Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Table of Contents
indent20px
styledisc

 
SVN - Download - Other Tutorials

Other Relevant Info:

...

No Format
// Instantiate Smooks with the config...
Smooks smooks = new Smooks("smooks-config.xml");
//
Create an exec context - no profiles....
StandaloneExecutionContext executionContext = smooks.createExecutionContext();

// Filter the input message to the outputWriter, using the execution context...
DOMResult domResult = new DOMResult();
smooks.filter(new StreamSource(new ByteArrayInputStream(messageIn)), domResult, executionContext)new StreamResult(messageOut));

Of course, you'd typically cache the Smooks instance.

...