response_builder library

Key types

Classes

DefaultBuildActions
Default building actions that used by BuildResultListenable and BuildAsyncResult
HistoryValueNotifier<T>
A ValueListenable implementation that kept the history of the changes
Request<T>
Request is a listenable data source that loads data in either synchronous or asynchronous manner.
ResultListenable<T>
An interface for subclasses of Listenable that expose a result.
ResultNotifier<T>
ResultNotifier is just like ValueNotifier but support to hold error along with value.

Mixins

BuildAsyncResult<T>
Protocol that builds 3-state async result, which can be:
BuildAsyncSnapshot<T>
Protocol that builds 3-state async result from a Future, a Stream or a Request
BuildResult<T>
Protocol that builds 2-state sync result, which could be either a value or an error BuildResult implements BuildValue
BuildValue<T>
Protocol that builds value
BuildWithBuilder
BuildWithBuilderInLocalContext
WithEmptyValue<T>
Protocol to build data which potentially could be empty

Extensions

BuildAsyncSnapshotActions
BuildResultListenable
Actions that depends on Protocol BuildResult
BuildValueListenable
Actions that depends on Protocol ValueListenable

Typedefs

AsyncValueUpdater<T> = Future<T> Function(T current)
Contract of asynchronous value updater
ErrorFixer<T> = T Function(Object error)
Contract of error fixer
ValueUpdater<T> = T Function(T current)
Contract of synchronous value updater
ValueWidgetBuilder<T> = Widget Function(BuildContext context, T value)