EnumSchema extension type
Union type for all enum schemas.
Includes UntitledSingleSelectEnumSchema, TitledSingleSelectEnumSchema, UntitledMultiSelectEnumSchema, and TitledMultiSelectEnumSchema.
- on
- Implemented types
- Implementers
- Available extensions
Constructors
-
EnumSchema.fromMap(Map<
String, Object?> _value)
Properties
-
allOf
→ List<
Schema> ? -
Schema combinator that requires all sub-schemas to match.
no setterinherited
-
anyOf
→ List<
Schema> ? -
Schema combinator that requires at least one of the sub-schemas to match.
no setterinherited
- description → String?
-
A description of this schema.
no setter
- isTitledMultiSelect → bool
-
Whether or not this schema looks like a titled multi-select enum.
no setter
- isTitledSingleSelect → bool
-
Whether or not this schema looks like a titled single-select enum.
no setter
- isUntitledMultiSelect → bool
-
Whether or not this schema looks like an untitled multi-select enum.
no setter
- isUntitledSingleSelect → bool
-
Whether or not this schema looks like an untitled single-select enum.
no setter
-
not
→ List<
Schema> ? -
Schema combinator that requires none of the sub-schemas to match.
no setterinherited
-
oneOf
→ List<
Schema> ? -
Schema combinator that requires exactly one of the sub-schemas to match.
no setterinherited
- title → String?
-
A title for this schema, should be short.
no setter
- type → JsonType?
-
The JsonType of this schema, if present.
no setterinherited
Methods
-
validate(
Object? data) → List< ValidationError> -
Available on Schema, provided by the SchemaValidation extension
Validates the givendataagainst this schema.
Constants
-
titledMultiSelect
→ const TitledMultiSelectEnumSchema Function({Iterable<
String> ? defaultValue, String? description, int? maxItems, int? minItems, String? title, required Iterable<EnumValueWithTitle> values}) - Alias for TitledMultiSelectEnumSchema.new.
-
titledSingleSelect
→ const TitledSingleSelectEnumSchema Function({String? defaultValue, String? description, String? title, required Iterable<
EnumValueWithTitle> values}) - Alias for TitledSingleSelectEnumSchema.new.
-
untitledMultiSelect
→ const UntitledMultiSelectEnumSchema Function({Iterable<
String> ? defaultValue, String? description, int? maxItems, int? minItems, String? title, required Iterable<String> values}) - Alias for UntitledMultiSelectEnumSchema.new.
-
untitledSingleSelect
→ const UntitledSingleSelectEnumSchema Function({String? defaultValue, String? description, String? title, required Iterable<
String> values}) - Alias for UntitledSingleSelectEnumSchema.new.