Interface Serializer
-
- All Known Implementing Classes:
AbstractSerializer,DocumentSerializer,TransformSerializer
public interface SerializerConvertsStrings intoNodes and visa versa.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description byte[]canonSerializeToByteArray(Node node)Use the Canonicalizer to serialize the nodeNodedeserialize(byte[] source, Node ctx)byte[]serializeToByteArray(Element element)Returns abyte[]representation of the specifiedElement.byte[]serializeToByteArray(NodeList content)Returns abyte[]representation of the specifiedNodeList.voidsetCanonicalizer(Canonicalizer canon)Set the Canonicalizer object to use.
-
-
-
Method Detail
-
setCanonicalizer
void setCanonicalizer(Canonicalizer canon)
Set the Canonicalizer object to use.
-
serializeToByteArray
byte[] serializeToByteArray(Element element) throws Exception
Returns abyte[]representation of the specifiedElement.- Parameters:
element- theElementto serialize.- Returns:
- the
byte[]representation of the serilaizedElement. - Throws:
Exception
-
serializeToByteArray
byte[] serializeToByteArray(NodeList content) throws Exception
Returns abyte[]representation of the specifiedNodeList.- Parameters:
content- theNodeListto serialize.- Returns:
- the
byte[]representation of the serializedNodeList. - Throws:
Exception
-
canonSerializeToByteArray
byte[] canonSerializeToByteArray(Node node) throws Exception
Use the Canonicalizer to serialize the node- Parameters:
node-- Returns:
- the (byte[]) canonicalization of the node
- Throws:
Exception
-
deserialize
Node deserialize(byte[] source, Node ctx) throws XMLEncryptionException
- Parameters:
source-ctx-- Returns:
- the Node resulting from the parse of the source
- Throws:
XMLEncryptionException
-
-