com.sun.xml.fastinfoset.stax.factory
Class StAXInputFactory
java.lang.Object
javax.xml.stream.XMLInputFactory
com.sun.xml.fastinfoset.stax.factory.StAXInputFactory
public class StAXInputFactory
- extends javax.xml.stream.XMLInputFactory
| Fields inherited from class javax.xml.stream.XMLInputFactory |
ALLOCATOR, IS_COALESCING, IS_NAMESPACE_AWARE, IS_REPLACING_ENTITY_REFERENCES, IS_SUPPORTING_EXTERNAL_ENTITIES, IS_VALIDATING, REPORTER, RESOLVER, SUPPORT_DTD |
| Methods inherited from class javax.xml.stream.XMLInputFactory |
newFactory, newFactory, newInstance |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
StAXInputFactory
public StAXInputFactory()
newInstance
public static javax.xml.stream.XMLInputFactory newInstance()
createXMLStreamReader
public javax.xml.stream.XMLStreamReader createXMLStreamReader(Reader xmlfile)
throws javax.xml.stream.XMLStreamException
- Create a new XMLStreamReader from a reader
- Specified by:
createXMLStreamReader in class javax.xml.stream.XMLInputFactory
- Parameters:
xmlfile - the XML data to read from
- Throws:
javax.xml.stream.XMLStreamException
createXMLStreamReader
public javax.xml.stream.XMLStreamReader createXMLStreamReader(InputStream s)
throws javax.xml.stream.XMLStreamException
- Specified by:
createXMLStreamReader in class javax.xml.stream.XMLInputFactory
- Throws:
javax.xml.stream.XMLStreamException
createXMLStreamReader
public javax.xml.stream.XMLStreamReader createXMLStreamReader(String systemId,
Reader xmlfile)
throws javax.xml.stream.XMLStreamException
- Specified by:
createXMLStreamReader in class javax.xml.stream.XMLInputFactory
- Throws:
javax.xml.stream.XMLStreamException
createXMLStreamReader
public javax.xml.stream.XMLStreamReader createXMLStreamReader(Source source)
throws javax.xml.stream.XMLStreamException
- Specified by:
createXMLStreamReader in class javax.xml.stream.XMLInputFactory
- Throws:
javax.xml.stream.XMLStreamException
createXMLStreamReader
public javax.xml.stream.XMLStreamReader createXMLStreamReader(String systemId,
InputStream inputstream)
throws javax.xml.stream.XMLStreamException
- Specified by:
createXMLStreamReader in class javax.xml.stream.XMLInputFactory
- Throws:
javax.xml.stream.XMLStreamException
createXMLStreamReader
public javax.xml.stream.XMLStreamReader createXMLStreamReader(InputStream inputstream,
String encoding)
throws javax.xml.stream.XMLStreamException
- Specified by:
createXMLStreamReader in class javax.xml.stream.XMLInputFactory
- Throws:
javax.xml.stream.XMLStreamException
createXMLEventReader
public javax.xml.stream.XMLEventReader createXMLEventReader(InputStream inputstream)
throws javax.xml.stream.XMLStreamException
- Specified by:
createXMLEventReader in class javax.xml.stream.XMLInputFactory
- Parameters:
inputstream -
- Returns:
- XMLEventReader
- Throws:
javax.xml.stream.XMLStreamException
createXMLEventReader
public javax.xml.stream.XMLEventReader createXMLEventReader(Reader reader)
throws javax.xml.stream.XMLStreamException
- Specified by:
createXMLEventReader in class javax.xml.stream.XMLInputFactory
- Throws:
javax.xml.stream.XMLStreamException
createXMLEventReader
public javax.xml.stream.XMLEventReader createXMLEventReader(Source source)
throws javax.xml.stream.XMLStreamException
- Specified by:
createXMLEventReader in class javax.xml.stream.XMLInputFactory
- Throws:
javax.xml.stream.XMLStreamException
createXMLEventReader
public javax.xml.stream.XMLEventReader createXMLEventReader(String systemId,
InputStream inputstream)
throws javax.xml.stream.XMLStreamException
- Specified by:
createXMLEventReader in class javax.xml.stream.XMLInputFactory
- Throws:
javax.xml.stream.XMLStreamException
createXMLEventReader
public javax.xml.stream.XMLEventReader createXMLEventReader(InputStream stream,
String encoding)
throws javax.xml.stream.XMLStreamException
- Specified by:
createXMLEventReader in class javax.xml.stream.XMLInputFactory
- Throws:
javax.xml.stream.XMLStreamException
createXMLEventReader
public javax.xml.stream.XMLEventReader createXMLEventReader(String systemId,
Reader reader)
throws javax.xml.stream.XMLStreamException
- Specified by:
createXMLEventReader in class javax.xml.stream.XMLInputFactory
- Throws:
javax.xml.stream.XMLStreamException
createXMLEventReader
public javax.xml.stream.XMLEventReader createXMLEventReader(javax.xml.stream.XMLStreamReader streamReader)
throws javax.xml.stream.XMLStreamException
- Create a new XMLEventReader from an XMLStreamReader. After being used
to construct the XMLEventReader instance returned from this method
the XMLStreamReader must not be used.
- Specified by:
createXMLEventReader in class javax.xml.stream.XMLInputFactory
- Parameters:
streamReader - the XMLStreamReader to read from (may not be modified)
- Returns:
- a new XMLEventReader
- Throws:
javax.xml.stream.XMLStreamException
getEventAllocator
public javax.xml.stream.util.XMLEventAllocator getEventAllocator()
- Specified by:
getEventAllocator in class javax.xml.stream.XMLInputFactory
getXMLReporter
public javax.xml.stream.XMLReporter getXMLReporter()
- Specified by:
getXMLReporter in class javax.xml.stream.XMLInputFactory
getXMLResolver
public javax.xml.stream.XMLResolver getXMLResolver()
- Specified by:
getXMLResolver in class javax.xml.stream.XMLInputFactory
setXMLReporter
public void setXMLReporter(javax.xml.stream.XMLReporter xmlreporter)
- Specified by:
setXMLReporter in class javax.xml.stream.XMLInputFactory
setXMLResolver
public void setXMLResolver(javax.xml.stream.XMLResolver xmlresolver)
- Specified by:
setXMLResolver in class javax.xml.stream.XMLInputFactory
createFilteredReader
public javax.xml.stream.XMLEventReader createFilteredReader(javax.xml.stream.XMLEventReader reader,
javax.xml.stream.EventFilter filter)
throws javax.xml.stream.XMLStreamException
- Create a filtered event reader that wraps the filter around the event reader
- Specified by:
createFilteredReader in class javax.xml.stream.XMLInputFactory
- Parameters:
reader - the event reader to wrapfilter - the filter to apply to the event reader
- Throws:
javax.xml.stream.XMLStreamException
createFilteredReader
public javax.xml.stream.XMLStreamReader createFilteredReader(javax.xml.stream.XMLStreamReader reader,
javax.xml.stream.StreamFilter filter)
throws javax.xml.stream.XMLStreamException
- Create a filtered reader that wraps the filter around the reader
- Specified by:
createFilteredReader in class javax.xml.stream.XMLInputFactory
- Parameters:
reader - the reader to filterfilter - the filter to apply to the reader
- Throws:
javax.xml.stream.XMLStreamException
getProperty
public Object getProperty(String name)
throws IllegalArgumentException
- Get the value of a feature/property from the underlying implementation
- Specified by:
getProperty in class javax.xml.stream.XMLInputFactory
- Parameters:
name - The name of the property (may not be null)
- Returns:
- The value of the property
- Throws:
IllegalArgumentException - if the property is not supported
isPropertySupported
public boolean isPropertySupported(String name)
- Query the set of Properties that this factory supports.
- Specified by:
isPropertySupported in class javax.xml.stream.XMLInputFactory
- Parameters:
name - The name of the property (may not be null)
- Returns:
- true if the property is supported and false otherwise
setEventAllocator
public void setEventAllocator(javax.xml.stream.util.XMLEventAllocator allocator)
- Set a user defined event allocator for events
- Specified by:
setEventAllocator in class javax.xml.stream.XMLInputFactory
- Parameters:
allocator - the user defined allocator
setProperty
public void setProperty(String name,
Object value)
throws IllegalArgumentException
- Allows the user to set specific feature/property on the underlying implementation. The underlying implementation
is not required to support every setting of every property in the specification and may use IllegalArgumentException
to signal that an unsupported property may not be set with the specified value.
- Specified by:
setProperty in class javax.xml.stream.XMLInputFactory
- Parameters:
name - The name of the property (may not be null)value - The value of the property
- Throws:
IllegalArgumentException - if the property is not supported
Copyright © 2005-2011 Oracle Corporation. All Rights Reserved.