|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
An XML Serializer is used to marshal a fixed subclass of JMElement. It is unable to marshal generic JMElements. The XML Serializer is typically created by the Manager.
Nested Class Summary | |
static interface |
JMXmlSerializer.Data
|
Method Summary | |
JMXmlSerializer.Data |
getData(JMMarshaller pMarshaller,
org.xml.sax.ContentHandler pHandler)
Initializes the marshalling stage by creating an instance of JMXmlSerializerData. |
java.lang.String |
getPreferredPrefix(java.lang.String pURI)
Returns a suggested prefix for the given URI. |
void |
init(JAXBContextImpl pFactory)
Initializes the JMXmlSerializer; called by the JAXBContextImpl before the serializer is returned to the Marshaller. |
void |
marshal(JMXmlSerializer.Data pData,
QName pName,
java.lang.Object pElement)
Marshals the given JMElement. |
Method Detail |
public void init(JAXBContextImpl pFactory) throws JAXBException
Initializes the JMXmlSerializer; called by the JAXBContextImpl before the serializer is returned to the Marshaller. This method must be called only once.
JAXBException
public java.lang.String getPreferredPrefix(java.lang.String pURI)
Returns a suggested prefix for the given URI.
public JMXmlSerializer.Data getData(JMMarshaller pMarshaller, org.xml.sax.ContentHandler pHandler)
Initializes the marshalling stage by creating an instance of JMXmlSerializerData.
pMarshaller
- The Marshaller controlling the marshalling
process. In particular it will be used as an object factory
(via its getContext()
method) and for reading
settings like indentation and the like.pHandler
- The ContentHandler thatpublic void marshal(JMXmlSerializer.Data pData, QName pName, java.lang.Object pElement) throws org.xml.sax.SAXException
Marshals the given JMElement.
pData
- An instance of JMXmlSerializerData that was
obtained by calling getData(JMMarshaller,
ContentHandler)
.pElement
- The element being marshalled. It must be
an instance of the class associated to this specific
JMXmlSerializer.
org.xml.sax.SAXException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |