Class XmlEncryptionExtensions


  • public final class XmlEncryptionExtensions
    extends java.lang.Object
    The class XmlEncryptionExtensions provides methods for encrypt data object to the given file as xml and encoded into a hexadecimal String object
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static <T> void writeToFileAsXmlAndHex​(com.thoughtworks.xstream.XStream xstream, java.util.Map<java.lang.String,​java.lang.Class<?>> aliases, T data, java.io.File file)
      Write the given data object to the given file as xml and encoded into a hexadecimal String object.
      static <T> void writeToFileAsXmlAndHex​(com.thoughtworks.xstream.XStream xstream, java.util.Map<java.lang.String,​java.lang.Class<?>> aliases, T data, java.io.File file, java.lang.String charset)
      Write the given data object to the given file as xml and encoded into a hexadecimal String object.
      static <T> void writeToFileAsXmlAndHex​(java.util.Map<java.lang.String,​java.lang.Class<?>> aliases, T data, java.io.File file, java.lang.String... allowTypesByWildcard)
      Write the given data object to the given file as xml and encoded into a hexadecimal String object.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • writeToFileAsXmlAndHex

        public static <T> void writeToFileAsXmlAndHex​(java.util.Map<java.lang.String,​java.lang.Class<?>> aliases,
                                                      T data,
                                                      java.io.File file,
                                                      java.lang.String... allowTypesByWildcard)
                                               throws java.io.IOException
        Write the given data object to the given file as xml and encoded into a hexadecimal String object.
        Type Parameters:
        T - the generic type of the data object
        Parameters:
        aliases - the aliases for the XStream object
        data - the data to write
        file - the file to write
        allowTypesByWildcard - the allowed types by wildcard
        Throws:
        java.io.IOException - Signals that an I/O exception has occurred.
      • writeToFileAsXmlAndHex

        public static <T> void writeToFileAsXmlAndHex​(com.thoughtworks.xstream.XStream xstream,
                                                      java.util.Map<java.lang.String,​java.lang.Class<?>> aliases,
                                                      T data,
                                                      java.io.File file)
                                               throws java.io.IOException
        Write the given data object to the given file as xml and encoded into a hexadecimal String object.
        Type Parameters:
        T - the generic type of the data object
        Parameters:
        xstream - the XStream object
        aliases - the aliases for the XStream object
        data - the data to write
        file - the file to write
        Throws:
        java.io.IOException - Signals that an I/O exception has occurred.
      • writeToFileAsXmlAndHex

        public static <T> void writeToFileAsXmlAndHex​(com.thoughtworks.xstream.XStream xstream,
                                                      java.util.Map<java.lang.String,​java.lang.Class<?>> aliases,
                                                      T data,
                                                      java.io.File file,
                                                      java.lang.String charset)
                                               throws java.io.IOException
        Write the given data object to the given file as xml and encoded into a hexadecimal String object.
        Type Parameters:
        T - the generic type of the data object
        Parameters:
        xstream - the XStream object
        aliases - the aliases for the XStream object
        data - the data to write
        file - the file to write
        charset - the charset
        Throws:
        java.io.IOException - Signals that an I/O exception has occurred.