io.github.cakelier.tuples.space.JsonTemplate$.JsonStringTemplate
See theJsonStringTemplate companion object
sealed trait JsonStringTemplate extends JsonTemplate
A JsonTemplate that can be matched against a string value.
A JsonElement can be matched using a set of strings, creating what is called in the JSON Schema an "enum". Regardless of this, specifying a Set constrains the values that the JsonElement can have, because no other string value outside of the Set could be accepted. If the Set is the singleton Set, this constraint is perfectly equal to specifying a constant value to be matched against. The given JsonElement can be constrained in terms of an inclusive range of string length, which can be half-open, and in terms of the regular expression that can match it. If no constraint is specified, only the type equality will be checked.
Attributes
- Companion
- object
- Graph
-
- Supertypes
Members list
In this article