Table of Contents

Class LocalTrackPublication

Namespace
LiveKit.Rtc
Assembly
LivekitRtc.dll

Local track publication.

public class LocalTrackPublication : TrackPublication
Inheritance
LocalTrackPublication
Inherited Members

Properties

Participant

The local participant that owns this publication.

public LocalParticipant Participant { get; }

Property Value

LocalParticipant

Track

The local track.

public LocalTrack? Track { get; }

Property Value

LocalTrack

Methods

WaitForSubscriptionAsync(CancellationToken)

Waits until at least one remote participant has subscribed to this track. This is useful when you want to ensure someone is receiving your published track before proceeding (e.g., before starting to send audio/video frames).

public Task WaitForSubscriptionAsync(CancellationToken cancellationToken = default)

Parameters

cancellationToken CancellationToken

Cancellation token to abort the wait.

Returns

Task

A task that completes when the first subscription occurs.