Enum GeneralNameType

java.lang.Object
java.lang.Enum<GeneralNameType>
eu.europa.esig.dss.enumerations.GeneralNameType
All Implemented Interfaces:
Serializable, Comparable<GeneralNameType>

public enum GeneralNameType extends Enum<GeneralNameType>
Represents possible types of a GeneralName
  • Enum Constant Details

  • Method Details

    • values

      public static GeneralNameType[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static GeneralNameType 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
    • getIndex

      public int getIndex()
      Gets index of the GeneralName type
      Returns:
      int index
    • getLabel

      public String getLabel()
      Gets a human-readable label of the GeneralName type
      Returns:
      String
    • fromIndex

      public static GeneralNameType fromIndex(int index)
      Returns a GeneralNameType for the given index if exists
      Parameters:
      index - int index to get value for
      Returns:
      GeneralNameType if found, null otherwise
    • fromLabel

      public static GeneralNameType fromLabel(String label)
      Returns a GeneralNameType for the given label if exists
      Parameters:
      label - String representing a human-readable value of the general name type
      Returns:
      GeneralNameType if found, null otherwise