Package com.sun.xml.rpc.streaming
Interface XMLWriter
- All Known Implementing Classes:
FastInfosetWriter
,PrettyPrintingXMLWriterImpl
,StAXWriter
,XmlTreeWriter
,XMLWriterBase
,XMLWriterImpl
public interface XMLWriter
The XMLWriter interface is used to write XML documents.
Concrete XMLWriters can be created using a XMLWriterFactory.
- Author:
- JAX-RPC Development Team
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
Close the writer and its underlying stream.void
Write the end tag for the current element.void
flush()
Flush the writer and its underlying stream.Return a prefix for the given URI.Return the prefix factory in use by this writer.Return the URI for a given prefix.void
setPrefixFactory
(PrefixFactory factory) Set the prefix factory to be used by this writer.void
startElement
(String localName) Write the start tag for an element.void
startElement
(String localName, String uri) Write the start tag for an element.void
startElement
(String localName, String uri, String prefix) Write the start tag for an element.void
startElement
(QName name) Write the start tag for an element.void
startElement
(QName name, String prefix) Write the start tag for an element.void
writeAttribute
(String localName, String value) Write an attribute of the current element.void
writeAttribute
(String localName, String uri, String value) Write an attribute of the current element.void
writeAttribute
(QName name, String value) Write an attribute of the current element.void
writeAttributeUnquoted
(String localName, String value) Write an attribute (unquoted) of the current element.void
writeAttributeUnquoted
(String localName, String uri, String value) Write an attribute (unquoted) of the current element.void
writeAttributeUnquoted
(QName name, String value) Write an attribute (unquoted) of the current element.void
writeChars
(CDATA chars) Write character data within an element.void
writeChars
(String chars) Write character data within an element.void
writeCharsUnquoted
(char[] buf, int offset, int len) Write character data within an element, skipping quoting.void
writeCharsUnquoted
(String chars) Write character data within an element, skipping quoting.void
writeComment
(String comment) Write a comment within an element.void
Write a namespace declaration of the current element.void
writeNamespaceDeclaration
(String prefix, String uri) Write a namespace declaration of the current element.
-
Method Details
-
startElement
Write the start tag for an element. -
startElement
Write the start tag for an element. -
startElement
Write the start tag for an element. -
startElement
Write the start tag for an element. -
startElement
Write the start tag for an element. -
writeAttribute
Write an attribute of the current element. -
writeAttribute
Write an attribute of the current element. -
writeAttribute
Write an attribute of the current element. -
writeAttributeUnquoted
Write an attribute (unquoted) of the current element. -
writeAttributeUnquoted
Write an attribute (unquoted) of the current element. -
writeAttributeUnquoted
Write an attribute (unquoted) of the current element. -
writeNamespaceDeclaration
Write a namespace declaration of the current element. -
writeNamespaceDeclaration
Write a namespace declaration of the current element. The prefix name will be generated by the PrefixFactory currently configured for this writer. -
writeChars
Write character data within an element. -
writeChars
Write character data within an element. -
writeCharsUnquoted
Write character data within an element, skipping quoting. -
writeCharsUnquoted
void writeCharsUnquoted(char[] buf, int offset, int len) Write character data within an element, skipping quoting. -
writeComment
Write a comment within an element. -
endElement
void endElement()Write the end tag for the current element. -
getPrefixFactory
PrefixFactory getPrefixFactory()Return the prefix factory in use by this writer. -
setPrefixFactory
Set the prefix factory to be used by this writer. -
getURI
Return the URI for a given prefix. If the prefix is undeclared, return null. -
getPrefix
Return a prefix for the given URI.If no prefix for the given URI is in scope, return null.
-
flush
void flush()Flush the writer and its underlying stream. -
close
void close()Close the writer and its underlying stream.
-