Class AbstractEnumMarshaller<T extends Enum<T>>
java.lang.Object
com.amazonaws.services.dynamodbv2.datamodeling.AbstractEnumMarshaller<T>
- All Implemented Interfaces:
DynamoDBMarshaller<T>
public abstract class AbstractEnumMarshaller<T extends Enum<T>>
extends Object
implements DynamoDBMarshaller<T>
Generic marshaller for enumerations.
Please note, there are some risks in distributed systems when using
enumerations as attributes intead of simply using a String.
When adding new values to the enumeration, the enum only changes must
be deployed before the enumeration value can be persisted. This will
ensure that all systems have the correct code to map it from the item
record in DynamoDB to your objects.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
AbstractEnumMarshaller
public AbstractEnumMarshaller()
-
-
Method Details
-
marshall
Turns an object of type T into its String representation.- Specified by:
marshall
in interfaceDynamoDBMarshaller<T extends Enum<T>>
-
unmarshall
Turns a String representation of an object of type T into an object.- Specified by:
unmarshall
in interfaceDynamoDBMarshaller<T extends Enum<T>>
-