class documentation

Wraps VisitorFunctions to cap concurrent payload visits via a semaphore.

After the full traversal, call drain() to await all in-flight tasks.

Method __init__ Undocumented
Async Method drain Wait for all in-flight background tasks to complete.
Async Method visit_payload Called when encountering a single payload.
Async Method visit_payloads Called when encountering multiple payloads together.
Instance Variable _inner Undocumented
Instance Variable _sem Undocumented
Instance Variable _tasks Undocumented
def __init__(self, inner: VisitorFunctions, sem: asyncio.Semaphore): (source)

Undocumented

async def drain(self): (source)

Wait for all in-flight background tasks to complete.

On cancellation or error, cancels all remaining tasks and awaits them so their finally blocks run before this coroutine returns.

async def visit_payload(self, payload: Payload): (source)

Called when encountering a single payload.

async def visit_payloads(self, payloads: MutableSequence[Payload]): (source)

Called when encountering multiple payloads together.

Undocumented

Undocumented

Undocumented