Class EnumStringifier<E extends Enum>
java.lang.Object
com.googlecode.objectify.stringifier.EnumStringifier<E>
- All Implemented Interfaces:
InitializeStringifier
,Stringifier<E>
public class EnumStringifier<E extends Enum>
extends Object
implements Stringifier<E>, InitializeStringifier
Converts Enums back and forth with their string representation
- Author:
- Jeff Schnitzer <[email protected]>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfromString
(String str) Convert the string back to a thingvoid
init
(ObjectifyFactory fact, Type keyType) Informs the stringifier of the actual key type.Convert the thing to a string
-
Constructor Details
-
EnumStringifier
public EnumStringifier()
-
-
Method Details
-
init
Description copied from interface:InitializeStringifier
Informs the stringifier of the actual key type.- Specified by:
init
in interfaceInitializeStringifier
- Parameters:
fact
- is just handy to have aroundkeyType
- is the declared type of the map key.
-
toString
Description copied from interface:Stringifier
Convert the thing to a string- Specified by:
toString
in interfaceStringifier<E extends Enum>
-
fromString
Description copied from interface:Stringifier
Convert the string back to a thing- Specified by:
fromString
in interfaceStringifier<E extends Enum>
-