Skip to content

Commit e5daa73

Browse files
committed
WIP: requested changes
1 parent 803051e commit e5daa73

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

src/main/java/com/flowingcode/vaadin/jsonmigration/JsonSerializer.java

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -92,9 +92,6 @@ public static JsonValue toJson(Object bean) {
9292
if (bean.getClass().isArray()) {
9393
return toJsonArray(bean);
9494
}
95-
// if (bean instanceof JsonSerializable) {
96-
// return ((JsonSerializable) bean).toJson();
97-
// }
9895

9996
Optional<JsonValue> simpleType = tryToConvertToSimpleType(bean);
10097
if (simpleType.isPresent()) {
@@ -234,11 +231,6 @@ private static <T> T toObject(Class<T> type, Type genericType,
234231
}
235232

236233
try {
237-
// if (instance instanceof JsonSerializable
238-
// && json instanceof JsonObject) {
239-
// return type.cast(JsonSerializable.class.cast(instance)
240-
// .readJson((JsonObject) json));
241-
// }
242234

243235
JsonObject jsonObject = (JsonObject) json;
244236
String[] keys = jsonObject.keys();
@@ -307,7 +299,7 @@ private static <T> T toCollection(Class<T> type, Type genericType,
307299
}
308300
if (!(genericType instanceof ParameterizedType)) {
309301
throw new IllegalArgumentException(
310-
"Cloud not infer the generic parameterized type of the collection of class: "
302+
"Could not infer the generic parameterized type of the collection of class: "
311303
+ type.getName()
312304
+ ". The type is no subclass of ParameterizedType: "
313305
+ genericType);

0 commit comments

Comments
 (0)