background image

XMLOutputFactory

<< StAX Factory Classes | Resources, Namespaces, and Errors >>
<< StAX Factory Classes | Resources, Namespaces, and Errors >>
90
S
TREAMING
API
FOR
XML
erties supported by
XMLInputFactory
. See the StAX specification for a more
detailed listing.
XMLOutputFactory
New instances of the abstract class
XMLOutputFactory
are created by calling the
newInstance()
method on the class. The static method
XMLOutputFac-
tory.newInstance()
is then used to create a new factory instance. The algo-
rithm used to obtain the instance is the same as for
XMLInputFactory
but
references the
javax.xml.stream.XMLOutputFactory
system property.
XMLOutputFactory
supports only one property,
javax.xml.stream.isRepair-
ingNamespaces
. This property is required, and its purpose is to create default
Table 4­4 XMLInputFactory Properties
Property
Description
javax.xml.stream.isValidating
Turns on implementation specific validation.
javax.xml.stream.isCoalescing
(Required) Requires the processor to coalesce
adjacent character data.
javax.xml.stream.isNamespaceAware
Turns off namespace support. All implementations
must support namespaces supporting non-
namespace aware documents is optional.
javax.xml.stream.isReplacingEntityReferences
(Required) Requires the processor to replace inter-
nal entity references with their replacement value
and report them as characters or the set of events
that describe the entity.
javax.xml.stream.isSupportingExternalEntities
(Required) Requires the processor to resolve exter-
nal parsed entities.
javax.xml.stream.reporter
(Required) Sets and gets the implementation of the
XMLReporter
javax.xml.stream.resolver
(Required) Sets and gets the implementation of the
XMLResolver interface
javax.xml.stream.allocator
(Required) Sets/gets the implementation of the
XMLEventAllocator interface