Skip to content

Interface: LiveObjectSource ​

Push-oriented live object feed. Wraps a ReadableStream plus lightweight event subscription helpers. Implementations advance largestLocation monotonically as objects arrive.

Properties ​

largestLocation ​

readonly largestLocation: Location | undefined

Highest (latest) location observed so far; undefined until first object


stream ​

readonly stream: ReadableStream<MoqtObject>

Continuous stream yielding objects as they are produced

Methods ​

onDone() ​

onDone(listener): () => void

Register a listener invoked when the live stream ends (normal or error). Returns an unsubscribe function.

Parameters ​

listener ​

() => void

Returns ​

() => void


onNewObject() ​

onNewObject(listener): () => void

Register a listener invoked (async) for each new object. Returns an unsubscribe function.

Parameters ​

listener ​

(obj) => void

Returns ​

() => void


stop() ​

stop(): void

Stop ingestion and release underlying reader (idempotent).

Returns ​

void