Package com.snmp4j.smi
Enum Class SmiAccess
- All Implemented Interfaces:
Serializable
,Comparable<SmiAccess>
,java.lang.constant.Constable
The SmiMaxAccess enumerates the ACCESS values of SMIv2 for MODULE-COMPLIANCE and AGENT-CAPABILITIES statements,
including the deprecated
writeOnly
for backward-compatibility.- Since:
- 1.7.0 (Pro edition only)
- Author:
- Frank Fock
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionObject accesible for notifications only.Not acessible object.Not implemented object.Object is read-write accessible and creatable via SNMP.Object is read-only.Object is read-write accessible - creation is not supported via SNMP SET.Object is write-only (deprecated in SMIv2) -
Method Summary
Modifier and TypeMethodDescriptionstatic SmiAccess
fromSmiValue(String smiValue)
Gets theMaxAccess
from a MAX-ACCESS (or ACCESS in SMIv1) clause string.Gets the MAX-ACCESS (or ACCESS in SMIv1) clause string.boolean
Checks if thisSmiObject
is accessible or not.boolean
Checks if thisSmiObject
is read-create or not.boolean
Checks if thisSmiObject
is implemented or not.boolean
Checks if thisSmiObject
is read-only or not.boolean
Checks if thisSmiObject
is read-write or not.static SmiAccess
Returns the enum constant of this class with the specified name.static SmiAccess[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
notImplemented
Not implemented object. -
notAccessible
Not acessible object. -
accessibleForNotify
Object accesible for notifications only. -
writeOnly
Object is write-only (deprecated in SMIv2) -
readOnly
Object is read-only. -
readWrite
Object is read-write accessible - creation is not supported via SNMP SET. -
readCreate
Object is read-write accessible and creatable via SNMP.
-
-
Method Details
-
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
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 nameNullPointerException
- if the argument is null
-
getSmiValue
Gets the MAX-ACCESS (or ACCESS in SMIv1) clause string.- Returns:
- the SMI access string.
-
fromSmiValue
Gets theMaxAccess
from a MAX-ACCESS (or ACCESS in SMIv1) clause string.- Parameters:
smiValue
- the SMI access string.- Returns:
null
ifsmiValue
is not a valid ACCESS/MAX-ACCESS clause value or the matching enumeration value.
-
isAccessible
public boolean isAccessible()Checks if thisSmiObject
is accessible or not.- Returns:
true
if access is notnotAccessible
and notnotImplemented
.
-
isImplemented
public boolean isImplemented()Checks if thisSmiObject
is implemented or not.- Returns:
true
if access is notnotImplemented
.
-
isReadOnly
public boolean isReadOnly()Checks if thisSmiObject
is read-only or not.- Returns:
true
if access isreadOnly
.
-
isWritable
public boolean isWritable()Checks if thisSmiObject
is read-write or not.- Returns:
true
if access isreadWrite
or greater.
-
isCreatable
public boolean isCreatable()Checks if thisSmiObject
is read-create or not.- Returns:
true
if access isreadCreate
.
-