StringControl class
Extended version of FieldControl specified to String.
- Inheritance
-
- Object
- ObservableValue<
String?> - ObservableModel<
String?> - FieldControl<
String?> - StringControl
- Available Extensions
Constructors
- StringControl([String? value])
- FieldControl of String.
- StringControl.withRegex({String? value, String? regex})
- FieldControl of String with regex validation.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- internalData ↔ dynamic
-
getter/setter pairinherited
- isActive → bool
-
Checks if Stream is not closed.
no setterinherited
- isClosed → bool
-
Returns true if current stream is closed.
no setterinherited
- isEmpty → bool
-
Returns 'true' if value is 'null' or empty String.
no setteroverride
- isNotEmpty → bool
-
Returns 'true' if value is not 'null' and not empty.
no setteroverride
- isValid → bool
-
no setterinherited
- regex ↔ String?
-
Current regex for validation.
setWithRegex will be called if regex is not null.
getter/setter pair
- requestValidation → bool
-
Checks if regex is filled and validation is required.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
sink
→ Sink<
String?> -
Default sink of this controller.
Use sinkConverter to convert input data.
no setterinherited
-
stream
→ Stream<
String?> -
no setterinherited
- value ↔ String?
-
getter/setter pairinherited
Methods
-
cancel(
ControlSubscription< String?> subscription) → void -
inherited
-
cast<
U> () → ObservableValue< U> -
inherited
-
dispose(
) → void -
Used to clear and dispose object.
After this method call is object typically unusable and ready for GC.
Can be called multiple times!
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
notify(
) → void -
Notifies current Stream.
inherited
-
onFuture(
Future future, {ValueConverter? converter}) → Future -
Sets value after
future
finishes. Via ValueConverter is possible to convert object from input Stream type to own stream value. Returns Future to await and register other callbacks.inherited -
setValue(
String? value, {bool notify = true, bool forceNotify = false}) → void -
override
-
setWithRegex(
String? value, {String? regex, bool notify = true, bool forceNotify = false}) → void -
Sets given
value
only ifregex
matches. -
sinkConverter(
ValueConverter< String?> converter) → Sink -
Returns Sink with custom ValueConverter.
inherited
-
softDispose(
) → void -
Clears subscribers, but didn't close Stream entirely.
inherited
-
subscribe(
ValueCallback< String?> action, {bool current = true, dynamic args}) → FieldSubscription<String?> -
inherited
-
subscribeStream(
void onData(String? event), {Function? onError, void onDone()?, bool cancelOnError = false, bool current = true}) → FieldSubscription< String?> -
inherited
-
subscribeTo(
Stream stream, {Function? onError, void onDone()?, bool cancelOnError = false, ValueConverter? converter}) → FieldSubscription -
Subscribes this field to given Stream.
Controller will subscribe to input stream and will listen for changes and populate this changes into own stream.
Via ValueConverter is possible to convert object from input Stream type to own stream value.
StreamSubscription is automatically closed during dispose phase of FieldControl.
Returns FieldSubscription for manual cancellation.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited