com.ctc.wstx.evt
Class SimpleStartElement
java.lang.Object
com.ctc.wstx.evt.WEvent
com.ctc.wstx.evt.SimpleStartElement
- All Implemented Interfaces:
- javax.xml.stream.events.StartElement, javax.xml.stream.events.XMLEvent, javax.xml.stream.XMLStreamConstants, XMLEvent2
public class SimpleStartElement
- extends WEvent
Wstx StartElement implementation used when event is constructed
from already objectified data, for example when constructed by the event
factory.
| Fields inherited from interface javax.xml.stream.XMLStreamConstants |
ATTRIBUTE, CDATA, CHARACTERS, COMMENT, DTD, END_DOCUMENT, END_ELEMENT, ENTITY_DECLARATION, ENTITY_REFERENCE, NAMESPACE, NOTATION_DECLARATION, PROCESSING_INSTRUCTION, SPACE, START_DOCUMENT, START_ELEMENT |
| Methods inherited from class com.ctc.wstx.evt.WEvent |
asCharacters, asEndElement, getLocation, getSchemaType, isAttribute, isCharacters, isEndDocument, isEndElement, isEntityReference, isNamespace, isProcessingInstruction, isStartDocument, throwFromIOE, toString |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface javax.xml.stream.events.XMLEvent |
asCharacters, asEndElement, getLocation, getSchemaType, isAttribute, isCharacters, isEndDocument, isEndElement, isEntityReference, isNamespace, isProcessingInstruction, isStartDocument |
mName
protected final javax.xml.namespace.QName mName
mNsCtxt
protected final BaseNsContext mNsCtxt
SimpleStartElement
protected SimpleStartElement(javax.xml.stream.Location loc,
javax.xml.namespace.QName name,
BaseNsContext nsCtxt,
java.util.Map attr)
construct
public static SimpleStartElement construct(javax.xml.stream.Location loc,
javax.xml.namespace.QName name,
java.util.Map attrs,
java.util.List ns,
javax.xml.namespace.NamespaceContext nsCtxt)
- Factory method called when a start element needs to be constructed
from an external source (most likely, non-woodstox stream reader).
construct
public static SimpleStartElement construct(javax.xml.stream.Location loc,
javax.xml.namespace.QName name,
java.util.Iterator attrs,
java.util.Iterator ns,
javax.xml.namespace.NamespaceContext nsCtxt)
getAttributeByName
public javax.xml.stream.events.Attribute getAttributeByName(javax.xml.namespace.QName name)
- Specified by:
getAttributeByName in interface javax.xml.stream.events.StartElement
getAttributes
public java.util.Iterator getAttributes()
- Specified by:
getAttributes in interface javax.xml.stream.events.StartElement
outputNsAndAttr
protected void outputNsAndAttr(java.io.Writer w)
throws java.io.IOException
- Throws:
java.io.IOException
outputNsAndAttr
protected void outputNsAndAttr(javax.xml.stream.XMLStreamWriter w)
throws javax.xml.stream.XMLStreamException
- Throws:
javax.xml.stream.XMLStreamException
getName
public final javax.xml.namespace.QName getName()
- Specified by:
getName in interface javax.xml.stream.events.StartElement
getNamespaces
public java.util.Iterator getNamespaces()
- Specified by:
getNamespaces in interface javax.xml.stream.events.StartElement
getNamespaceContext
public javax.xml.namespace.NamespaceContext getNamespaceContext()
- Specified by:
getNamespaceContext in interface javax.xml.stream.events.StartElement
getNamespaceURI
public java.lang.String getNamespaceURI(java.lang.String prefix)
- Specified by:
getNamespaceURI in interface javax.xml.stream.events.StartElement
asStartElement
public javax.xml.stream.events.StartElement asStartElement()
- Specified by:
asStartElement in interface javax.xml.stream.events.XMLEvent- Overrides:
asStartElement in class WEvent
getEventType
public int getEventType()
- Specified by:
getEventType in interface javax.xml.stream.events.XMLEvent- Specified by:
getEventType in class WEvent
isStartElement
public boolean isStartElement()
- Specified by:
isStartElement in interface javax.xml.stream.events.XMLEvent- Overrides:
isStartElement in class WEvent
writeAsEncodedUnicode
public void writeAsEncodedUnicode(java.io.Writer w)
throws javax.xml.stream.XMLStreamException
- Specified by:
writeAsEncodedUnicode in interface javax.xml.stream.events.XMLEvent- Specified by:
writeAsEncodedUnicode in class WEvent
- Throws:
javax.xml.stream.XMLStreamException
writeUsing
public void writeUsing(javax.xml.stream.XMLStreamWriter w)
throws javax.xml.stream.XMLStreamException
- Specified by:
writeUsing in interface XMLEvent2- Specified by:
writeUsing in class WEvent
- Throws:
javax.xml.stream.XMLStreamException