org.jclouds.json
Interface Json

All Known Implementing Classes:
GsonWrapper

public interface Json

Author:
Adrian Cole

Method Summary
<T> T
fromJson(String json, Class<T> classOfT)
          Deserialize the object from json.
<T> T
fromJson(String json, Type type)
          Deserialize the generic object from json.
 String toJson(Object src)
          Serialize the object into json.
 String toJson(Object src, Type type)
          Serialize the generic object into json.
 

Method Detail

toJson

String toJson(Object src)
Serialize the object into json. If the object is a generic type, use toJson(Object, Type)


toJson

String toJson(Object src,
              Type type)
Serialize the generic object into json. If the object is not a generic, use toJson(Object, Type)


fromJson

<T> T fromJson(String json,
               Type type)
Deserialize the generic object from json. If the object is not a generic type, use #fromJson(Object, Class)


fromJson

<T> T fromJson(String json,
               Class<T> classOfT)
Deserialize the object from json. If the object is a generic type, use #fromJson(Object, Type)



Copyright © 2009-2011 jclouds. All Rights Reserved.