Package org.apache.cxf.aegis.xml
Interface MessageWriter
-
- All Known Implementing Classes:
AbstractMessageWriter,AttributeWriter,AttributeWriter,ElementWriter
public interface MessageWriterWrites messages to an output stream.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidclose()Tells the MessageWriter that writing operations are completed so it can write the end element.MessageWritergetAttributeWriter(String name)MessageWritergetAttributeWriter(String name, String namespace)MessageWritergetAttributeWriter(QName qname)MessageWritergetElementWriter(String name)MessageWritergetElementWriter(String name, String namespace)MessageWritergetElementWriter(QName qname)StringgetPrefixForNamespace(String namespace)StringgetPrefixForNamespace(String namespace, String hint)Get a prefix for a namespace.voidwriteValue(Object value)voidwriteValueAsBoolean(boolean b)voidwriteValueAsByte(Byte b)voidwriteValueAsCharacter(Character char1)voidwriteValueAsDouble(Double double1)voidwriteValueAsFloat(Float f)voidwriteValueAsInt(Integer i)voidwriteValueAsLong(Long l)voidwriteValueAsShort(Short short1)voidwriteXsiNil()voidwriteXsiType(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 Detail
-
writeValue
void writeValue(Object value)
-
writeValueAsInt
void writeValueAsInt(Integer i)
-
writeValueAsCharacter
void writeValueAsCharacter(Character char1)
-
writeValueAsDouble
void writeValueAsDouble(Double double1)
-
writeValueAsLong
void writeValueAsLong(Long l)
-
writeValueAsFloat
void writeValueAsFloat(Float f)
-
writeValueAsShort
void writeValueAsShort(Short short1)
-
writeValueAsByte
void writeValueAsByte(Byte b)
-
writeValueAsBoolean
void writeValueAsBoolean(boolean b)
-
getAttributeWriter
MessageWriter getAttributeWriter(String name)
-
getAttributeWriter
MessageWriter getAttributeWriter(String name, String namespace)
-
getAttributeWriter
MessageWriter getAttributeWriter(QName qname)
-
getElementWriter
MessageWriter getElementWriter(String name)
-
getElementWriter
MessageWriter getElementWriter(String name, String namespace)
-
getElementWriter
MessageWriter getElementWriter(QName qname)
-
getPrefixForNamespace
String getPrefixForNamespace(String namespace, String hint)
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
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."- Parameters:
qn- the QName of the type being referenced.
-
writeXsiNil
void writeXsiNil()
-
-