/** * A simple async lock implementation. This lock * is not reentrant. */ export declare class AsyncLock { private locked; private waitingResolvers; /** * Acquire the lock. If the lock is already * acquired, the next caller wait until it is * released. * @returns a promise that resolves when the * lock is acquired */ acquire(): Promise; /** * Release the lock. If there are waiting promises, * resolve the first one. */ release(): void; }