org.apache.axiom.om
Interface OMSerializable
- All Known Subinterfaces:
- OMComment, OMContainer, OMContainerEx, OMDocType, OMDocument, OMElement, OMNode, OMNodeEx, OMProcessingInstruction, OMSourcedElement, OMText, SOAPBody, SOAPEnvelope, SOAPFault, SOAPFaultClassifier, SOAPFaultCode, SOAPFaultDetail, SOAPFaultNode, SOAPFaultReason, SOAPFaultRole, SOAPFaultSubCode, SOAPFaultText, SOAPFaultValue, SOAPHeader, SOAPHeaderBlock, SOAPMessage
- All Known Implementing Classes:
- AttrImpl, CDATASectionImpl, CharacterImpl, ChildNode, CommentImpl, DocumentFragmentImpl, DocumentImpl, DocumentTypeImpl, ElementImpl, NodeImpl, OMCommentImpl, OMDocTypeImpl, OMDocumentImpl, OMElementImpl, OMNodeImpl, OMProcessingInstructionImpl, OMSerializableImpl, OMSourcedElementImpl, OMTextImpl, ParentNode, ProcessingInstructionImpl, SOAP11BodyImpl, SOAP11BodyImpl, SOAP11FaultCodeImpl, SOAP11FaultCodeImpl, SOAP11FaultDetailImpl, SOAP11FaultDetailImpl, SOAP11FaultImpl, SOAP11FaultImpl, SOAP11FaultReasonImpl, SOAP11FaultReasonImpl, SOAP11FaultRoleImpl, SOAP11FaultRoleImpl, SOAP11FaultSubCodeImpl, SOAP11FaultSubCodeImpl, SOAP11FaultTextImpl, SOAP11FaultTextImpl, SOAP11FaultValueImpl, SOAP11FaultValueImpl, SOAP11HeaderBlockImpl, SOAP11HeaderBlockImpl, SOAP11HeaderImpl, SOAP11HeaderImpl, SOAP12BodyImpl, SOAP12BodyImpl, SOAP12FaultCodeImpl, SOAP12FaultCodeImpl, SOAP12FaultDetailImpl, SOAP12FaultDetailImpl, SOAP12FaultImpl, SOAP12FaultImpl, SOAP12FaultNodeImpl, SOAP12FaultNodeImpl, SOAP12FaultReasonImpl, SOAP12FaultReasonImpl, SOAP12FaultRoleImpl, SOAP12FaultRoleImpl, SOAP12FaultSubCodeImpl, SOAP12FaultSubCodeImpl, SOAP12FaultTextImpl, SOAP12FaultTextImpl, SOAP12FaultValueImpl, SOAP12FaultValueImpl, SOAP12HeaderBlockImpl, SOAP12HeaderBlockImpl, SOAP12HeaderImpl, SOAP12HeaderImpl, SOAPBodyImpl, SOAPBodyImpl, SOAPElement, SOAPElement, SOAPEnvelopeImpl, SOAPEnvelopeImpl, SOAPFaultCodeImpl, SOAPFaultCodeImpl, SOAPFaultDetailImpl, SOAPFaultDetailImpl, SOAPFaultImpl, SOAPFaultImpl, SOAPFaultNodeImpl, SOAPFaultNodeImpl, SOAPFaultReasonImpl, SOAPFaultReasonImpl, SOAPFaultRoleImpl, SOAPFaultRoleImpl, SOAPFaultSubCodeImpl, SOAPFaultSubCodeImpl, SOAPFaultTextImpl, SOAPFaultTextImpl, SOAPFaultValueImpl, SOAPFaultValueImpl, SOAPHeaderBlockImpl, SOAPHeaderBlockImpl, SOAPHeaderImpl, SOAPHeaderImpl, SOAPMessageImpl, SOAPMessageImpl, SOAPTextImpl, SOAPTextImpl, TextImpl, TextNodeImpl
public interface OMSerializable
Information item that can be serialized (written to an XML stream writer) and
deserialized (retrieved from an XML parser) as a unit.
This is the common super-interface for OMDocument
and OMNode
.
Note that OMAttribute
and OMNamespace
are information items that don't
match the definition of this interface because they can only be read from the parser
as part of a larger unit, namely an element.
In accordance with the definition given above, this interface declares two sets of methods:
- Methods allowing to control whether the information item has been completely built,
i.e. whether all events corresponding to the information item have been retrieved
from the parser.
- Methods to write the StAX events corresponding to the information item to an
XMLStreamWriter
.
getOMFactory
OMFactory getOMFactory()
- Returns the OMFactory that created this object
isComplete
boolean isComplete()
- Indicates whether parser has parsed this information item completely or not. If some info are
not available in the item, one has to check this attribute to make sure that, this item has been
parsed completely or not.
- Returns:
- Returns boolean.
build
void build()
- Builds itself.
close
void close(boolean build)
- If a builder and parser is associated with the node, it is closed.
- Parameters:
build
- if true, the object is built first before closing the builder/parser
serialize
void serialize(XMLStreamWriter xmlWriter)
throws XMLStreamException
- Serializes the information item with caching. This method has the same effect as
serialize(XMLStreamWriter, boolean)
with cache
set to
true
.
- Parameters:
xmlWriter
-
- Throws:
XMLStreamException
serializeAndConsume
void serializeAndConsume(XMLStreamWriter xmlWriter)
throws XMLStreamException
- Serializes the information item without caching. This method has the same effect as
serialize(XMLStreamWriter, boolean)
with cache
set to
false
.
- Parameters:
xmlWriter
-
- Throws:
XMLStreamException
serialize
void serialize(XMLStreamWriter xmlWriter,
boolean cache)
throws XMLStreamException
- Serializes the information item.
- Parameters:
xmlWriter
- cache
- indicates if caching should be enabled
- Throws:
XMLStreamException
Copyright © 2004-2013 The Apache Software Foundation. All Rights Reserved.