AsyncData<T extends Object> class
sealed
定义一个基于异步状态的数据结构
- Available extensions
Constructors
- AsyncData.error(Object error, [StackTrace? stackTrace])
-
factory
- AsyncData.loading()
-
factory
- AsyncData.value(T value)
-
factory
Properties
- data → T
-
Available on AsyncData<
T> , provided by the AsyncDataTypedExt extensionno setter - dataOrNull → T?
-
Available on AsyncData<
T> , provided by the AsyncDataTypedExt extensionno setter - error → Object
-
Available on AsyncData<
T> , provided by the AsyncDataTypedExt extensionno setter - hasData → bool
-
Available on AsyncData<
T> , provided by the AsyncDataTypedExt extensionno setter - hasError → bool
-
Available on AsyncData<
T> , provided by the AsyncDataTypedExt extensionno setter - hashCode → int
-
The hash code for this object.
no setterinherited
- hasValue → bool
-
Available on AsyncData<
T> , provided by the AsyncDataTypedExt extensionno setter - isLoading → bool
-
Available on AsyncData<
T> , provided by the AsyncDataTypedExt extensionno setter - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- stackTrace → StackTrace?
-
Available on AsyncData<
T> , provided by the AsyncDataTypedExt extensionno setter - value → T
-
Available on AsyncData<
T> , provided by the AsyncDataTypedExt extensionno setter - valueOrNull → T?
-
Available on AsyncData<
T> , provided by the AsyncDataTypedExt extensionno setter
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
when<
R> ({required R loading(), required R value(T value), required R error(Object error, StackTrace? stackTrace)}) → R -
Available on AsyncData<
T> , provided by the AsyncDataTypedExt extension
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited