BaseValidationController<K> class abstract

Base class with common logic for ValidationController's

Implemented types
Implementers

Constructors

BaseValidationController([List<ValidationConnector<K, dynamic>> connectors = const []])

Properties

disposed bool
Returns true whenever controller is disposed
no setteroverride
errors Map<K, String>
Sync access to current validation error messages
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
isValid bool
Sync access to validation state
no setteroverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

addConnector(ValidationConnector<K, Object?> connector) → void
Add ValidationConnector to the active list.
override
addErrors(Map<K, String> errors) → void
Replace error messages
inherited
addFieldError(K field, String error) → void
Add error message for some particular field
override
attachConnectors(Iterable<ValidationConnector<K, Object?>> connectors) → void
Attach multiple ValidationConnector to the controller
override
clearErrors() → void
Clear all validation errors
override
clearFieldError(K field) → void
Remove error message from particular field
override
dispose() → void
Dispose method.
override
fieldError(K field) String?
Sync access to the validation error message if there is one
override
fieldErrorProvider(K field) ErrorProvider<K>
Provides ErrorProvider with validation error value for particular field.
inherited
fieldsError(Iterable<K> fields) Iterable<String>
Sync access to the validation error message if there is any.
override
fieldsErrorProvider(Iterable<K> fields) ErrorsProvider<K>
Provides ErrorsProvider with validation errors from multiple fields.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
removeConnector(ValidationConnector<K, Object?> connector) → void
Remove ValidationConnector.
override
toString() String
A string representation of this object.
inherited
validate() Future<void>
Invoke validation across all connected ValidationConnector
override

Operators

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