Package com.itextpdf.commons.json
Class JsonValue
java.lang.Object
com.itextpdf.commons.json.JsonValue
- Direct Known Subclasses:
-
JsonArray,JsonBoolean,JsonNull,JsonNumber,JsonObject,JsonString
Class representing generic JSON value.
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
JsonValue
protected JsonValue()Creates a newJsonValue.
-
-
Method Details
-
fromJson
Parses string and createsJsonValueout of it.- Parameters:
-
json- string to parse - Returns:
-
JsonValuerepresenting the input string
-
toJson
Converts thisJsonValueinto a string.- Returns:
-
string representing this
JsonValue
-
toPrettifiedJson
Converts thisJsonValueinto a prettified JSON string with indentation and line breaks.- Returns:
-
prettified JSON string representing this
JsonValue
-