class SerializedCredentialProvider

Keep a shared credential provider's pending work in the coroutine invoking it.

Properties

protected Closure $provider
protected string $lockKey
static protected array<string, int> $owners

Methods

__construct(callable $provider)

Create a serialized credential provider.

string
identity(callable $provider)

Identify the state behind a callable: one lock per bound object, whichever method is called on it.

PromiseInterface
__invoke(mixed ...$arguments)

Resolve this caller's credentials before releasing the shared provider.

static void
flushState()

Flush all static state.

Details

at line 31
__construct(callable $provider)

Create a serialized credential provider.

Parameters

callable $provider

at line 40
protected string identity(callable $provider)

Identify the state behind a callable: one lock per bound object, whichever method is called on it.

Parameters

callable $provider

Return Value

string

at line 57
PromiseInterface __invoke(mixed ...$arguments)

Resolve this caller's credentials before releasing the shared provider.

Parameters

mixed ...$arguments

Return Value

PromiseInterface

at line 95
static void flushState()

Flush all static state.

Return Value

void