augment-vir - v32.2.2
    Preparing search index...

    Class PromiseQueue

    A queue that manages its items with promises.

    Hierarchy

    Index
    currentlyAwaiting: PromiseQueueItem<any> | undefined = undefined
    queue: PromiseQueueItem<any>[] = []
    queueItemIds: Set<PropertyKey> = ...
    • Add an item to the queue. Only await this if you want to wait for the promise to be added and resolved (or rejected).

      Type Parameters

      • T = void

      Parameters

      Returns Promise<T>

      A promise that resolves at the same time as the added item.

    • Checks if the given id is currently in the queue.

      Parameters

      • id: PropertyKey

      Returns boolean

      true if the item is in the queue and has not been resolved or rejected. false if the item has never been in the queue or has been resolved / rejected from the queue.