public class SAXResult extends Object implements Result
Acts as an holder for a transformation Result.
public static final String FEATURE
If TransformerFactory.getFeature(java.lang.String)
returns true when passed this value as an argument, the Transformer supports Result output of this type.
public SAXResult()
Zero-argument default constructor.
public SAXResult(ContentHandler handler)
Create a SAXResult that targets a SAX2 ContentHandler
.
handler
- Must be a non-null ContentHandler reference.public void setHandler(ContentHandler handler)
Set the target to be a SAX2 ContentHandler
.
handler
- Must be a non-null ContentHandler reference.public ContentHandler getHandler()
Get the ContentHandler
that is the Result.
public void setLexicalHandler(LexicalHandler handler)
Set the SAX2 LexicalHandler
for the output.
This is needed to handle XML comments and the like. If the lexical handler is not set, an attempt should be made by the transformer to cast the ContentHandler
to a LexicalHandler
.
handler
- A non-null LexicalHandler
for handling lexical parse events.public LexicalHandler getLexicalHandler()
Get a SAX2 LexicalHandler
for the output.
LexicalHandler
, or null.public void setSystemId(String systemId)
Method setSystemId Set the systemID that may be used in association with the ContentHandler
.
setSystemId
in interface Result
systemId
- The system identifier as a URI string.public String getSystemId()
Get the system identifier that was set with setSystemId.
getSystemId
in interface Result
© 1993–2017, Oracle and/or its affiliates. All rights reserved.
Documentation extracted from Debian's OpenJDK Development Kit package.
Licensed under the GNU General Public License, version 2, with the Classpath Exception.
Various third party code in OpenJDK is licensed under different licenses (see Debian package).
Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.