represents an immutable Json object. There are several ways of creating a Json object, being the most common the following:
- From a string, array of bytes or an input stream of bytes, using the parse functions of the companion object
- From the apply function of the companion object.
- Value parameters:
- bindings
immutable map of JsValue
- Companion:
- object
Value members
Concrete methods
string representation of this Json array. It's a lazy json.value which is only computed once.
string representation of this Json array. It's a lazy json.value which is only computed once.
- Returns:
string representation of this Json array
- Definition Classes
- Json -> Any
Inherited methods
Returns the element located at a specified path. This function is total on its argument. If no element is found, JsNothing is returned
Returns the element located at a specified path. This function is total on its argument. If no element is found, JsNothing is returned
- Value parameters:
- path
the path
- Returns:
the json value found at the path
- Inherited from:
- Json
Retrieves the json.value which is associated with the given key. If there is no mapping
from the given key to a json.value, JsNothing
is returned.
Retrieves the json.value which is associated with the given key. If there is no mapping
from the given key to a json.value, JsNothing
is returned.
- Value parameters:
- key
the key
- Returns:
the json.value associated with the given key
- Inherited from:
- AbstractJsObj (hidden)
Tests whether this json object contains a binding for a key.
Tests whether this json object contains a binding for a key.
- Value parameters:
- key
the key
- Returns:
true
if there is a binding forkey
in this map,false
otherwise.- Inherited from:
- AbstractJsObj (hidden)
Selects all elements of this Json object which satisfy a predicate.
Selects all elements of this Json object which satisfy a predicate.
- Returns:
a new Json object consisting of all elements of this Json object that satisfy the given predicate p. The order of the elements is preserved.
- Inherited from:
- AbstractJsObj (hidden)
Flatten this Json object into a LazyList
of pairs of (JsPath,JsValue)
traversing recursively every noe-empty Json found along the way.
Flatten this Json object into a LazyList
of pairs of (JsPath,JsValue)
traversing recursively every noe-empty Json found along the way.
- Returns:
a
LazyList
of pairs ofJsPath
andJsValue
- Inherited from:
- AbstractJsObj (hidden)
Selects the next element of the iterator of this Json object, throwing a NoSuchElementException if the Json object is empty
Selects the next element of the iterator of this Json object, throwing a NoSuchElementException if the Json object is empty
- Returns:
the next element of the iterator of this Json object.
- Inherited from:
- AbstractJsObj (hidden)
Optionally selects the next element of the iterator of this Json object.
Optionally selects the next element of the iterator of this Json object.
- Returns:
the first element of this Json object if it is nonempty.
None
if it is empty.- Inherited from:
- AbstractJsObj (hidden)
Tests whether the Json object is empty.
Tests whether the Json object is empty.
- Returns:
true
if the Json object contains no elements,false
otherwise.- Inherited from:
- AbstractJsObj (hidden)
Returns an iterator of this Json object. Can be used only once
Returns an iterator of this Json object. Can be used only once
- Returns:
an iterator
- Inherited from:
- AbstractJsObj (hidden)
Collects all keys of this map in a set.
Collects all keys of this map in a set.
- Returns:
a set containing all keys of this map.
- Inherited from:
- AbstractJsObj (hidden)
Collects all keys of this Json object in an iterable collection.
Collects all keys of this Json object in an iterable collection.
- Returns:
the keys of this Json object as an iterable.
- Inherited from:
- AbstractJsObj (hidden)
Selects the last element of the iterator of this Json object, throwing a NoSuchElementException if the Json object is empty
Selects the last element of the iterator of this Json object, throwing a NoSuchElementException if the Json object is empty
- Returns:
the last element of the iterator of this Json object.
- Inherited from:
- AbstractJsObj (hidden)
Optionally selects the last element of the iterator of this Json object.
Optionally selects the last element of the iterator of this Json object.
- Returns:
the last element of the iterator of this Json object,
None
if it is empty.- Inherited from:
- AbstractJsObj (hidden)
returns true if the Json is non empty
returns true if the Json is non empty
- Returns:
true if non empty, false otherwise
- Inherited from:
- Json
- Inherited from:
- AbstractJsObj (hidden)
Returns a zero-argument function that when called, it serializes this Json into the given output stream, no returning anything
Returns a zero-argument function that when called, it serializes this Json into the given output stream, no returning anything
- Value parameters:
- outputStream
the output stream
- Returns:
() => Unit function that serializes this Json into the given output stream
- Inherited from:
- Json
The size of this Json object. *
The size of this Json object. *
- Returns:
the number of elements in this Json object.
- Inherited from:
- AbstractJsObj (hidden)