MapInput<K, V, E> class
abstract
- Inheritance
- Implementers
Constructors
-
MapInput.fromData(InputData<
Map< data)K, V> , E> -
MapInput.touched({Map<
K, V> value = const {}, Map<K, V> ? initialValue, ValidationMode mode = ValidationMode.live, E? errorCache, E? remoteError}) -
const
-
MapInput.untouched({Map<
K, V> value = const {}, ValidationMode mode = ValidationMode.live, E? errorCache}) -
const
Properties
-
asyncValidators
→ List<
AsyncValidator< Map< >K, V> , E> -
Asynchronous validators run via InputMixin.runBuiltInAsyncValidation.
no setterinherited
- currentRemoteError → E?
-
no setterinherited
-
detailedErrors
→ List<
E> -
ALL validation errors for the current value — bypasses the cache.
Use for password-strength meters or multi-requirement checklists.
no setterinherited
- error → E?
-
Remote errors take precedence over local ones.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
-
initialValue
→ Map<
K, V> -
finalinherited
- isDirty → bool
-
True when the current value differs from initialValue.
no setterinherited
- isNotValid → bool
-
no setterinherited
- isPristine → bool
-
True when the current value equals the initialValue (user has not
changed the field from its starting state).
no setterinherited
- isTouched → bool
-
no setterinherited
- isUntouched → bool
-
no setterinherited
- isValid → bool
-
no setterinherited
- isValidating → bool
-
no setterinherited
- localError → E?
-
no setterinherited
- mode → ValidationMode
-
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
sanitizers
→ List<
Sanitizer< Map< >K, V> > -
no setterinherited
- status → InputStatus
-
finalinherited
-
validators
→ List<
Validator< Map< >K, V> , E> -
Synchronous validators run against value.
no setterinherited
-
value
→ Map<
K, V> -
finalinherited
-
valueSanitizers
→ List<
Sanitizer< V> > -
Sanitizers applied to every individual value in the map.
no setter
-
valueValidators
→ List<
Validator< V, E> > -
Validators applied to every individual value in the map.
no setter
Methods
-
displayError(
SubmissionStatus status) → E? -
Resolves the error to show in the UI based on SubmissionStatus and ValidationMode.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
prepareUpdate(
{Map< K, V> ? value, InputStatus? status, ValidationMode? mode, E? remoteError}) → InputData<Map< K, V> , E> -
⚠️ Known limitation: when
Tis nullable (e.g.,DateTime?), passingvalue: nullis indistinguishable from omittingvalue. Use InputMixin.reset to revert a nullable field to its initial value.inherited -
putItem(
K key, V item) → MapInput< K, V, E> -
Inserts or replaces the entry at
keywithitem, runs valueSanitizers on the item, and marks the input as touched. -
removeItem(
K key) → MapInput< K, V, E> -
Removes the entry at
keyand marks the input as touched. Returnsthisunchanged ifkeyis not present. -
sanitize(
Map< K, V> value) → Map<K, V> -
Sanitizes each value through valueSanitizers after running
map-level sanitizers from sanitizers.
override
-
toString(
) → String -
A string representation of this object.
inherited
-
update(
{Map< K, V> ? value, InputStatus? status, ValidationMode? mode, E? remoteError}) → MapInput<K, V, E> -
override
-
validate(
Map< K, V> value) → E? -
Validates the map structure first, then each value individually.
override
-
validateAsync(
Map< K, V> value) → Future<E?> -
inherited
-
valueErrorAt(
K key) → E? -
Returns the validation error for the value at
key, or null if the key does not exist or the value is valid.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited