@Deprecated public class TypesafeEnum extends Object implements Localizable
import java.io.Serializable; import java.io.ObjectStreamException; import puce.util.TypesafeEnum; public class Foo extends TypesafeEnum implements Serializable{ private Foo(String name){ super(name); } public static final Foo BAR = new Foo("bar"){ private Object readResolve() throws ObjectStreamException{ return Foo.BAR; } } }Note:This serialization tip has not been tested yet!
Modifier | Constructor and Description |
---|---|
protected |
TypesafeEnum()
Deprecated.
|
protected |
TypesafeEnum(String name)
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj)
Deprecated.
All equal objects of the enumerated type are also identical
(a.equals(b) if and only if a==b).
|
String |
getDisplayString(Locale locale)
Deprecated.
Returns a string that is appropriate to display to the user.
|
String |
getResourceBundleBaseName()
Deprecated.
|
int |
hashCode()
Deprecated.
|
String |
toString()
Deprecated.
|
protected TypesafeEnum(String name)
protected TypesafeEnum()
public String getDisplayString(Locale locale)
Localizable
getDisplayString
in interface Localizable
locale
- the string returned will be localized according to this value, if possiblepublic String getResourceBundleBaseName()
public final boolean equals(Object obj)
Copyright © 2002–2016 SoftSmithy. All rights reserved.