*/
public static <T> T toObject(JsonElement jsonObject, Class<T> type) {
Preconditions.checkNotNull(jsonObject, "null jsonObject not allowed");
Preconditions.checkNotNull(type, "null type not allowed");
Gson gson = new GsonBuilder().registerTypeAdapter(DateTime.class,
new GsonDateTimeDeserializer()).create();
return type.cast(gson.fromJson(jsonObject, type));
}