Schema class

Inheritance

Constructors

Schema(Map<String, SchemaValue> properties, {bool additionalProperties = false})
const

Properties

additionalProperties → bool
finalinherited
hashCode → int
The hash code for this object.
no setterinherited
optional → bool
finalinherited
properties → Map<String, SchemaValue>
finalinherited
required → bool
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
validators → List<Validator<Map<String, dynamic>>>
finalinherited

Methods

copyWith({bool? optional, bool? additionalProperties, Map<String, SchemaValue>? properties, List<Validator<Map<String, dynamic>>>? validators}) → SchemaMap
inherited
getSchemaValue<T extends SchemaValue>(String key) → T?
inherited
isOptional() → SchemaValue<Map<String, dynamic>>
inherited
isRequired() → SchemaValue<Map<String, dynamic>>
inherited
merge(Map<String, SchemaValue> properties, {bool? additionalProperties, bool? optional}) → SchemaMap
inherited
mergeSchema(SchemaMap schema) → SchemaMap
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited
tryParse(Object? value) → Map<String, dynamic>?
inherited
validate(List<String> path, Object? value) → SchemaValidationResult
inherited
validateOrThrow(Object value) → void
inherited

Operators

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

Constants

any → const Schema
boolean → const BooleanSchema
double → const DoubleSchema
enumType → const EnumSchema Function({bool optional = false, List<Validator<String>> validators = const [], required List<String> values})
integer → const IntegerSchema
string → const StringSchema