Package javanet.staxutils
Class StaxUtilsXMLOutputFactory
- java.lang.Object
-
- javax.xml.stream.XMLOutputFactory
-
- javanet.staxutils.helpers.FilterXMLOutputFactory
-
- javanet.staxutils.StaxUtilsXMLOutputFactory
-
public class StaxUtilsXMLOutputFactory extends FilterXMLOutputFactory
An output factory that optionally wraps a filter around each writer. The propertyINDENTINGcontrols indentation of output.
-
-
Field Summary
Fields Modifier and Type Field Description static StringINDENTA String property whose value indents one level.static StringINDENTINGA Boolean property controlling whether to indent output.static StringNEW_LINEA String property whose value introduces a new line for indentation.-
Fields inherited from class javanet.staxutils.helpers.FilterXMLOutputFactory
source
-
Fields inherited from class javax.xml.stream.XMLOutputFactory
IS_REPAIRING_NAMESPACES
-
-
Constructor Summary
Constructors Constructor Description StaxUtilsXMLOutputFactory()StaxUtilsXMLOutputFactory(XMLOutputFactory source)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)protected XMLEventWriterfilter(XMLEventWriter writer)Transform the given writer.protected XMLStreamWriterfilter(XMLStreamWriter writer)ObjectgetProperty(String name)Delegates to source.inthashCode()booleanisPropertySupported(String name)Delegates to source.voidsetProperty(String name, Object value)Delegates to source.-
Methods inherited from class javanet.staxutils.helpers.FilterXMLOutputFactory
createXMLEventWriter, createXMLEventWriter, createXMLEventWriter, createXMLEventWriter, createXMLStreamWriter, createXMLStreamWriter, createXMLStreamWriter, createXMLStreamWriter, equals, hashCode
-
Methods inherited from class javax.xml.stream.XMLOutputFactory
newDefaultFactory, newFactory, newFactory, newInstance, newInstance
-
-
-
-
Field Detail
-
INDENTING
public static final String INDENTING
A Boolean property controlling whether to indent output. If true, output is indented byIndentingXMLEventWriterorIndentingXMLStreamWriter. The default is false.- See Also:
- Constant Field Values
-
INDENT
public static final String INDENT
A String property whose value indents one level. The default isIndentation.DEFAULT_INDENT.- See Also:
- Constant Field Values
-
NEW_LINE
public static final String NEW_LINE
A String property whose value introduces a new line for indentation. The default isIndentation.NORMAL_END_OF_LINE.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
StaxUtilsXMLOutputFactory
public StaxUtilsXMLOutputFactory()
-
StaxUtilsXMLOutputFactory
public StaxUtilsXMLOutputFactory(XMLOutputFactory source)
-
-
Method Detail
-
filter
protected XMLEventWriter filter(XMLEventWriter writer)
Description copied from class:FilterXMLOutputFactoryTransform the given writer.- Specified by:
filterin classFilterXMLOutputFactory
-
filter
protected XMLStreamWriter filter(XMLStreamWriter writer)
- Specified by:
filterin classFilterXMLOutputFactory
-
isPropertySupported
public boolean isPropertySupported(String name)
Description copied from class:FilterXMLOutputFactoryDelegates to source.- Overrides:
isPropertySupportedin classFilterXMLOutputFactory
-
setProperty
public void setProperty(String name, Object value) throws IllegalArgumentException
Description copied from class:FilterXMLOutputFactoryDelegates to source.- Overrides:
setPropertyin classFilterXMLOutputFactory- Throws:
IllegalArgumentException
-
getProperty
public Object getProperty(String name) throws IllegalArgumentException
Description copied from class:FilterXMLOutputFactoryDelegates to source.- Overrides:
getPropertyin classFilterXMLOutputFactory- Throws:
IllegalArgumentException
-
hashCode
public int hashCode()
- Overrides:
hashCodein classFilterXMLOutputFactory
-
equals
public boolean equals(Object o)
- Overrides:
equalsin classFilterXMLOutputFactory
-
-