LocalTrackPublication<T extends LocalTrack> constructor

LocalTrackPublication<T extends LocalTrack>(
  1. {required LocalParticipant participant,
  2. required TrackInfo info,
  3. required T track}
)

Implementation

LocalTrackPublication({
  required this.participant,
  required lk_models.TrackInfo info,
  required T track,
}) : super(info: info) {
  updateTrack(track);
  // register dispose func
  onDispose(() async {
    // this object is responsible for disposing track
    await this.track?.dispose();
  });
}