java.lang.Object | |
↳ | com.sun.jmx.snmp.Enumerated |
This class is used for implementing enumerated values. An enumeration is represented by a class derived from Enumerated. The derived class defines what are the permitted values in the enumeration. An enumerated value is represented by an instance of the derived class. It can be represented : - as an integer - as a string
This API is a Sun Microsystems internal API and is subject to change without notice.
Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
value | This variable keeps the integer form of the enumerated. |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Construct an enumerated with a default value.
| |||||||||||
Construct an enumerated from its integer form.
| |||||||||||
Construct an enumerated from its Integer form.
| |||||||||||
Construct an enumerated from its string form.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Compares this enumerated to the specified enumerated.
| |||||||||||
Returns the hash code for this enumerated.
| |||||||||||
Return the integer form of the enumerated.
| |||||||||||
Returns the string form of this enumerated.
| |||||||||||
Returns an Java enumeration of the permitted integers.
| |||||||||||
Returns an Java enumeration of the permitted strings.
|
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Returns the hashtable of the integer forms.
| |||||||||||
Returns the hashtable of the string forms.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
This variable keeps the integer form of the enumerated. The string form is retreived using getIntTable().
Construct an enumerated with a default value. The default value is the first available in getIntTable().
IllegalArgumentException | One of the arguments passed to the method is illegal or inappropriate. |
---|
Construct an enumerated from its integer form.
valueIndex | The integer form. |
---|
IllegalArgumentException | One of the arguments passed to the method is illegal or inappropriate. |
---|
Construct an enumerated from its Integer form.
valueIndex | The Integer form. |
---|
IllegalArgumentException | One of the arguments passed to the method is illegal or inappropriate. |
---|
Construct an enumerated from its string form.
valueString | The string form. |
---|
IllegalArgumentException | One of the arguments passed to the method is illegal or inappropriate. |
---|
Compares this enumerated to the specified enumerated. The result is true if and only if the argument is not null and is of the same class.
obj | The object to compare with. |
---|
Returns the hash code for this enumerated.
Return the integer form of the enumerated.
Returns the string form of this enumerated.
Returns an Java enumeration of the permitted integers.
Returns an Java enumeration of the permitted strings.
Returns the hashtable of the integer forms. getIntTable().get(x) returns the string form associated to the integer x. This method must be implemented by the derived class.
Returns the hashtable of the string forms. getStringTable().get(s) returns the integer form associated to the string s. This method must be implemented by the derived class.