Enum Class SmiType

java.lang.Object
java.lang.Enum<SmiType>
com.snmp4j.smi.SmiType
All Implemented Interfaces:
Serializable, Comparable<SmiType>, Constable

public enum SmiType extends Enum<SmiType>
The SmiType defines the SMI construct (for example OBJECT-TYPE) that defined the SMI object.
Since:
1.2 (Pro edition only)
Author:
Frank Fock
  • Enum Constant Details

    • MODULE_IDENTITY

      public static final SmiType MODULE_IDENTITY
      SMIv2 MODULE-IDENTITY macro.
    • OBJECT_NAME

      public static final SmiType OBJECT_NAME
      SMIv1/v2 OBJECT-TYPE used as a plain object name (not further classified).
    • OBJECT_IDENTITY

      public static final SmiType OBJECT_IDENTITY
      SMIv2 OBJECT-IDENTITY macro.
    • OBJECT_TYPE_SCALAR

      public static final SmiType OBJECT_TYPE_SCALAR
      SMIv2 OBJECT-TYPE that defines a scalar object.
    • OBJECT_TYPE_TABLE

      public static final SmiType OBJECT_TYPE_TABLE
      SMIv2 OBJECT-TYPE that defines a conceptual table.
    • OBJECT_TYPE_TABLE_ENTRY

      public static final SmiType OBJECT_TYPE_TABLE_ENTRY
      SMIv2 OBJECT-TYPE that defines a conceptual table row (entry).
    • OBJECT_TYPE_COLUMN

      public static final SmiType OBJECT_TYPE_COLUMN
      SMIv2 OBJECT-TYPE that defines a conceptual table column.
    • NOTIFICATION_TYPE

      public static final SmiType NOTIFICATION_TYPE
      SMIv2 NOTIFICATION-TYPE macro.
    • TEXTUAL_CONVENTION

      public static final SmiType TEXTUAL_CONVENTION
      SMIv2 TEXTUAL-CONVENTION macro.
    • OBJECT_GROUP

      public static final SmiType OBJECT_GROUP
      SMIv2 OBJECT-GROUP macro.
    • NOTIFICATION_GROUP

      public static final SmiType NOTIFICATION_GROUP
      SMIv2 NOTIFICATION-GROUP macro.
    • MODULE_COMPLIANCE

      public static final SmiType MODULE_COMPLIANCE
      SMIv2 MODULE-COMPLIANCE macro.
    • AGENT_CAPABILITIES

      public static final SmiType AGENT_CAPABILITIES
      SMIv2 AGENT-CAPABILITIES macro.
    • TRAP_TYPE

      public static final SmiType TRAP_TYPE
      SMIv1 TRAP-TYPE macro.
  • Method Details

    • values

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

      public static SmiType valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified name
      NullPointerException - if the argument is null
    • getJasmiType

      public int getJasmiType()
      Gets the numeric JASMI type constant corresponding to this SMI type.
      Returns:
      the JASMI type code as defined in SMI.
    • fromJasmiType

      public static SmiType fromJasmiType(int jasmiType)
      Returns the SmiType for a given JASMI type constant. When multiple SmiType values share the same JASMI code (e.g. all OBJECT_TYPE_* variants), the first matching constant is returned.
      Parameters:
      jasmiType - the JASMI type code as defined in SMI.
      Returns:
      the matching SmiType, or null if no match exists.