Enum PdfEncryptor.Algorithm

    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
      AES_128
      /V 4 /R 4, AES-128 via a /StdCF crypt filter.
      AES_256
      /V 5 /R 6, AES-256, ISO 32000-2 hardened-hash key derivation.
      RC4_128
      /V 2 /R 3, 128-bit RC4.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static PdfEncryptor.Algorithm valueOf​(java.lang.String name)
      Returns the enum constant of this type with the specified name.
      static PdfEncryptor.Algorithm[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      • Methods inherited from class java.lang.Enum

        compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, wait, wait, wait
    • Enum Constant Detail

      • RC4_128

        public static final PdfEncryptor.Algorithm RC4_128
        /V 2 /R 3, 128-bit RC4. Broadest legacy-reader compatibility, weakest cipher.
      • AES_256

        public static final PdfEncryptor.Algorithm AES_256
        /V 5 /R 6, AES-256, ISO 32000-2 hardened-hash key derivation. Modern default.
    • Method Detail

      • values

        public static PdfEncryptor.Algorithm[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (PdfEncryptor.Algorithm c : PdfEncryptor.Algorithm.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static PdfEncryptor.Algorithm valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null