JEffect<T> class abstract

Base class representing a one-time side effect with an optional result.

Extensions:

  • Provides an ID and timestamp for tracing.
  • Allows completion with a value OR error.
  • Idempotent completion (subsequent calls ignored).
Implementers

Constructors

JEffect()

Properties

createdAt → DateTime
final
hashCode → int
The hash code for this object.
no setterinherited
id → String
final
isCompleted → bool
Whether the effect has already been completed.
no setter
resolvedCategory → String?
Returns a category (if any).
no setter
result → Future<T>
Future that completes when the effect is handled (or failed).
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

complete(T value) → void
Completes the effect with a value (idempotent).
completeError(Object error, [StackTrace? st]) → void
Completes the effect with an error (idempotent).
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
inherited