Method
assertFullConsumption
gson/src/main/java/com/google/gson/Gson.java:1196–1206
· gson/src/main/java/com/google/gson/Gson.java::Gson.assertFullConsumption
(Object obj, JsonReader reader)
Source from the content-addressed store, hash-verified
| 1194 | } |
| 1195 | |
| 1196 | private static void assertFullConsumption(Object obj, JsonReader reader) { |
| 1197 | try { |
| 1198 | if (obj != null && reader.peek() != JsonToken.END_DOCUMENT) { |
| 1199 | throw new JsonSyntaxException(class="st">"JSON document was not fully consumed."); |
| 1200 | } |
| 1201 | } catch (MalformedJsonException e) { |
| 1202 | throw new JsonSyntaxException(e); |
| 1203 | } catch (IOException e) { |
| 1204 | throw new JsonIOException(e); |
| 1205 | } |
| 1206 | } |
| 1207 | |
| 1208 | /** |
| 1209 | * Proxy type adapter for cyclic type graphs. |
Tested by
no test coverage detected