json

array

List<Json> array = json.array(String name);

Retrieves a json array nested under a specified member name. Leave blank for unnamed arrays.

equals

boolean equals = json1.equals(json2);

Returns whether two Json types are equal.

exists

boolean exists = json.exists();

Returns whether an object exists.

get

String value = json.get(String key, String default);

Retrieves the value from a specified json key. Providing a default value is optional.

map

Map<String, Json> map = json.map();

Converts json to a map.

object

Json object = json.object(String name);

Retrieves a nested json object by name. Leave blank for unnamed objects.

parse

Json json = new Json(String jsonString);

Parses a json string into a json object.

string

String data = json.string();

Converts json to a string.

Last updated