net.sf.eos.document
Class XmlSerializer
java.lang.Object
net.sf.eos.config.Configured
net.sf.eos.document.Serializer
net.sf.eos.document.XmlSerializer
- All Implemented Interfaces:
- Configurable
public class XmlSerializer
- extends Serializer
Serializer and deserializer for an EosDocument
. See
XmlSerializer.ElementName
for element names. The order of the elements in
the root container are not defined. Also the order in the meta container
is not defined. If the root container contains more than one title
or text element, the latest elements may win. If the meta container
contains more than one key, the latest may win.
- Author:
- Sascha Kohlmann
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XmlSerializer
public XmlSerializer()
serialize
public void serialize(EosDocument doc,
Writer out)
throws IOException
- Description copied from class:
Serializer
- Implementations serializes the content of an
EosDocument
thru the given writer
- Specified by:
serialize
in class Serializer
- Parameters:
doc
- the document to serializeout
- the sink to write the content thru
- Throws:
IOException
- if something goes wrong during serialization
deserialize
public EosDocument deserialize(Reader in)
throws IOException,
ParserConfigurationException,
SAXException
- Description copied from class:
Serializer
- Implementations must deserialize a
EosDocument
which are
serialized by Serializer.serialize(EosDocument,Writer)
.
- Specified by:
deserialize
in class Serializer
- Parameters:
in
- the stream to read the EosDocument
content from
- Returns:
- a
EosDocument
constructed form the content
- Throws:
IOException
- if in occurs an error
ParserConfigurationException
SAXException
Copyright © 2008. All Rights Reserved.