Skip to content

node-av / api / SchedulerControl

Class: SchedulerControl<TSend> ​

Defined in: src/api/utilities/scheduler.ts:145

Control interface for completed pipelines.

Provides control methods without pipeTo() - this is the final stage after piping to Muxer.

Type Parameters ​

TSend ​

TSend = Packet | Frame

The input type flowing through the pipeline

Constructors ​

Constructor ​

new SchedulerControl<TSend>(firstComponent): SchedulerControl<TSend>

Defined in: src/api/utilities/scheduler.ts:153

Internal

Parameters ​

firstComponent ​

SchedulableComponent<TSend>

First component in the pipeline

Returns ​

SchedulerControl<TSend>

Methods ​

send() ​

send(item): Promise<void>

Defined in: src/api/utilities/scheduler.ts:174

Send an item into the pipeline or flush.

When item is provided, queues it for processing through the pipeline. When null is provided, triggers flush sequence through all components.

Parameters ​

item ​

TSend | null

Packet or Frame to process, or null to flush

Returns ​

Promise<void>

Example ​

typescript
// Send packet for processing
await control.send(packet);

// Flush pipeline
await control.send(null);