Effect<E, L, R> class
final
- Inheritance
-
- Available Extensions
Constructors
-
Effect.fail(L value)
-
{@category constructors}
factory
-
Effect.failCause(Cause<L> cause)
-
{@category constructors}
factory
-
Effect.from(FutureOr<Exit<L, R>> run(Context<E> context))
-
{@category constructors}
factory
-
Effect.fromNullable(R? value, {required L onNull()})
-
{@category constructors}
factory
-
Effect.functionFail(FutureOr<Cause<L>> f())
-
{@category constructors}
factory
-
Effect.functionSucceed(FutureOr<R> f())
-
{@category constructors}
factory
-
Effect.gen(DoFunctionEffect<E, L, R> f)
-
{@category constructors}
factory
-
Effect.lazy(Effect<E, L, R> effect())
-
{@category constructors}
factory
-
Effect.raceAll(Iterable<Effect<E, L, R>> iterable)
-
{@category constructors}
factory
-
Effect.succeed(R value)
-
{@category constructors}
factory
-
Effect.tryCatch({required FutureOr<R> execute(), required L onError(Object error, StackTrace stackTrace), FutureOr onCancel()?})
-
{@category constructors}
factory
Properties
-
asEffect
→ Effect<E, L, R>
-
no setteroverride
-
hashCode
→ int
-
The hash code for this object.
no setterinherited
-
orDie
→ Effect<E, Never, R>
-
{@category alternatives}
no setter
-
runtimeType
→ Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
alwaysIgnore<C>(Effect<E, L, C> effect)
→ Effect<E, L, R>
-
{@category sequencing}
-
ap<V>(Effect<E, L, V Function(R r)> f)
→ Effect<E, L, V>
-
{@category combining}
-
catchCause<C>(Effect<E, C, R> f(Cause<L> cause))
→ Effect<E, C, R>
-
{@category error_handling}
-
catchError<C>(Effect<E, C, R> f(L error))
→ Effect<E, C, R>
-
{@category error_handling}
-
delay(Duration duration)
→ Effect<E, L, R>
-
{@category delay}
-
either()
→ Effect<E, Never, Either<L, R>>
-
{@category conversions}
-
exit()
→ Effect<E, Never, Exit<L, R>>
-
{@category conversions}
-
filterOrDie<C>({required bool predicate(R r), required C orDieWith(R r)})
→ Effect<E, L, R>
-
{@category filtering}
-
filterOrElse({required bool predicate(R r), required Effect<E, L, R> orElse(R r)})
→ Effect<E, L, R>
-
{@category filtering}
-
flatMap<C>(Effect<E, L, C> f(R r))
→ Effect<E, L, C>
-
{@category sequencing}
-
flatMapEnv<C>(Effect<E, L, C> f(R r, E env))
→ Effect<E, L, C>
-
{@category sequencing}
-
flip()
→ Effect<E, R, L>
-
{@category mapping}
-
interrupt()
→ Effect<E, Never, R>
-
{@category interruption}
-
map<V>(V f(R r))
→ Effect<E, L, V>
-
{@category mapping}
-
mapBoth<C, D>(C fl(L l), D fr(R r))
→ Effect<E, C, D>
-
{@category mapping}
-
mapContext<V>(Context<E> f(Context<V> context))
→ Effect<V, L, R>
-
{@category context}
-
mapEnv<V>(E f(V env))
→ Effect<V, L, R>
-
{@category context}
-
mapError<C>(C f(L l))
→ Effect<E, C, R>
-
{@category mapping}
-
mapErrorCause<C>(C f(Cause<L> l))
→ Effect<E, C, R>
-
{@category mapping}
-
match<C>({required C onFailure(L l), required C onSuccess(R r)})
→ Effect<E, Never, C>
-
{@category folding}
-
matchCause<C>({required C onFailure(Cause<L> l), required C onSuccess(R r)})
→ Effect<E, Never, C>
-
{@category folding}
-
matchCauseEffect<C, D>({required Effect<E, C, D> onFailure(Cause<L> l), required Effect<E, C, D> onSuccess(R r)})
→ Effect<E, C, D>
-
{@category folding}
-
matchEffect<C, D>({required Effect<E, C, D> onFailure(L l), required Effect<E, C, D> onSuccess(R r)})
→ Effect<E, C, D>
-
{@category folding}
-
noSuchMethod(Invocation invocation)
→ dynamic
-
Invoked when a nonexistent method or property is accessed.
inherited
-
option()
→ Effect<E, Never, Option<R>>
-
{@category conversions}
-
orDieWith<T extends Object>(T onError(L l))
→ Effect<E, Never, R>
-
{@category alternatives}
-
orElse<C>(Effect<E, C, R> orElse(L l))
→ Effect<E, C, R>
-
{@category alternatives}
-
provide(Context<E> context)
→ Effect<Null, L, R>
-
{@category context}
-
provideEffect<V>(Effect<V, L, E> effect)
→ Effect<V, L, R>
-
{@category context}
-
provideEnv(E env)
→ Effect<Null, L, R>
-
{@category context}
-
race(Effect<E, L, R> effect)
→ Effect<E, L, R>
-
{@category sequencing}
-
tap<C>(Effect<E, L, C> f(R r))
→ Effect<E, L, R>
-
{@category sequencing}
-
tapEnv<C>(Effect<E, L, C> f(R r, E env))
→ Effect<E, L, R>
-
{@category sequencing}
-
tapError<C>(Effect<E, C, R> f(L l))
→ Effect<E, L, R>
-
{@category sequencing}
-
timeout(Duration duration)
→ Effect<E, L, R>
-
{@category delay}
-
toString()
→ String
-
A string representation of this object.
override
-
zipLeft<C>(Effect<E, L, C> effect)
→ Effect<E, L, R>
-
{@category zipping}
-
zipRight<C>(Effect<E, L, C> effect)
→ Effect<E, L, C>
-
{@category zipping}
-
zipWith<B, C>(Effect<E, L, B> effect, C f(R r, B b))
→ Effect<E, L, C>
-
{@category zipping}
Static Methods
-
all<E, L, R>(Iterable<Effect<E, L, R>> iterable)
→ Effect<E, L, Iterable<R>>
-
{@category collecting}
-
die<E>(dynamic defect)
→ Effect<E, Never, Never>
-
{@category constructors}
-
env<E, L>()
→ Effect<E, L, E>
-
{@category context}
-
forEach<E, L, R, A>(Iterable<A> iterable, Effect<E, L, R> f(A a, int index))
→ Effect<E, L, Iterable<R>>
-
{@category collecting}
-
functionDie<E>(dynamic run())
→ Effect<E, Never, Never>
-
{@category constructors}
-
sleep<E, L>(Duration duration)
→ Effect<E, L, void>
-
{@category constructors}
-
unit<E, L>()
→ Effect<E, L, Unit>
-
{@category constructors}