skema

Const

@Serializable
@SerialName(value = "Const")
data class Const(val value: JsonElement) : JsonSpec(source)

Value constrained to a single constant. Maps to {"const": value}.

Constructors

Link copied to clipboard
constructor(value: JsonElement)

Properties

Link copied to clipboard
val value: JsonElement

The required value, as a JsonElement.

Functions

Link copied to clipboard
fun JsonSpec.toJsonSchema(): JsonObject

JSON Schema fragment describing the value this primitive validates.

Const

constructor(value: JsonElement)(source)

value

val value: JsonElement(source)

The required value, as a JsonElement.