public class StandaloneRepresentationHandler extends java.lang.Object implements RepresentationHandler
StandaloneRepresentable implementers
and some other simple types.| Modifier and Type | Field and Description |
|---|---|
protected java.lang.Class<?> |
type
Type of the represented object.
|
| Constructor and Description |
|---|
StandaloneRepresentationHandler(java.lang.Class<?> type) |
| Modifier and Type | Method and Description |
|---|---|
static boolean |
canHandle(java.lang.reflect.Type type)
Checks whether this handler can handle objects of the given type.
|
java.lang.Object |
deserializeFromRepresentation(Representation repr,
java.util.function.Function<java.lang.String,RepresentationRestorer> getRegisteredRestorer)
Deserializes the given representation using the given representation restorers.
|
Representation |
serializeToRepresentation(java.lang.Object value)
Serializes (creates a representation of) the given object.
|
public StandaloneRepresentationHandler(java.lang.Class<?> type)
public static boolean canHandle(java.lang.reflect.Type type)
type - the type to checkpublic java.lang.Object deserializeFromRepresentation(Representation repr, java.util.function.Function<java.lang.String,RepresentationRestorer> getRegisteredRestorer)
RepresentationHandlerdeserializeFromRepresentation in interface RepresentationHandlerrepr - the representation to deserializegetRegisteredRestorer - maps representation restorer names to the restorerspublic Representation serializeToRepresentation(java.lang.Object value)
RepresentationHandlerserializeToRepresentation in interface RepresentationHandlervalue - the object to serialize