public abstract class DOMWrappingWriter extends Object implements XMLStreamWriter2
XMLStreamWriter
as a facade on top of a DOM document or Node, allowing one
to basically construct DOM trees via Stax API.
It is meant to serve as basis for a full implementation.
Note that the implementation is only to be used with
javax.xml.transform.dom.DOMResult. It can however be
used for both full documents, and single element root fragments,
depending on what node is passed as the argument.
>p>
One more implementation note: much code is identical to one
used by Stax2WriterAdapter.
Alas it is hard to reuse it without cut'n pasting.
| Modifier and Type | Field and Description |
|---|---|
protected Document |
mDocument
We need a reference to the document hosting nodes to
be able to create new nodes
|
protected String |
mEncoding
This member variable is to keep information about encoding
that seems to be used for the document (or fragment) to output,
if known.
|
protected boolean |
mNsAware |
protected NamespaceContext |
mNsContext
If we are being given info about existing bindings, it'll come
as a NamespaceContext.
|
protected boolean |
mNsRepairing |
protected SimpleValueEncoder |
mValueEncoder
Encoding of typed values is used the standard encoder
included in RI.
|
| Modifier | Constructor and Description |
|---|---|
protected |
DOMWrappingWriter(Node treeRoot,
boolean nsAware,
boolean nsRepairing) |
| Modifier and Type | Method and Description |
|---|---|
protected abstract void |
appendLeaf(Node n) |
void |
close() |
void |
closeCompletely()
Method similar to
XMLStreamWriter.close(),
except that this method also does close the underlying output
destination (stream) if it has not yet been closed. |
void |
copyEventFromReader(XMLStreamReader2 r,
boolean preserveEventData)
Method that essentially copies
event that the specified reader has just read.
|
void |
flush() |
String |
getEncoding()
Method that can be called to get information about encoding that
this writer is using (or at least claims is using).
|
XMLStreamLocation2 |
getLocation()
Method that should return current output location, if the writer
keeps track of it; null if it does not.
|
abstract NamespaceContext |
getNamespaceContext() |
abstract String |
getPrefix(String uri) |
abstract Object |
getProperty(String name) |
protected SimpleValueEncoder |
getValueEncoder() |
abstract boolean |
isPropertySupported(String name)
Method similar to
XMLOutputFactory.isPropertySupported(java.lang.String), used
to determine whether a property is supported by the Writer
instance. |
protected void |
reportUnsupported(String operName) |
protected String |
serializeQNameValue(QName name)
Method called to serialize given qualified name into valid
String serialization, taking into account existing namespace
bindings.
|
abstract void |
setDefaultNamespace(String uri) |
void |
setNamespaceContext(NamespaceContext context) |
abstract void |
setPrefix(String prefix,
String uri) |
abstract boolean |
setProperty(String name,
Object value)
Method that can be used to set per-writer properties; a subset of
properties one can set via matching
XMLOutputFactory2
instance. |
ValidationProblemHandler |
setValidationProblemHandler(ValidationProblemHandler h)
Method that application can call to define a custom handler for
validation problems encountered during validation process.
|
XMLValidator |
stopValidatingAgainst(XMLValidationSchema schema)
Method that can be called by application to stop validating
output against a schema, for which
Validatable.validateAgainst(org.codehaus.stax2.validation.XMLValidationSchema)
was called earlier. |
XMLValidator |
stopValidatingAgainst(XMLValidator validator)
Method that can be called by application to stop validating
output using specified validator.
|
protected static void |
throwOutputError(String msg) |
protected static void |
throwOutputError(String format,
Object arg) |
XMLValidator |
validateAgainst(XMLValidationSchema schema)
Method that will construct a
XMLValidator instance from the
given schema (unless a validator for that schema has already been
added),
initialize it if necessary, and make validatable object (reader,
writer)
call appropriate validation methods from this point on until the
end of the document (that is, it's not scoped with sub-trees), or until
validator is removed by an explicit call to
Validatable.stopValidatingAgainst(org.codehaus.stax2.validation.XMLValidationSchema). |
abstract void |
writeAttribute(String localName,
String value) |
abstract void |
writeAttribute(String nsURI,
String localName,
String value) |
abstract void |
writeAttribute(String prefix,
String nsURI,
String localName,
String value) |
void |
writeBinary(Base64Variant v,
byte[] value,
int from,
int length) |
void |
writeBinary(byte[] value,
int from,
int length)
Write binary content as base64 encoded characters to the output.
|
void |
writeBinaryAttribute(Base64Variant v,
String prefix,
String nsURI,
String localName,
byte[] value) |
void |
writeBinaryAttribute(String prefix,
String nsURI,
String localName,
byte[] value)
Write a byte array attribute.
|
void |
writeBoolean(boolean value)
Write a boolean value to the output as textual element content.
|
void |
writeBooleanAttribute(String prefix,
String nsURI,
String localName,
boolean value)
Write a boolean value to the output as attribute value.
|
void |
writeCData(char[] text,
int start,
int len) |
void |
writeCData(String data) |
void |
writeCharacters(char[] text,
int start,
int len) |
void |
writeCharacters(String text) |
void |
writeComment(String data) |
void |
writeDecimal(BigDecimal value)
Write a decimal value to the output as textual element content.
|
void |
writeDecimalAttribute(String prefix,
String nsURI,
String localName,
BigDecimal value) |
abstract void |
writeDefaultNamespace(String nsURI) |
void |
writeDouble(double value)
Write a double value to the output as textual element content.
|
void |
writeDoubleArray(double[] value,
int from,
int length) |
void |
writeDoubleArrayAttribute(String prefix,
String nsURI,
String localName,
double[] value) |
void |
writeDoubleAttribute(String prefix,
String nsURI,
String localName,
double value) |
void |
writeDTD(String dtd) |
abstract void |
writeDTD(String rootName,
String systemId,
String publicId,
String internalSubset) |
abstract void |
writeEmptyElement(String localName) |
abstract void |
writeEmptyElement(String nsURI,
String localName) |
abstract void |
writeEmptyElement(String prefix,
String localName,
String nsURI) |
abstract void |
writeEndDocument() |
void |
writeEntityRef(String name) |
void |
writeFloat(float value)
Write a float value to the output as textual element content.
|
void |
writeFloatArray(float[] value,
int from,
int length) |
void |
writeFloatArrayAttribute(String prefix,
String nsURI,
String localName,
float[] value) |
void |
writeFloatAttribute(String prefix,
String nsURI,
String localName,
float value) |
void |
writeFullEndElement()
Method similar to
XMLStreamWriter.writeEndElement(), but that will always
write the full end element, instead of empty element. |
void |
writeInt(int value)
Write an int value to the output as textual element content.
|
void |
writeIntArray(int[] value,
int from,
int length)
Write int array to the output.
|
void |
writeIntArrayAttribute(String prefix,
String nsURI,
String localName,
int[] value)
Write int array attribute.
|
void |
writeIntAttribute(String prefix,
String nsURI,
String localName,
int value)
Write an integer value to the output as attribute value.
|
void |
writeInteger(BigInteger value) |
void |
writeIntegerAttribute(String prefix,
String nsURI,
String localName,
BigInteger value) |
void |
writeLong(long value)
Write a long value to the output as textual element content.
|
void |
writeLongArray(long[] value,
int from,
int length) |
void |
writeLongArrayAttribute(String prefix,
String nsURI,
String localName,
long[] value) |
void |
writeLongAttribute(String prefix,
String nsURI,
String localName,
long value)
Write an long value to the output as attribute value.
|
void |
writeProcessingInstruction(String target) |
void |
writeProcessingInstruction(String target,
String data) |
void |
writeQName(QName name) |
void |
writeQNameAttribute(String prefix,
String nsURI,
String localName,
QName name) |
void |
writeRaw(char[] text,
int offset,
int length)
Method that writes specified content as is, without encoding or
deciphering it in any way.
|
void |
writeRaw(String text)
Method that writes specified content as is, without encoding or
deciphering it in any way.
|
void |
writeRaw(String text,
int start,
int offset)
Method that writes specified content as is, without encoding or
deciphering it in any way.
|
void |
writeSpace(char[] text,
int start,
int len)
Method that can be called to write whitespace-only content.
|
void |
writeSpace(String text)
Method that can be called to write whitespace-only content.
|
void |
writeStartDocument() |
void |
writeStartDocument(String version) |
void |
writeStartDocument(String encoding,
String version) |
void |
writeStartDocument(String version,
String encoding,
boolean standAlone) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitwriteEndElement, writeNamespace, writeStartElement, writeStartElement, writeStartElementprotected final boolean mNsAware
protected final boolean mNsRepairing
protected String mEncoding
protected NamespaceContext mNsContext
protected final Document mDocument
protected SimpleValueEncoder mValueEncoder
protected DOMWrappingWriter(Node treeRoot, boolean nsAware, boolean nsRepairing) throws XMLStreamException
XMLStreamExceptionpublic void close()
close in interface XMLStreamWriterpublic void flush()
flush in interface XMLStreamWriterpublic abstract NamespaceContext getNamespaceContext()
getNamespaceContext in interface XMLStreamWriterpublic abstract String getPrefix(String uri)
getPrefix in interface XMLStreamWriterpublic abstract Object getProperty(String name)
getProperty in interface XMLStreamWriterpublic abstract void setDefaultNamespace(String uri)
setDefaultNamespace in interface XMLStreamWriterpublic void setNamespaceContext(NamespaceContext context)
setNamespaceContext in interface XMLStreamWriterpublic abstract void setPrefix(String prefix, String uri) throws XMLStreamException
setPrefix in interface XMLStreamWriterXMLStreamExceptionpublic abstract void writeAttribute(String localName, String value) throws XMLStreamException
writeAttribute in interface XMLStreamWriterXMLStreamExceptionpublic abstract void writeAttribute(String nsURI, String localName, String value) throws XMLStreamException
writeAttribute in interface XMLStreamWriterXMLStreamExceptionpublic abstract void writeAttribute(String prefix, String nsURI, String localName, String value) throws XMLStreamException
writeAttribute in interface XMLStreamWriterXMLStreamExceptionpublic void writeCData(String data) throws XMLStreamException
writeCData in interface XMLStreamWriterXMLStreamExceptionpublic void writeCharacters(char[] text,
int start,
int len)
throws XMLStreamException
writeCharacters in interface XMLStreamWriterXMLStreamExceptionpublic void writeCharacters(String text) throws XMLStreamException
writeCharacters in interface XMLStreamWriterXMLStreamExceptionpublic void writeComment(String data) throws XMLStreamException
writeComment in interface XMLStreamWriterXMLStreamExceptionpublic abstract void writeDefaultNamespace(String nsURI) throws XMLStreamException
writeDefaultNamespace in interface XMLStreamWriterXMLStreamExceptionpublic void writeDTD(String dtd) throws XMLStreamException
writeDTD in interface XMLStreamWriterXMLStreamExceptionpublic abstract void writeEmptyElement(String localName) throws XMLStreamException
writeEmptyElement in interface XMLStreamWriterXMLStreamExceptionpublic abstract void writeEmptyElement(String nsURI, String localName) throws XMLStreamException
writeEmptyElement in interface XMLStreamWriterXMLStreamExceptionpublic abstract void writeEmptyElement(String prefix, String localName, String nsURI) throws XMLStreamException
writeEmptyElement in interface XMLStreamWriterXMLStreamExceptionpublic abstract void writeEndDocument()
throws XMLStreamException
writeEndDocument in interface XMLStreamWriterXMLStreamExceptionpublic void writeEntityRef(String name) throws XMLStreamException
writeEntityRef in interface XMLStreamWriterXMLStreamExceptionpublic void writeProcessingInstruction(String target) throws XMLStreamException
writeProcessingInstruction in interface XMLStreamWriterXMLStreamExceptionpublic void writeProcessingInstruction(String target, String data) throws XMLStreamException
writeProcessingInstruction in interface XMLStreamWriterXMLStreamExceptionpublic void writeStartDocument()
throws XMLStreamException
writeStartDocument in interface XMLStreamWriterXMLStreamExceptionpublic void writeStartDocument(String version) throws XMLStreamException
writeStartDocument in interface XMLStreamWriterXMLStreamExceptionpublic void writeStartDocument(String encoding, String version) throws XMLStreamException
writeStartDocument in interface XMLStreamWriterXMLStreamExceptionpublic XMLStreamLocation2 getLocation()
XMLStreamWriter2getLocation in interface XMLStreamWriter2public String getEncoding()
XMLStreamWriter2XMLOutputFactory
writeStartDocument method (explicitly
or implicity; latter in cases where defaults are imposed
by Stax specification)
getEncoding in interface XMLStreamWriter2public abstract boolean isPropertySupported(String name)
XMLStreamWriter2XMLOutputFactory.isPropertySupported(java.lang.String), used
to determine whether a property is supported by the Writer
instance. This means that this method may return false
for some properties that the output factory does support: specifically,
it should only return true if the value is mutable on per-instance
basis. False means that either the property is not recognized, or
is not mutable via writer instance.isPropertySupported in interface XMLStreamWriter2public abstract boolean setProperty(String name, Object value)
XMLStreamWriter2XMLOutputFactory2
instance. Exactly which methods are mutable is implementation
specific.setProperty in interface XMLStreamWriter2name - Name of the property to setvalue - Value to set property to.public void writeCData(char[] text,
int start,
int len)
throws XMLStreamException
writeCData in interface XMLStreamWriter2XMLStreamExceptionpublic abstract void writeDTD(String rootName, String systemId, String publicId, String internalSubset) throws XMLStreamException
writeDTD in interface XMLStreamWriter2XMLStreamExceptionpublic void writeFullEndElement()
throws XMLStreamException
XMLStreamWriter2XMLStreamWriter.writeEndElement(), but that will always
write the full end element, instead of empty element. This only
matters for cases where the element itself has no content, and
if writer is allowed to write empty elements when it encounters
such start/end element write pairs.writeFullEndElement in interface XMLStreamWriter2XMLStreamExceptionpublic void writeSpace(char[] text,
int start,
int len)
throws XMLStreamException
XMLStreamWriter2This method is useful for things like outputting indentation.
writeSpace in interface XMLStreamWriter2XMLStreamExceptionpublic void writeSpace(String text) throws XMLStreamException
XMLStreamWriter2This method is useful for things like outputting indentation.
writeSpace in interface XMLStreamWriter2XMLStreamExceptionpublic void writeStartDocument(String version, String encoding, boolean standAlone) throws XMLStreamException
writeStartDocument in interface XMLStreamWriter2XMLStreamExceptionpublic XMLValidator validateAgainst(XMLValidationSchema schema) throws XMLStreamException
ValidatableXMLValidator instance from the
given schema (unless a validator for that schema has already been
added),
initialize it if necessary, and make validatable object (reader,
writer)
call appropriate validation methods from this point on until the
end of the document (that is, it's not scoped with sub-trees), or until
validator is removed by an explicit call to
Validatable.stopValidatingAgainst(org.codehaus.stax2.validation.XMLValidationSchema).
Note that while this method can be called at any point in output processing, validator instances are not required to be able to handle addition at other points than right before outputting the root element.
validateAgainst in interface ValidatableXMLStreamExceptionpublic XMLValidator stopValidatingAgainst(XMLValidationSchema schema) throws XMLStreamException
ValidatableValidatable.validateAgainst(org.codehaus.stax2.validation.XMLValidationSchema)
was called earlier.stopValidatingAgainst in interface ValidatableXMLStreamExceptionpublic XMLValidator stopValidatingAgainst(XMLValidator validator) throws XMLStreamException
ValidatableValidatable.validateAgainst(org.codehaus.stax2.validation.XMLValidationSchema).
Note: the specified validator is compared for identity with validators in use, not for equality.
stopValidatingAgainst in interface Validatablevalidator)
if it was being used for validating current document; null if not.XMLStreamExceptionpublic ValidationProblemHandler setValidationProblemHandler(ValidationProblemHandler h)
ValidatablesetValidationProblemHandler in interface Validatableh - Handler to install, if non null; if null, indicates that
the default (implementation-specific) handling should be usedpublic void writeRaw(String text) throws XMLStreamException
XMLStreamWriter2Method is usually used when encapsulating output from another writer as a sub-tree, or when passing through XML fragments.
NOTE: since text to be written may be anything, including markup, it can not be reliably validated. Because of this, validator(s) attached to the writer will NOT be informed about writes.
writeRaw in interface XMLStreamWriter2XMLStreamExceptionpublic void writeRaw(String text, int start, int offset) throws XMLStreamException
XMLStreamWriter2Method is usually used when encapsulating output from another writer as a sub-tree, or when passing through XML fragments.
NOTE: since text to be written may be anything, including markup, it can not be reliably validated. Because of this, validator(s) attached to the writer will NOT be informed about writes.
writeRaw in interface XMLStreamWriter2XMLStreamExceptionpublic void writeRaw(char[] text,
int offset,
int length)
throws XMLStreamException
XMLStreamWriter2Method is usually used when encapsulating output from another writer as a sub-tree, or when passing through XML fragments.
NOTE: since text to be written may be anything, including markup, it can not be reliably validated. Because of this, validator(s) attached to the writer will NOT be informed about writes.
writeRaw in interface XMLStreamWriter2XMLStreamExceptionpublic void copyEventFromReader(XMLStreamReader2 r, boolean preserveEventData) throws XMLStreamException
XMLStreamWriter2copyEventFromReader in interface XMLStreamWriter2r - Reader to use for accessing event to copypreserveEventData - If true, writer is not allowed to change
the state of the reader (so that all the data associated with the
current event has to be preserved); if false, writer is allowed
to use methods that may cause some data to be discarded. Setting
this to false may improve the performance, since it may allow
full no-copy streaming of data, especially textual contents.XMLStreamExceptionpublic void closeCompletely()
XMLStreamWriter2XMLStreamWriter.close(),
except that this method also does close the underlying output
destination (stream) if it has not yet been closed.
It is specifically necessary to call this method if the parsing ends
in an exception to ensure that the output destination does get
properly closed, even if the stream writer would otherwise close
it (as is the case for destinations it manages where calling
application has no access)closeCompletely in interface XMLStreamWriter2public void writeBoolean(boolean value)
throws XMLStreamException
TypedXMLStreamWriterwriteBoolean in interface TypedXMLStreamWritervalue - The boolean value to write.XMLStreamExceptionpublic void writeInt(int value)
throws XMLStreamException
TypedXMLStreamWriterwriteInt in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeLong(long value)
throws XMLStreamException
TypedXMLStreamWriterwriteLong in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeFloat(float value)
throws XMLStreamException
TypedXMLStreamWriterwriteFloat in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeDouble(double value)
throws XMLStreamException
TypedXMLStreamWriterwriteDouble in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeInteger(BigInteger value) throws XMLStreamException
writeInteger in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeDecimal(BigDecimal value) throws XMLStreamException
TypedXMLStreamWriterwriteDecimal in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeQName(QName name) throws XMLStreamException
writeQName in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeIntArray(int[] value,
int from,
int length)
throws XMLStreamException
TypedXMLStreamWriterWrite int array to the output. The lexical representation of a int array is defined by the following XML schema type:
<xs:simpleType name="intArray">
<xs:list itemType="xs:int"/>
</xs:simpleType>
whose lexical space is a list of space-separated ints.
This method can be called multiple times to write the
array in chunks.writeIntArray in interface TypedXMLStreamWritervalue - The array from which to write the ints.from - The index in the array from which writing starts.length - The number of ints to write.XMLStreamExceptionpublic void writeLongArray(long[] value,
int from,
int length)
throws XMLStreamException
writeLongArray in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeFloatArray(float[] value,
int from,
int length)
throws XMLStreamException
writeFloatArray in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeDoubleArray(double[] value,
int from,
int length)
throws XMLStreamException
writeDoubleArray in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeBinary(byte[] value,
int from,
int length)
throws XMLStreamException
TypedXMLStreamWriterWrite binary content as base64 encoded characters to the output. The lexical representation of a byte array is defined by the XML Schema base64Binary data type. This method can be called multiple times to write the array in chunks; but if so, callers should write output in chunks divisible by 3 (natural atomic unit of base64 output, which avoids padding) to maximize interoperability.
Note: base64 variant defaults to Base64Variants.MIME.
writeBinary in interface TypedXMLStreamWritervalue - The array from which to write the bytes.from - The index in the array from which writing starts.length - The number of bytes to write.XMLStreamExceptionpublic void writeBinary(Base64Variant v, byte[] value, int from, int length) throws XMLStreamException
writeBinary in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeBooleanAttribute(String prefix, String nsURI, String localName, boolean value) throws XMLStreamException
TypedXMLStreamWriterwriteBooleanAttribute in interface TypedXMLStreamWriterprefix - The attribute's prefix. Null or "" if no prefix is to be usednsURI - The attribute's URI (can be either null or empty String for "no namespace")localName - The attribute's local namevalue - The boolean value to write.XMLStreamExceptionpublic void writeIntAttribute(String prefix, String nsURI, String localName, int value) throws XMLStreamException
TypedXMLStreamWriterwriteIntAttribute in interface TypedXMLStreamWriterprefix - The attribute's prefix. Null or "" if no prefix is to be usednsURI - The attribute's URI (can be either null or empty String for "no namespace")localName - The attribute's local namevalue - The integer value to write.XMLStreamExceptionpublic void writeLongAttribute(String prefix, String nsURI, String localName, long value) throws XMLStreamException
TypedXMLStreamWriterwriteLongAttribute in interface TypedXMLStreamWriterprefix - The attribute's prefix. Null or "" if no prefix is to be usednsURI - The attribute's URI (can be either null or empty String for "no namespace")localName - The attribute's local namevalue - The long value to write.XMLStreamExceptionpublic void writeFloatAttribute(String prefix, String nsURI, String localName, float value) throws XMLStreamException
writeFloatAttribute in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeDoubleAttribute(String prefix, String nsURI, String localName, double value) throws XMLStreamException
writeDoubleAttribute in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeIntegerAttribute(String prefix, String nsURI, String localName, BigInteger value) throws XMLStreamException
writeIntegerAttribute in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeDecimalAttribute(String prefix, String nsURI, String localName, BigDecimal value) throws XMLStreamException
writeDecimalAttribute in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeQNameAttribute(String prefix, String nsURI, String localName, QName name) throws XMLStreamException
writeQNameAttribute in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeIntArrayAttribute(String prefix, String nsURI, String localName, int[] value) throws XMLStreamException
TypedXMLStreamWriterWrite int array attribute. The lexical representation of a int array is defined by the following XML schema type:
<xs:simpleType name="intArray">
<xs:list itemType="xs:int"/>
</xs:simpleType>
whose lexical space is a list of space-separated ints.writeIntArrayAttribute in interface TypedXMLStreamWriterprefix - The attribute's prefix.nsURI - The attribute's URI.localName - The attribute's local name.value - The array from which to write the ints.XMLStreamExceptionpublic void writeLongArrayAttribute(String prefix, String nsURI, String localName, long[] value) throws XMLStreamException
writeLongArrayAttribute in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeFloatArrayAttribute(String prefix, String nsURI, String localName, float[] value) throws XMLStreamException
writeFloatArrayAttribute in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeDoubleArrayAttribute(String prefix, String nsURI, String localName, double[] value) throws XMLStreamException
writeDoubleArrayAttribute in interface TypedXMLStreamWriterXMLStreamExceptionpublic void writeBinaryAttribute(String prefix, String nsURI, String localName, byte[] value) throws XMLStreamException
TypedXMLStreamWriterWrite a byte array attribute. The lexical representation of a byte array is defined by the XML Schema base64Binary data type.
Note: base64 variant defaults to Base64Variants.MIME.
writeBinaryAttribute in interface TypedXMLStreamWriterprefix - The attribute's prefix.nsURI - The attribute's URI.localName - The attribute's local name.value - The array from which to write the bytes.XMLStreamExceptionpublic void writeBinaryAttribute(Base64Variant v, String prefix, String nsURI, String localName, byte[] value) throws XMLStreamException
writeBinaryAttribute in interface TypedXMLStreamWriterXMLStreamExceptionprotected abstract void appendLeaf(Node n) throws IllegalStateException
IllegalStateExceptionprotected String serializeQNameValue(QName name) throws XMLStreamException
XMLStreamExceptionprotected SimpleValueEncoder getValueEncoder()
protected static void throwOutputError(String msg) throws XMLStreamException
XMLStreamExceptionprotected static void throwOutputError(String format, Object arg) throws XMLStreamException
XMLStreamExceptionprotected void reportUnsupported(String operName)
Copyright © 2015 fasterxml.com. All Rights Reserved.