Package org.apache.cxf.aegis.xml
Interface MessageWriter
- All Known Implementing Classes:
AbstractMessageWriter
,AttributeWriter
,AttributeWriter
,ElementWriter
public interface MessageWriter
Writes messages to an output stream.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
Tells the MessageWriter that writing operations are completed so it can write the end element.getAttributeWriter
(String name) getAttributeWriter
(String name, String namespace) getAttributeWriter
(QName qname) getElementWriter
(String name) getElementWriter
(String name, String namespace) getElementWriter
(QName qname) getPrefixForNamespace
(String namespace) getPrefixForNamespace
(String namespace, String hint) Get a prefix for a namespace.void
writeValue
(Object value) void
writeValueAsBoolean
(boolean b) void
void
writeValueAsCharacter
(Character char1) void
writeValueAsDouble
(Double double1) void
void
void
void
writeValueAsShort
(Short short1) void
void
writeXsiType
(QName qn) As per 2.6.1 in XML Schema Part 1: "An element information item in an instance may, however, explicitly assert its type using the attributexsi:type
."
-
Method Details
-
writeValue
-
writeValueAsInt
-
writeValueAsCharacter
-
writeValueAsDouble
-
writeValueAsLong
-
writeValueAsFloat
-
writeValueAsShort
-
writeValueAsByte
-
writeValueAsBoolean
void writeValueAsBoolean(boolean b) -
getAttributeWriter
-
getAttributeWriter
-
getAttributeWriter
-
getElementWriter
-
getElementWriter
-
getElementWriter
-
getPrefixForNamespace
-
getPrefixForNamespace
Get a prefix for a namespace. After calling this, the prefix returned is registered with the namespace. This method will make an attempt to use the hint prefix if possible. If the namespace is already registered or the hint is already registered with a different namespace then the behavior will be the same as the non-hint version.- Parameters:
namespace
- the namespace to retrieve the prefix forhint
- the hint for the prefix.- Returns:
- the prefix associated with the namespace
-
close
void close()Tells the MessageWriter that writing operations are completed so it can write the end element. -
writeXsiType
As per 2.6.1 in XML Schema Part 1: "An element information item in an instance may, however, explicitly assert its type using the attributexsi:type
."- Parameters:
qn
- the QName of the type being referenced.
-
writeXsiNil
void writeXsiNil()
-