Parses the specified JSON string into a parse tree. An exception is thrown if the JSON string has multiple top-level JSON elements, or if there is trailing data. <p>The JSON string is parsed in {@linkplain JsonReader#setStrictness(Strictness) lenient mode}. @param json JSON text @return a parse tr
(String json)
| 89 | * @since 2.8.6 |
| 90 | */ |
| 91 | public static JsonElement parseString(String json) throws JsonSyntaxException { |
| 92 | return parseReader(new StringReader(json)); |
| 93 | } |
| 94 | |
| 95 | /** |
| 96 | * Parses the complete JSON string provided by the reader into a parse tree. An exception is |