CallOnce<R> class final

Executes the provided Function exactly once, even if called concurrently.

Constructors

CallOnce(Function _closure)

Properties

hashCode → int
The hash code for this object.
no setterinherited
isCompleted → bool
True if the asynchronous call to this CallOnce is already completed.
no setter
result → Future<R>
The cached result from call.
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
wasCalled → bool
True if this CallOnce has already been called.
no setter

Methods

call([List? positionalArguments, Map<Symbol, dynamic>? namedArguments]) → Future<R>
Call the closure, which was provided as an argument to the CallOnce constructor, with the specified arguments.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

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