Interface Serializer

All Known Implementing Classes:
AbstractSerializer, DocumentSerializer, TransformSerializer

public interface Serializer
Converts Strings into Nodes and visa versa.
  • Method Details

    • setCanonicalizer

      void setCanonicalizer(Canonicalizer canon)
      Set the Canonicalizer object to use.
    • serializeToByteArray

      byte[] serializeToByteArray(Element element) throws Exception
      Returns a byte[] representation of the specified Element.
      Parameters:
      element - the Element to serialize.
      Returns:
      the byte[] representation of the serilaized Element.
      Throws:
      Exception
    • serializeToByteArray

      byte[] serializeToByteArray(NodeList content) throws Exception
      Returns a byte[] representation of the specified NodeList.
      Parameters:
      content - the NodeList to serialize.
      Returns:
      the byte[] representation of the serialized NodeList.
      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, IOException
      Parameters:
      source -
      ctx -
      Returns:
      the Node resulting from the parse of the source
      Throws:
      XMLEncryptionException
      IOException