Function type that can be provided to [[AsyncLock.withCallback]].
Key used if no key provided.
Decorator which runs the underlying method in AsyncLock.withLock.
This inherently converts the method to an async method!
function used to generate the key(s).
Input is the same arguments as the underlying method takes and this
is bound to the target.
Returning an array will cause each item to be used as a key. If you don't want this behaviour,
wrap the array in another array:
return [["key 1"]];
If undefined
no keys are used.
Generated using TypeDoc
Even though there is no thread safety to deal with thanks to the magic of Promises there is still a need for locks.