XMLStreamWriter, that does
not do namespace repairing, ie doesn't try to resolve possible
conflicts between prefixes and namespace URIs, or automatically
create namespace bindings.
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public final void | copyStartElement(InputElementStack elemStack, AttributeCollector attrCollector)
Implements abstract com. Element copier method implementation suitable to be used with namespace-aware writers in non-repairing (explicit namespaces) mode. |
| public void | doSetPrefix(String prefix, String uri)
Implements abstract com.
|
| public void | setDefaultNamespace(String
the uri to bind to the default namespace, may be null uri)Implements abstract com. Implements javax. Binds a URI to the default namespace This URI is bound in the scope of the current START_ELEMENT / END_ELEMENT pair. |
| public String | validateQNamePrefix(QName name)
Implements abstract com. Method called before writing a QName via Typed Access API. |
| public void | writeAttribute(String
the uri of the prefix for this attribute nsURI, String the local name of the attribute localName, String the value of the attribute value)Implements abstract com. Implements javax. Writes an attribute to the output stream |
| public void | writeAttribute(String
the prefix for this attribute prefix, String the uri of the prefix for this attribute nsURI, String the local name of the attribute localName, String the value of the attribute value)Implements abstract com. Implements javax. Writes an attribute to the output stream |
| public void | writeDefaultNamespace(String
the uri to bind the default namespace to nsURI)Implements abstract com. Implements javax. Writes the default namespace to the stream |
| public void | writeNamespace(String
the prefix to bind this namespace to prefix, String the uri to bind the prefix to nsURI)Implements abstract com. Implements javax. Writes a namespace to the output stream If the prefix argument to this method is the empty string, "xmlns", or null this method will delegate to writeDefaultNamespace |
| public void | writeStartElement(StartElement elem)
Implements abstract com. Convenience method needed by |
| protected void | writeStartOrEmpty(String localName, String nsURI)
Implements abstract com.
|
| protected void | writeStartOrEmpty(String prefix, String localName, String nsURI)
Implements abstract com.
|
| SimpleNsStreamWriter | back to summary |
|---|---|
| public SimpleNsStreamWriter(XmlWriter xw, String enc, WriterConfig cfg) | |
| copyStartElement | back to summary |
|---|---|
| public final void copyStartElement(InputElementStack elemStack, AttributeCollector attrCollector) throws IOException, XMLStreamException Implements abstract com. Element copier method implementation suitable to be used with
namespace-aware writers in non-repairing (explicit namespaces) mode.
The trickiest thing is having to properly
order calls to
| |
| doSetPrefix | back to summary |
|---|---|
| public void doSetPrefix(String prefix, String uri) throws XMLStreamException Implements abstract com.
| |
| setDefaultNamespace | back to summary |
|---|---|
| public void setDefaultNamespace(String uri) throws XMLStreamException Implements abstract com. Implements javax. Doc from javax. 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.
| |
| validateQNamePrefix | back to summary |
|---|---|
| public String validateQNamePrefix(QName name) Implements abstract com. Doc from com. Method called before writing a QName via Typed Access API. In namespace-repairing mode it should take appropriate actions to ensure that the given namespace URI is bound to a namespace and return whatever it maps to. In non-repairing work no additional work is to be done and methods | |
| writeAttribute | back to summary |
|---|---|
| public void writeAttribute(String nsURI, String localName, String value) throws XMLStreamException Implements abstract com. Implements javax. Doc from javax. Writes an attribute to the output stream
| |
| writeAttribute | back to summary |
|---|---|
| public void writeAttribute(String prefix, String nsURI, String localName, String value) throws XMLStreamException Implements abstract com. Implements javax. Doc from javax. Writes an attribute to the output stream
| |
| writeDefaultNamespace | back to summary |
|---|---|
| public void writeDefaultNamespace(String nsURI) throws XMLStreamException Implements abstract com. Implements javax. Doc from javax. Writes the default namespace to the stream
| |
| writeNamespace | back to summary |
|---|---|
| public void writeNamespace(String prefix, String nsURI) throws XMLStreamException Implements abstract com. Implements javax. Doc from javax. Writes a namespace to the output stream If the prefix argument to this method is the empty string, "xmlns", or null this method will delegate to writeDefaultNamespace
| |
| writeStartElement | back to summary |
|---|---|
| public void writeStartElement(StartElement elem) throws XMLStreamException Implements abstract com. Doc from com. Convenience method needed by
| |
| writeStartOrEmpty | back to summary |
|---|---|
| protected void writeStartOrEmpty(String localName, String nsURI) throws XMLStreamException Implements abstract com.
| |
| writeStartOrEmpty | back to summary |
|---|---|
| protected void writeStartOrEmpty(String prefix, String localName, String nsURI) throws XMLStreamException Implements abstract com.
| |