jasper
Types
pub type Indentation {
Spaces(Int)
Tab
Tabs(Int)
}
Constructors
-
Spaces(Int)
-
Tab
-
Tabs(Int)
pub type JsonQuery {
Root
Key(query: JsonQuery, key: String)
KeyOr(query: JsonQuery, key: String, or: JsonValue)
Index(query: JsonQuery, index: Int)
IndexOr(query: JsonQuery, index: Int, or: JsonValue)
Filter(query: JsonQuery, predicate: fn(JsonValue) -> Bool)
Map(query: JsonQuery, mapping: fn(JsonValue) -> JsonValue)
MapKeys(query: JsonQuery, mapping: fn(String) -> String)
MapValues(
query: JsonQuery,
mapping: fn(String, JsonValue) -> JsonValue,
)
FilterMap(
query: JsonQuery,
mapping: fn(JsonValue) -> Result(JsonValue, Nil),
)
ForEach(query: JsonQuery)
ForEachOk(query: JsonQuery)
}
Constructors
Values
pub fn decoder() -> decode.Decoder(JsonValue)
pub fn parse(
value: String,
) -> Result(JsonValue, json.DecodeError)
pub fn parse_bits(
value: BitArray,
) -> Result(JsonValue, json.DecodeError)
pub fn to_pretty_string(
value: JsonValue,
indentation: Indentation,
) -> String
pub fn to_pretty_string_tree(
value: JsonValue,
indentation: Indentation,
) -> string_tree.StringTree
pub fn to_string_tree(value: JsonValue) -> string_tree.StringTree