jeeves-meta-monorepo
    Preparing search index...

    Class SynthesisQueue

    Single-threaded synthesis queue.

    Only one synthesis runs at a time. Priority items are inserted at the front of the queue. Duplicate paths are rejected with their current position returned.

    Index

    Constructors

    Accessors

    Methods

    • Get the 0-indexed position of a path in the queue.

      Parameters

      • path: string

        Meta path to look up.

      Returns number | null

      Position index, or null if not found in the queue.

    • Check whether a path is in the queue or currently being synthesized.

      Parameters

      • path: string

        Meta path to look up.

      Returns boolean

      True if the path is queued or currently running.

    • Set a callback to invoke when a new (non-duplicate) item is enqueued.

      Parameters

      • callback: () => void

      Returns void

    • Process queued items one at a time until the queue is empty.

      Re-entry is prevented: if already processing, the call returns immediately. Errors are logged and do not block subsequent items.

      Parameters

      • synthesizeFn: (path: string) => Promise<void>

        Async function that performs synthesis for a path.

      Returns Promise<void>