ccc.plugins.s11n.json
Class PagedCollectionSerializer<T>

java.lang.Object
  extended by ccc.plugins.s11n.json.PagedCollectionSerializer<T>
Type Parameters:
T - The type of collection to be serialized / deserialized.
All Implemented Interfaces:
Serializer<PagedCollection<T>>

public class PagedCollectionSerializer<T>
extends java.lang.Object
implements Serializer<PagedCollection<T>>

Serializer for PagedCollections.

Author:
Civic Computing Ltd.

Constructor Summary
PagedCollectionSerializer()
           
 
Method Summary
 PagedCollection<T> read(Json json)
          Deserialize from a representation.
 Json write(Json json, PagedCollection<T> instance)
          Serialize to representation.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PagedCollectionSerializer

public PagedCollectionSerializer()
Method Detail

read

public PagedCollection<T> read(Json json)
Deserialize from a representation.

Specified by:
read in interface Serializer<PagedCollection<T>>
Parameters:
json - The wire representation.
Returns:
The corresponding object.

write

public Json write(Json json,
                  PagedCollection<T> instance)
Serialize to representation.

Specified by:
write in interface Serializer<PagedCollection<T>>
Parameters:
json - The wire representation.
instance - The object to serialize.
Returns:
Returns the 'json' input param if the 'instance' param is not NULL; returns NULL otherwise.


Copyright © 2010. All Rights Reserved.