Class StaxSerializer

  • All Implemented Interfaces:
    org.apache.xml.security.encryption.Serializer

    public class StaxSerializer
    extends org.apache.xml.security.encryption.AbstractSerializer
    Converts Strings into Nodes and visa versa using CXF's StaxUtils
    • Constructor Detail

      • StaxSerializer

        public StaxSerializer()
                       throws org.apache.xml.security.c14n.InvalidCanonicalizerException
        Throws:
        org.apache.xml.security.c14n.InvalidCanonicalizerException
    • Method Detail

      • deserialize

        public Node deserialize​(byte[] source,
                                Node ctx)
                         throws org.apache.xml.security.encryption.XMLEncryptionException
        Parameters:
        source -
        ctx -
        Returns:
        the Node resulting from the parse of the source
        Throws:
        org.apache.xml.security.encryption.XMLEncryptionException
      • serializeToByteArray

        public byte[] serializeToByteArray​(Element element)
                                    throws Exception
        Specified by:
        serializeToByteArray in interface org.apache.xml.security.encryption.Serializer
        Overrides:
        serializeToByteArray in class org.apache.xml.security.encryption.AbstractSerializer
        Throws:
        Exception