Package org.apache.sis.xml
Class InputFactory
java.lang.Object
org.apache.sis.util.Static
org.apache.sis.xml.InputFactory
Provides access to
XMLInputFactory methods as static methods working on a SIS-wide instance.
This convenience is provided in a separated class in order to allow the JVM to instantiate the factory
only when first needed, when initializing this class.- Since:
- 0.4
- Version:
- 1.0
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic XMLEventReaderCreates a new reader for the given stream.static XMLEventReaderCreates a new reader for the given stream.static XMLEventReaderCreates a new reader for the given source.static XMLEventReaderCreates a new reader for the given source.static XMLEventReaderCreates a new reader for the given source.static XMLEventReaderCreates a new reader for the given source.
-
Field Details
-
FACTORY
The SIS-wide factory. This factory can be specified by the user, for example using thejavax.xml.stream.XMLInputFactorysystem property.Note:XMLInputFactoryhas annewDefaultFactory()method which bypass user settings.
-
-
Constructor Details
-
InputFactory
private InputFactory()Do not allow instantiation of this class.
-
-
Method Details
-
createXMLEventReader
Creates a new reader for the given stream. It is caller's responsibility to close the given input stream after usage (it will not be done byXMLEventReader.close()).- Parameters:
in- where to read from.- Returns:
- the reader.
- Throws:
XMLStreamException- if the reader cannot be created.
-
createXMLEventReader
Creates a new reader for the given stream. It is caller's responsibility to close the given reader after usage (it will not be done byXMLEventReader.close()).- Parameters:
in- where to read from.- Returns:
- the reader.
- Throws:
XMLStreamException- if the reader cannot be created.
-
createXMLEventReader
Creates a new reader for the given source.- Parameters:
in- where to read from.- Returns:
- the reader.
- Throws:
XMLStreamException- if the reader cannot be created.
-
createXMLEventReader
Creates a new reader for the given source.- Parameters:
in- where to read from.- Returns:
- the reader.
- Throws:
XMLStreamException- if the reader cannot be created.
-
createXMLEventReader
Creates a new reader for the given source.- Parameters:
in- where to read from.- Returns:
- the reader.
- Throws:
XMLStreamException- if the reader cannot be created.
-
createXMLEventReader
Creates a new reader for the given source. It is caller's responsibility to close the given stream reader after usage (it will not be done byXMLEventReader.close()).- Parameters:
in- where to read from.- Returns:
- the reader.
- Throws:
XMLStreamException- if the reader cannot be created.
-