Enum Use

    • Enum Constant Detail

      • SIGNATURE

        public static final Use SIGNATURE
        Use this constant when the key is being used for signature.
      • ENCRYPTION

        public static final Use ENCRYPTION
        Use this constant when the key is being used for encryption.
    • Method Detail

      • values

        public static Use[] 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 (Use c : Use.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static Use valueOf​(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:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null
      • getParamName

        public String getParamName()
      • fromString

        public static Use fromString​(String param)
        Returns the corresponding Use for a parameter use of the JWK endpoint.
        Parameters:
        param - The use parameter.
        Returns:
        The corresponding use if found, otherwise null.
      • toString

        public String toString()
        Returns a string representation of the object. In this case the parameter name.
        Overrides:
        toString in class Enum<Use>
        Returns:
        The string representation of the object.