Versions Compared

Key

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

...

Code Block
// lets turn Object messages into XML then send to MQSeries
from("activemq:My.Queue").
  marshal().xstream().
  to("mqseries:Another.Queue");

XMLInputFactory and XMLOutputFactory

...

The XStream library|http://xstream.codehaus.org/] uses the javax.xml.stream.XMLOutputFactoryXMLInputFactory and javax.xml.stream.XMLInputFactoryXMLOutputFactory, you can control which implementation of this factory should be used.

The Factory is discovered using this algorithm:
1. Use the javax.xml.stream.XMLOutputFactoryXMLInputFactory , javax.xml.stream.XMLInputFactoryXMLOutputFactory system property.
2. Use the lib/xml.stream.properties file in the JRE_HOME directory.
3. Use the Services API, if available, to determine the classname by looking in the META-INF/services/javax.xml.stream.XMLOutputFactoryXMLInputFactory, META-INF/services/javax.xml.stream.XMLInputFactoryXMLOutputFactory files in jars available to the JRE.
4. Use the platform default XMLInputFactory,XMLOutputFactory ,XMLInputFactoryinstanceinstance.