|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.n1.util.enum.EnumImpl
public abstract class EnumImpl
This class is the base implementation of the Enumumeration types. Its not meant to be used directly, only subclasses should be used.
| Constructor Summary | |
|---|---|
protected |
EnumImpl()
Creates a new enumumeration without any registration. |
protected |
EnumImpl(java.lang.String stringValue,
EnumFactoryImpl factory)
Creates a new enumumeration, and registers it with the passed factory. |
| Method Summary | |
|---|---|
boolean |
equals(java.lang.Object other)
This object is considered equal to the other object if the other object is non-null, and has the same class and int value. |
int |
hashCode()
Returns the hash code of this enum. |
int |
toInt()
Returns the int value of this enum. |
java.lang.String |
toString()
Returns the String value of this enum. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
protected EnumImpl(java.lang.String stringValue,
EnumFactoryImpl factory)
stringValue - the name of the enum.factory - the factory with which to register the eunm.
java.lang.IllegalArgumentException - if the passed name is already
registered within the passed factory.protected EnumImpl()
| Method Detail |
|---|
public int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object other)
equals in class java.lang.Objectother - the object to compare against for equality
public int toInt()
toInt in interface Enumpublic java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||