Fuse 6 is no longer supported
As of February 2025, Red Hat Fuse 6 is no longer supported. If you are using Fuse 6, please upgrade to Red Hat build of Apache Camel.Dieser Inhalt ist in der von Ihnen ausgewählten Sprache nicht verfügbar.
12.42. Configuring the SAXToXMLWriter
- When writing a
SAXVisitor
implementation with theSAXToXMLWriter
, set theSAXToXMLWriter
constructor to a boolean. This is theencodeSpecialChars
arg and it should be set based on therewriteEntities
filter setting. - Move the
@StreamResultWriter
annotation from the class and onto theSAXToXMLWriter
instance declaration. This results in Smooks creating theSAXToXMLWriter
instance which is then initialized with therewriteEntities
filter setting for the associated Smooks instance:@TextConsumer public class MyVisitor implements SAXVisitAfter { @StreamResultWriter private SAXToXMLWriter xmlWriter; public void visitAfter(SAXElement element, ExecutionContext executionContext) throws SmooksException, IOException { xmlWriter.writeStartElement(element); xmlWriter.writeText(element); xmlWriter.writeEndElement(element); } }