Package org.apache.cxf.staxutils
Class AbstractDOMStreamReader<T,I>
java.lang.Object
org.apache.cxf.staxutils.AbstractDOMStreamReader<T,I>
- All Implemented Interfaces:
XMLStreamConstants
,XMLStreamReader
- Direct Known Subclasses:
W3CDOMStreamReader
Abstract logic for creating XMLStreamReader from DOM documents. Its works
using adapters for Element, Node and Attribute.
-
Nested Class Summary
-
Field Summary
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
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
void
protected void
protected abstract AbstractDOMStreamReader.ElementFrame<T,
I> protected AbstractDOMStreamReader.ElementFrame<T,
I> abstract String
int
abstract String
getNamespaceURI
(String prefix) getProperty
(String name) int
getTextCharacters
(int sourceStart, char[] target, int targetStart, int length) protected abstract boolean
boolean
hasName()
boolean
hasNext()
boolean
hasText()
boolean
boolean
boolean
boolean
boolean
protected void
newFrame
(AbstractDOMStreamReader.ElementFrame<T, I> newFrame) int
next()
protected abstract int
int
nextTag()
void
boolean
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface javax.xml.stream.XMLStreamReader
getAttributeCount, getAttributeLocalName, getAttributeName, getAttributeNamespace, getAttributePrefix, getAttributeType, getAttributeValue, getAttributeValue, getEncoding, getLocalName, getName, getNamespaceContext, getNamespaceCount, getNamespacePrefix, getNamespaceURI, getNamespaceURI, getPIData, getPITarget, getPrefix, getText, getTextCharacters, getTextLength, getTextStart, isAttributeSpecified
-
Field Details
-
currentEvent
protected int currentEvent
-
-
Constructor Details
-
AbstractDOMStreamReader
- Parameters:
frame
-
-
-
Method Details
-
getCurrentFrame
-
getProperty
- Specified by:
getProperty
in interfaceXMLStreamReader
-
next
- Specified by:
next
in interfaceXMLStreamReader
- Throws:
XMLStreamException
-
newFrame
-
endElement
protected void endElement() -
hasMoreChildren
protected abstract boolean hasMoreChildren() -
nextChild
protected abstract int nextChild() -
getChildFrame
-
require
- Specified by:
require
in interfaceXMLStreamReader
- Throws:
XMLStreamException
-
getElementText
- Specified by:
getElementText
in interfaceXMLStreamReader
- Throws:
XMLStreamException
-
consumeFrame
public void consumeFrame() -
nextTag
- Specified by:
nextTag
in interfaceXMLStreamReader
- Throws:
XMLStreamException
-
hasNext
- Specified by:
hasNext
in interfaceXMLStreamReader
- Throws:
XMLStreamException
-
close
- Specified by:
close
in interfaceXMLStreamReader
- Throws:
XMLStreamException
-
getNamespaceURI
- Specified by:
getNamespaceURI
in interfaceXMLStreamReader
-
isStartElement
public boolean isStartElement()- Specified by:
isStartElement
in interfaceXMLStreamReader
-
isEndElement
public boolean isEndElement()- Specified by:
isEndElement
in interfaceXMLStreamReader
-
isCharacters
public boolean isCharacters()- Specified by:
isCharacters
in interfaceXMLStreamReader
-
isWhiteSpace
public boolean isWhiteSpace()- Specified by:
isWhiteSpace
in interfaceXMLStreamReader
-
getEventType
public int getEventType()- Specified by:
getEventType
in interfaceXMLStreamReader
-
getTextCharacters
public int getTextCharacters(int sourceStart, char[] target, int targetStart, int length) throws XMLStreamException - Specified by:
getTextCharacters
in interfaceXMLStreamReader
- Throws:
XMLStreamException
-
hasText
public boolean hasText()- Specified by:
hasText
in interfaceXMLStreamReader
-
getSystemId
-
getPublicId
-
getLocation
- Specified by:
getLocation
in interfaceXMLStreamReader
-
hasName
public boolean hasName()- Specified by:
hasName
in interfaceXMLStreamReader
-
getVersion
- Specified by:
getVersion
in interfaceXMLStreamReader
-
isStandalone
public boolean isStandalone()- Specified by:
isStandalone
in interfaceXMLStreamReader
-
standaloneSet
public boolean standaloneSet()- Specified by:
standaloneSet
in interfaceXMLStreamReader
-
getCharacterEncodingScheme
- Specified by:
getCharacterEncodingScheme
in interfaceXMLStreamReader
-