XMLEventFactory2.
It can be used as a building block for concrete implementations:
the minimal requirement is to implement createQName
methods.
Note that due to underlying Stax factory being non-generic (it was specified
for JDK 1.4, pre-generic), no generic typing can be added to various
java.s in signatures.
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public Attribute | createAttribute(QName
the qualified name of the attribute, may not be null name, String the attribute value to set, may not be null value)Implements abstract javax. |
| public Attribute | createAttribute(String
the local name of the XML name of the attribute, localName cannot be null localName, String the attribute value to set, may not be null value)Implements abstract javax. |
| public Attribute | createAttribute(String
the prefix of this attribute, may not be null prefix, String the attribute value is set to this value, may not be null nsURI, String the local name of the XML name of the attribute, localName cannot be null localName, String the attribute value to set, may not be null value)Implements abstract javax. |
| public Characters | createCData(String
the string to create content)Implements abstract javax. |
| public Characters | createCharacters(String
the string to create content)Implements abstract javax. |
| public Comment | createComment(String
The text of the comment text)Implements abstract javax. |
| public DTD | createDTD(String
the text of the document type definition dtd)Implements abstract javax. Note constructing DTD events this way means that there will be no internal presentation of actual DTD; no parsing is implied by construction. |
| public DTD2 | |
| public DTD2 | |
| public EndDocument | createEndDocument()
Implements abstract javax. |
| public EndElement | createEndElement(QName
the qualified name of the EndElement name, Iterator<E> an optional unordered set of objects that
implement Namespace that have gone out of scope, may be null namespaces)Implements abstract javax. |
| public EndElement | createEndElement(String
the prefix of the QName of the new StartElement prefix, String the uri of the QName of the new StartElement nsURI, String the local name of the QName of the new StartElement localName)Implements abstract javax. |
| public EndElement | createEndElement(String
the prefix of the QName of the new StartElement prefix, String the uri of the QName of the new StartElement nsURI, String the local name of the QName of the new StartElement localName, Iterator<E> an unordered set of objects that implement
Namespace that have gone out of scope, may be null ns)Implements abstract javax. |
| public EntityReference | createEntityReference(String
The name of the reference name, EntityDeclaration the declaration for the event decl)Implements abstract javax. |
| public Characters | createIgnorableSpace(String
the space to create content)Implements abstract javax. |
| public Namespace | createNamespace(String
the default namespace uri nsURI)Implements abstract javax. |
| public Namespace | createNamespace(String
the prefix of this namespace, may not be null prefix, String the attribute value is set to this value, may not be null nsURI)Implements abstract javax. |
| public ProcessingInstruction | createProcessingInstruction(String
The target of the processing instruction target, String The text of the processing instruction data)Implements abstract javax. |
| protected abstract QName | |
| protected abstract QName | |
| public Characters | createSpace(String
the content of the space to create content)Implements abstract javax. |
| public StartDocument | createStartDocument()
Implements abstract javax. |
| public StartDocument | createStartDocument(String
the encoding style encoding)Implements abstract javax. |
| public StartDocument | createStartDocument(String
the encoding style encoding, String the XML version version)Implements abstract javax. |
| public StartDocument | createStartDocument(String
the encoding style encoding, String the XML version version, boolean the status of standalone may be set to "true" or "false" standalone)Implements abstract javax. |
| public StartElement | createStartElement(QName
the qualified name of the attribute, may not be null name, Iterator<E> an optional unordered set of objects that
implement Attribute to add to the new StartElement, may be null attr, Iterator<E> an optional unordered set of objects that
implement Namespace to add to the new StartElement, may be null ns)Implements abstract javax. |
| public StartElement | createStartElement(String
the prefix of the QName of the new StartElement prefix, String the uri of the QName of the new StartElement nsURI, String the local name of the QName of the new StartElement localName)Implements abstract javax. |
| public StartElement | createStartElement(String
the prefix of the QName of the new StartElement prefix, String the uri of the QName of the new StartElement nsURI, String the local name of the QName of the new StartElement localName, Iterator<E> an unordered set of objects that implement
Attribute to add to the new StartElement attr, Iterator<E> an unordered set of objects that implement
Namespace to add to the new StartElement ns)Implements abstract javax. |
| public StartElement | createStartElement(String
the prefix of the QName of the new StartElement prefix, String the uri of the QName of the new StartElement nsURI, String the local name of the QName of the new StartElement localName, Iterator<E> an unordered set of objects that implement
Attribute to add to the new StartElement, may be null attr, Iterator<E> an unordered set of objects that implement
Namespace to add to the new StartElement, may be null ns, NamespaceContext the namespace context of this element nsCtxt)Implements abstract javax. |
| protected StartElement | |
| public void | setLocation(Location
the location to set on each event created loc)Implements abstract javax. |
| mLocation | back to summary |
|---|---|
| protected Location mLocation | |
| Stax2EventFactoryImpl | back to summary |
|---|---|
| public Stax2EventFactoryImpl() | |
| createAttribute | back to summary |
|---|---|
| public Attribute createAttribute(QName name, String value) Implements abstract javax. Doc from javax. Create a new Attribute | |
| createAttribute | back to summary |
|---|---|
| public Attribute createAttribute(String localName, String value) Implements abstract javax. Doc from javax. Create a new Attribute | |
| createAttribute | back to summary |
|---|---|
| public Attribute createAttribute(String prefix, String nsURI, String localName, String value) Implements abstract javax. Doc from javax. Create a new Attribute
| |
| createCData | back to summary |
|---|---|
| public Characters createCData(String content) Implements abstract javax. Doc from javax. Create a Characters event with the CData flag set to true
| |
| createCharacters | back to summary |
|---|---|
| public Characters createCharacters(String content) Implements abstract javax. Doc from javax. Create a Characters event, this method does not check if the content is all whitespace. To create a space event use #createSpace(String)
| |
| createComment | back to summary |
|---|---|
| public Comment createComment(String text) Implements abstract javax. Doc from javax. Create a comment. | |
| createDTD | back to summary |
|---|---|
| public DTD createDTD(String dtd) Implements abstract javax. Note constructing DTD events this way means that there will be no internal presentation of actual DTD; no parsing is implied by construction.
| |
| createDTD | back to summary |
|---|---|
| public DTD2 createDTD(String rootName, String sysId, String pubId, String intSubset) Implements abstract org.
| |
| createDTD | back to summary |
|---|---|
| public DTD2 createDTD(String rootName, String sysId, String pubId, String intSubset, Object processedDTD) Implements abstract org.
| |
| createEndDocument | back to summary |
|---|---|
| public EndDocument createEndDocument() Implements abstract javax. Doc from javax. Creates a new instance of an EndDocument event
| |
| createEndElement | back to summary |
|---|---|
| public EndElement createEndElement(QName name, Iterator<E> namespaces) Implements abstract javax. Doc from javax. Create a new EndElement
| |
| createEndElement | back to summary |
|---|---|
| public EndElement createEndElement(String prefix, String nsURI, String localName) Implements abstract javax. Doc from javax. Create a new EndElement
| |
| createEndElement | back to summary |
|---|---|
| public EndElement createEndElement(String prefix, String nsURI, String localName, Iterator<E> ns) Implements abstract javax. Doc from javax. Create a new EndElement
| |
| createEntityReference | back to summary |
|---|---|
| public EntityReference createEntityReference(String name, EntityDeclaration decl) Implements abstract javax. Doc from javax. Creates a new instance of a EntityReference event
| |
| createIgnorableSpace | back to summary |
|---|---|
| public Characters createIgnorableSpace(String content) Implements abstract javax. Doc from javax. Create an ignorable space
| |
| createNamespace | back to summary |
|---|---|
| public Namespace createNamespace(String nsURI) Implements abstract javax. Doc from javax. Create a new default Namespace | |
| createNamespace | back to summary |
|---|---|
| public Namespace createNamespace(String prefix, String nsURI) Implements abstract javax. Doc from javax. Create a new Namespace | |
| createProcessingInstruction | back to summary |
|---|---|
| public ProcessingInstruction createProcessingInstruction(String target, String data) Implements abstract javax. Doc from javax. Create a processing instruction
| |
| createQName | back to summary |
|---|---|
| protected abstract QName createQName(String nsURI, String localName) | |
| createQName | back to summary |
|---|---|
| protected abstract QName createQName(String nsURI, String localName, String prefix) | |
| createSpace | back to summary |
|---|---|
| public Characters createSpace(String content) Implements abstract javax. Doc from javax. Create a Characters event with the isSpace flag set to true
| |
| createStartDocument | back to summary |
|---|---|
| public StartDocument createStartDocument() Implements abstract javax. Doc from javax. Creates a new instance of a StartDocument event
| |
| createStartDocument | back to summary |
|---|---|
| public StartDocument createStartDocument(String encoding) Implements abstract javax. Doc from javax. Creates a new instance of a StartDocument event
| |
| createStartDocument | back to summary |
|---|---|
| public StartDocument createStartDocument(String encoding, String version) Implements abstract javax. Doc from javax. Creates a new instance of a StartDocument event
| |
| createStartDocument | back to summary |
|---|---|
| public StartDocument createStartDocument(String encoding, String version, boolean standalone) Implements abstract javax. Doc from javax. Creates a new instance of a StartDocument event
| |
| createStartElement | back to summary |
|---|---|
| public StartElement createStartElement(QName name, Iterator<E> attr, Iterator<E> ns) Implements abstract javax. Doc from javax. Create a new StartElement. Namespaces can be added to this StartElement by passing in an Iterator that walks over a set of Namespace interfaces. Attributes can be added to this StartElement by passing an iterator that walks over a set of Attribute interfaces.
| |
| createStartElement | back to summary |
|---|---|
| public StartElement createStartElement(String prefix, String nsURI, String localName) Implements abstract javax. Doc from javax. Create a new StartElement. This defaults the NamespaceContext to an empty NamespaceContext. Querying this event for its namespaces or attributes will result in an empty iterator being returned.
| |
| createStartElement | back to summary |
|---|---|
| public StartElement createStartElement(String prefix, String nsURI, String localName, Iterator<E> attr, Iterator<E> ns) Implements abstract javax. Doc from javax. Create a new StartElement. Namespaces can be added to this StartElement by passing in an Iterator that walks over a set of Namespace interfaces. Attributes can be added to this StartElement by passing an iterator that walks over a set of Attribute interfaces.
| |
| createStartElement | back to summary |
|---|---|
| public StartElement createStartElement(String prefix, String nsURI, String localName, Iterator<E> attr, Iterator<E> ns, NamespaceContext nsCtxt) Implements abstract javax. Doc from javax. Create a new StartElement. Namespaces can be added to this StartElement by passing in an Iterator that walks over a set of Namespace interfaces. Attributes can be added to this StartElement by passing an iterator that walks over a set of Attribute interfaces.
| |
| createStartElement | back to summary |
|---|---|
| protected StartElement createStartElement(QName name, Iterator<?> attr, Iterator<?> ns, NamespaceContext ctxt) | |
| setLocation | back to summary |
|---|---|
| public void setLocation(Location loc) Implements abstract javax. Doc from javax. This method allows setting of the Location on each event that is created by this factory. The values are copied by value into the events created by this factory. To reset the location information set the location to null. | |