|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sun.xml.stream.buffer.AbstractCreatorProcessor
com.sun.xml.stream.buffer.AbstractCreator
com.sun.xml.stream.buffer.stax.StreamReaderBufferCreator
public class StreamReaderBufferCreator
Create a buffer using an XMLStreamReader
.
TODO: Implement the marking the stream on the element when an ID attribute on the element is defined
Field Summary |
---|
Fields inherited from class com.sun.xml.stream.buffer.AbstractCreator |
---|
_buffer |
Constructor Summary | |
---|---|
StreamReaderBufferCreator()
Create a stream reader buffer creator. |
|
StreamReaderBufferCreator(MutableXMLStreamBuffer buffer)
Create a stream reader buffer creator using a mutable stream buffer. |
Method Summary | |
---|---|
MutableXMLStreamBuffer |
create(javax.xml.stream.XMLStreamReader reader)
Create the buffer from a stream reader. |
MutableXMLStreamBuffer |
createElementFragment(javax.xml.stream.XMLStreamReader reader,
boolean storeInScopeNamespaces)
Creates the buffer from a stream reader that is an element fragment. |
protected void |
storeAttribute(java.lang.String prefix,
java.lang.String uri,
java.lang.String localName,
java.lang.String type,
java.lang.String value)
|
void |
storeElement(java.lang.String nsURI,
java.lang.String localName,
java.lang.String prefix,
java.lang.String[] ns)
A low level method a create a structure element explicitly. |
protected void |
storeNamespaceAttribute(java.lang.String prefix,
java.lang.String uri)
|
protected void |
storeProcessingInstruction(java.lang.String target,
java.lang.String data)
|
protected void |
storeQualifiedName(int item,
java.lang.String prefix,
java.lang.String uri,
java.lang.String localName)
|
Methods inherited from class com.sun.xml.stream.buffer.AbstractCreator |
---|
createBuffer, getXMLStreamBuffer, increaseTreeCount, peekAtContentObject, resizeContentCharacters, resizeContentObjects, resizeStructure, resizeStructureStrings, setBuffer, setHasInternedStrings, setXMLStreamBuffer, storeContentCharacters, storeContentCharactersCopy, storeContentObject, storeContentString, storeStructure, storeStructureString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public StreamReaderBufferCreator()
A stream buffer will be created for storing the infoset from a stream reader.
public StreamReaderBufferCreator(MutableXMLStreamBuffer buffer)
buffer
- the mutable stream buffer.Method Detail |
---|
public MutableXMLStreamBuffer create(javax.xml.stream.XMLStreamReader reader) throws javax.xml.stream.XMLStreamException
The stream reader must be positioned at the start of the document or the start of an element.
If the stream is positioned at the start of the document then the whole document is stored and after storing the stream will be positioned at the end of the document.
If the stream is positioned at the start of an element then the element and all its children will be stored and after storing the stream will be positioned at the next event after the end of the element.
javax.xml.stream.XMLStreamException
- if the stream reader is not positioned at
the start of the document or at an element.public MutableXMLStreamBuffer createElementFragment(javax.xml.stream.XMLStreamReader reader, boolean storeInScopeNamespaces) throws javax.xml.stream.XMLStreamException
The stream reader will be moved to the position of the next start of an element if the stream reader is not already positioned at the start of an element.
The element and all its children will be stored and after storing the stream will be positioned at the next event after the end of the element.
storeInScopeNamespaces
- true if in-scope namespaces of the element
fragment should be stored.
javax.xml.stream.XMLStreamException
- if the stream reader cannot be positioned at
the start of an element.public void storeElement(java.lang.String nsURI, java.lang.String localName, java.lang.String prefix, java.lang.String[] ns)
ns
- an array of the even length of the form { prefix0, uri0, prefix1, uri1, ... }.protected void storeQualifiedName(int item, java.lang.String prefix, java.lang.String uri, java.lang.String localName)
protected final void storeNamespaceAttribute(java.lang.String prefix, java.lang.String uri)
protected final void storeAttribute(java.lang.String prefix, java.lang.String uri, java.lang.String localName, java.lang.String type, java.lang.String value)
protected final void storeProcessingInstruction(java.lang.String target, java.lang.String data)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |