---
url: https://docs.moqtail.dev/ts/api/client/interfaces/LiveObjectSource.md
---
# Interface: LiveObjectSource

Push-oriented live object feed. Wraps a [ReadableStream](https://developer.mozilla.org/docs/Web/API/ReadableStream) plus lightweight event subscription helpers.
Implementations advance [largestLocation](#largestlocation) monotonically as objects arrive.

## Properties

### largestLocation

> `readonly` **largestLocation**: [`Location`](../../model/classes/Location.md) | `undefined`

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

***

### stream

> `readonly` **stream**: `ReadableStream`<[`MoqtObject`](../../model/classes/MoqtObject.md)>

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`
