This typeclass with its implicit instances decides how two containers should be joined.
This typeclass with its implicit instances decides how two containers should be joined.
Supported containers are
Id
for scalar valuesOption
for optional valuesSeq
for a vector of valuesThose container types form an ordering from most specific to most abstract:
Id
contains always one valueOption
contains always zero or one valueSeq
can contain any number of valuesThe rule to determine what the result type of joining two container types is that the result is as generic as the more generic of both of the input types.
The implicit definitions in the companion object of join form evidence for this ordering.
A Lens combines read and update functions of UpdateLens and ReadLens into combinable chunks.
A Lens combines read and update functions of UpdateLens and ReadLens into combinable chunks.
A lens can either operate on a scalar value, or on an optional value, or on a
sequence value. This is denoted by the M[_]
type constructor.
This implements most of the methods of Lens
.
This implements most of the methods of Lens
. Implementors of a new type of lens
must implement retr
for the read side of the lens and updated
for the update side of the lens.
Defines a set of operations to update Json values.
A trait to define common operations for different container types.
A trait to define common operations for different container types.
There's some bias towards Seq
because container types have to support
conversions towards and from Seq
.
This could probably made more general but the methods defined here comprise exactly the set of operations needed to allow combining different kinds of lenses.
The read lens can extract child values out of a JsValue hierarchy.
The read lens can extract child values out of a JsValue hierarchy. A read lens is parameterized with a type constructor. This allows to extracts not only scalar values but also sequences or optional values.
The UpdateLens is the central interface for updating a child element somewhere deep down a hierarchy of a JsValue.
An aggregate option to import all of the functionality of JsonLenses with one import.
The AST for a json-path.
The AST for a json-path. Basically follows the specification at http://goessner.net/articles/JsonPath/
A parser for json-path expression as specified here: http://goessner.net/articles/JsonPath/