org.codegist.crest.serializer
Class ToStringSerializer<T>
java.lang.Object
org.codegist.crest.serializer.ToStringSerializer<T>
- All Implemented Interfaces:
- Serializer<T>
public class ToStringSerializer<T>
- extends Object
- implements Serializer<T>
Simple serializer that returns the toString() value of the given value or empty string if null.
- Author:
- Laurent Gilles (laurent.gilles@codegist.org)
Method Summary |
String |
serialize(T value)
Simple serializer that returns the toString() value of the given value or empty string if null. |
ToStringSerializer
public ToStringSerializer()
serialize
public String serialize(T value)
- Simple serializer that returns the toString() value of the given value or empty string if null.
- Specified by:
serialize
in interface Serializer<T>
- Parameters:
value
- Context of the serialization
- Returns:
- serialized value of param
Copyright © 2011. All Rights Reserved.