DraftModeFormAttribute<T> class

Mutable form-facing attribute that keeps a committed value, validation metadata, and synchronous normalizers together.

Constructors

DraftModeFormAttribute(T? value, {DraftModeFieldDefinition<T>? definition, String? debugName, DraftModeValidator<T>? validator, List<DraftModeValidator<T>>? validators})
DraftModeFormAttribute.fromDefinition(DraftModeFieldDefinition<T> definition, {T? value})
factory

Properties

debugName String?
final
definition DraftModeFieldDefinition<T>?
final
error DraftModeValidationIssue?
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
value ↔ T?
getter/setter pair

Methods

addValidator(DraftModeValidator<T> validator) → void
addValueMapper(T mapper(T value)) → void
mapValue(T? value) → T?
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited
validateIssue(DraftModeFormValueContext? form, T? value) DraftModeValidationIssue?
validateMessage(BuildContext context, DraftModeFormValueContext? form, T? value) String?
validatorByType(DraftModeValidatorType type) DraftModeTypedValidator<T>?
validatorsByType(DraftModeValidatorType type) Iterable<DraftModeTypedValidator<T>>

Operators

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