ContractViolation class final

One place where a JSON value breaks its schema.

pointer is a JSON Pointer (RFC 6901) into the checked value ("" for the root), the form the server uses in FieldError.pointer (06 5).

Constructors

ContractViolation(String pointer, String code, String detail)
Creates a violation at pointer with code (the FieldError.code of 06 5) and a short detail that never repeats the value.
const

Properties

code → String
The rule that failed: required, unknown_member, invalid_type, invalid_format, invalid_enum, too_short, too_long, too_small, too_large, too_few_items, too_many_items, pattern_mismatch or invalid.
final
detail → String
What was expected.
final
hashCode → int
The hash code for this object.
no setterinherited
pointer → String
Where the violation is.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
inherited