MediaStatsCollector interface

Media stats collector.

Methods

dispose()

Dispose collector.

off("sampleReported", MediaStatsReportSampleEvent)

Unsubscribe function for raw mediaStatsReport event.

off("summaryReported", MediaStatsReportSummaryEvent)

Unsubscribe function for MediaStatsReportSummary event.

on("sampleReported", MediaStatsReportSampleEvent)

Subscribe function for MediaStatsReportSample event.

on("summaryReported", MediaStatsReportSummaryEvent)

Subscribe function for MediaStatsReportSummary event.

Method Details

dispose()

Dispose collector.

function dispose()

off("sampleReported", MediaStatsReportSampleEvent)

Unsubscribe function for raw mediaStatsReport event.

function off(event: "sampleReported", listener: MediaStatsReportSampleEvent)

Parameters

event

"sampleReported"

event name

listener
MediaStatsReportSampleEvent

callback fn that was used to subscribe to this event

off("summaryReported", MediaStatsReportSummaryEvent)

Unsubscribe function for MediaStatsReportSummary event.

function off(event: "summaryReported", listener: MediaStatsReportSummaryEvent)

Parameters

event

"summaryReported"

event name

listener
MediaStatsReportSummaryEvent

callback fn that was used to subscribe to this event

on("sampleReported", MediaStatsReportSampleEvent)

Subscribe function for MediaStatsReportSample event.

function on(event: "sampleReported", listener: MediaStatsReportSampleEvent)

Parameters

event

"sampleReported"

event name

listener
MediaStatsReportSampleEvent

callback fn that was used to subscribe to this event

on("summaryReported", MediaStatsReportSummaryEvent)

Subscribe function for MediaStatsReportSummary event.

function on(event: "summaryReported", listener: MediaStatsReportSummaryEvent)

Parameters

event

"summaryReported"

event name

listener
MediaStatsReportSummaryEvent

callback fn that was used to subscribe to this event