Validator

A compiled, reusable schema validator. Create via compileSchema; then validate any number of instances of either built-in JSON type (or any custom-adapted type via validateWith).

Members

Functions

isValid
bool isValid(V instance)

Convenience: flag-format validity check.

validate
ValidationResult validate(JsonNode instance, OutputFormat format)

Validate an instance held in the library's internal representation.

validate
ValidationResult validate(std.json.JSONValue instance, OutputFormat format)

Validate a std.json.JSONValue instance.

validateWith
ValidationResult validateWith(A.Value instance, OutputFormat format)

Validate an instance of any adapted JSON type.