FieldBlocState<Value, Suggestion, ExtraData> class
abstract
- Mixed-in types
Constructors
-
FieldBlocState.new({required bool isValueChanged, required Value initialValue, required Value updatedValue, required Value value, required Object? error, required bool isDirty, required Suggestions<
Suggestion> ? suggestions, required bool isValidated, required bool isValidating, required FormBloc? formBloc, required String name, required dynamic toJson(Value value)?, required ExtraData extraData})
Properties
- canShowError → bool
-
Indicates if this state has error and is not initial.
no setter
- canShowIsValidating → bool
-
Indicates if this state is validating and is not initial.
no setter
- error → Object?
-
The current error of this state.
final
- extraData → ExtraData
-
Extra data that contains the data
you added when you created the field bloc
or use SingleFieldBloc.updateExtraData.
final
- formBloc → FormBloc?
-
The current FormBloc that contains this
FieldBloc
.final - hasDirt → bool
-
no setter
- hasError → bool
-
Indicates if error is not
null
.no setter - hasFormBloc → bool
-
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- hasInitialValue → bool
-
Indicate if this field has value from
FieldBloc.updateInitialValue
method.no setter - hasUpdatedValue → bool
-
Indicate if this field has value from
FieldBloc.updateValue
method.no setter - hasValue → bool
-
Indicates if value is not
null
.no setter - initialValue → Value
-
final
- isDirty → bool
-
Indicate if this field was value updated by SingleFieldBloc.changeValue / SingleFieldBloc.updateValue
or receive a external validation by SingleFieldBloc.validate.
final
- isInitial → bool
-
no setter
- isValid → bool
-
Indicates if this state
not has error (which means that the error is not
null
) and not is validating and is validatedno setteroverride - isValidated → bool
-
Indicate if value was checked with the validators
of the FieldBloc.
final
- isValidating → bool
-
Indicate if value is is being verified with any async validator
of the FieldBloc.
final
- isValueChanged → bool
-
Returns true when the value has been changed by
FieldBloc.changeValue
.final - name → String
-
It is the string that identifies the FieldBloc.
final
-
props
→ List<
Object?> -
The list of properties that will be used to determine whether
two instances are equal.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- stringify → bool?
-
If set to
true
, thetoString
method will be overridden to output this instance'sprops
.no setterinherited -
suggestions
→ Suggestions<
Suggestion> ? -
Function that returns a list of suggestions
which can be used to update the value.
final
- updatedValue → Value
-
final
- value → Value
-
The current value of this state.
final
Methods
-
copyWith(
{bool? isValueChanged, Param< Value> ? initialValue, Param<Value> ? updatedValue, Param<Value> ? value, Param<Object?> ? error, bool? isDirty, Param<Suggestions< ? suggestions, bool? isValidated, bool? isValidating, Param<Suggestion> ?>FormBloc?> formBloc, Param<ExtraData> ? extraData}) → FieldBlocState<Value, Suggestion, ExtraData> - Returns a copy of the current state by changing the values that are passed as parameters.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Object? -
Transform value in a JSON value.
By default returns value, but you can
set in the constructor of the
FieldBloc
-
toString(
[String extra = '']) → String - A string representation of this object.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited