SimpleMutex class

Mutex maintains a queue of Future-returning functions that are executed sequentially. The internal lock is not shared across Isolates by default.

Implemented types

Constructors

SimpleMutex()

Properties

hashCode int
The hash code for this object.
no setterinherited
last Future?
getter/setter pair
locked bool
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
shared SerializedMutex
Get a serialized instance that can be passed over to a different isolate.
no setter

Methods

close() Future<void>
Release resources used by the Mutex.
override
lock<T>(Future<T> callback(), {Duration? timeout}) Future<T>
timeout is a timeout for acquiring the lock, not for the callback
override
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