XMLEventReader, javax.xml.stream.events.XMLEvent , javax.xml.stream.events.Characters , javax.xml.stream.events.ProcessingInstruction , javax.xml.stream.events.StartElement , javax.xml.stream.events.EndElement
| Modifier and Type | Method and Description |
|---|---|
| public void | add(XMLEvent
the event to be added event)Redeclares javax. Add an event to the output stream Adding a START_ELEMENT will open a new namespace scope that will be closed when the corresponding END_ELEMENT is written. |
| public void | add(XMLEventReader
the event stream to add to the output reader)Adds an entire stream to an output stream, calls next() on the inputStream argument until hasNext() returns false This should be treated as a convenience method that will perform the following loop over all the events in an event reader and call add on each event. |
| public void | |
| public void | |
| public NamespaceContext | |
| public String | |
| public void | setDefaultNamespace(String
the uri to bind to the default namespace uri)Binds a URI to the default namespace This URI is bound in the scope of the current START_ELEMENT / END_ELEMENT pair. |
| public void | setNamespaceContext(NamespaceContext
the namespace context to use for this writer context)Sets the current namespace context for prefix and uri bindings. |
| public void |
| add | back to summary | ||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| public void add(XMLEvent event) throws XMLStreamException Redeclares javax. Add an event to the output stream Adding a START_ELEMENT will open a new namespace scope that will be closed when the corresponding END_ELEMENT is written.
| |||||||||||||||||||||||||||||||||||||||||
| add | back to summary |
|---|---|
| public void add(XMLEventReader reader) throws XMLStreamException Adds an entire stream to an output stream, calls next() on the inputStream argument until hasNext() returns false This should be treated as a convenience method that will perform the following loop over all the events in an event reader and call add on each event.
| |
| close | back to summary |
|---|---|
| public void close() throws XMLStreamException Frees any resources associated with this stream
| |
| flush | back to summary |
|---|---|
| public void flush() throws XMLStreamException Writes any cached events to the underlying output mechanism
| |
| getNamespaceContext | back to summary |
|---|---|
| public NamespaceContext getNamespaceContext() Returns the current namespace context.
| |
| getPrefix | back to summary |
|---|---|
| public String getPrefix(String uri) throws XMLStreamException Gets the prefix the uri is bound to
| |
| setDefaultNamespace | back to summary |
|---|---|
| public void setDefaultNamespace(String uri) throws XMLStreamException Binds a URI to the default namespace This URI is bound in the scope of the current START_ELEMENT / END_ELEMENT pair. If this method is called before a START_ELEMENT has been written the uri is bound in the root scope.
| |
| setNamespaceContext | back to summary |
|---|---|
| public void setNamespaceContext(NamespaceContext context) throws XMLStreamException Sets the current namespace context for prefix and uri bindings. This context becomes the root namespace context for writing and will replace the current root namespace context. Subsequent calls to setPrefix and setDefaultNamespace will bind namespaces using the context passed to the method as the root context for resolving namespaces.
| |
| setPrefix | back to summary |
|---|---|
| public void setPrefix(String prefix, String uri) throws XMLStreamException Sets the prefix the uri is bound to. This prefix is bound in the scope of the current START_ELEMENT / END_ELEMENT pair. If this method is called before a START_ELEMENT has been written the prefix is bound in the root scope.
| |