Json

interface Json<NODE>

This is the contract for all JSON implementations

Inheritors

Functions

Link copied to clipboard
open fun <T : NODE> array(value: T): NODE
open fun <T : NODE> array(value: Iterable<T>): NODE
Link copied to clipboard
Link copied to clipboard
abstract fun <T : Iterable<NODE>> T.asJsonArray(): NODE
Link copied to clipboard
abstract fun String.asJsonObject(): NODE
Link copied to clipboard
abstract fun BigDecimal?.asJsonValue(): NODE
abstract fun BigInteger?.asJsonValue(): NODE
abstract fun Boolean?.asJsonValue(): NODE
abstract fun Double?.asJsonValue(): NODE
abstract fun Int?.asJsonValue(): NODE
abstract fun Long?.asJsonValue(): NODE
abstract fun String?.asJsonValue(): NODE
Link copied to clipboard
Link copied to clipboard
open fun body(description: String? = null, contentNegotiation: ContentNegotiation = None): BiDiBodyLensSpec<NODE>
Link copied to clipboard
abstract fun bool(value: NODE): Boolean
Link copied to clipboard
open fun boolean(value: Boolean): NODE
Link copied to clipboard
open fun compact(node: NODE): String
Link copied to clipboard
open fun compactify(input: String): String
Link copied to clipboard
abstract fun decimal(value: NODE): BigDecimal
Link copied to clipboard
abstract fun elements(value: NODE): Iterable<NODE>
Link copied to clipboard
abstract fun fields(node: NODE): Iterable<Pair<String, NODE>>
Link copied to clipboard
abstract fun integer(value: NODE): Long
Link copied to clipboard
open operator fun <T> invoke(fn: Json<NODE>.() -> T): T
Link copied to clipboard
open fun Body.Companion.json(description: String? = null, contentNegotiation: ContentNegotiation = None): BiDiBodyLensSpec<NODE>
Link copied to clipboard
Link copied to clipboard
open fun nullNode(): NODE
Link copied to clipboard
open fun number(value: BigDecimal): NODE
open fun number(value: BigInteger): NODE
open fun number(value: Double): NODE
open fun number(value: Int): NODE
open fun number(value: Long): NODE
Link copied to clipboard
open fun obj(): NODE
open fun <T : NODE> obj(vararg fields: Pair<String, T>): NODE
open fun <T : NODE> obj(value: Iterable<Pair<String, T>>): NODE
Link copied to clipboard
open fun parse(input: String): NODE
Link copied to clipboard
open fun prettify(input: String): String
Link copied to clipboard
open fun pretty(node: NODE): String
Link copied to clipboard
open fun string(value: String): NODE
Link copied to clipboard
abstract fun text(value: NODE): String
Link copied to clipboard
abstract fun textValueOf(node: NODE, name: String): String?
Link copied to clipboard
abstract fun typeOf(value: NODE): JsonType