Search Results for

    / fm / liveswitch / ConnectionStats

    Class: ConnectionStats

    fm.liveswitch.ConnectionStats

    Connection stats.

    Hierarchy

    • BaseStats

      ↳ ConnectionStats

    Table of contents

    Constructors

    • constructor

    Methods

    • deserializeProperties
    • getAudioMediaQuality
    • getAudioNetworkQuality
    • getAudioStream
    • getAudioStreams
    • getDataStream
    • getExternalId
    • getId
    • getIsHost
    • getIsReflexive
    • getIsRelayed
    • getMediaQuality
    • getMediaStream
    • getMediaStreams
    • getNetworkQuality
    • getState
    • getStreams
    • getTimestamp
    • getTypeString
    • getVideoMediaQuality
    • getVideoNetworkQuality
    • getVideoStream
    • getVideoStreams
    • serializeProperties
    • setExternalId
    • setState
    • toJson
    • fromJson
    • toJson

    Constructors

    constructor

    + new ConnectionStats(): ConnectionStats

    Returns: ConnectionStats

    Inherited from: BaseStats

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:20

    Methods

    deserializeProperties

    ▸ ProtecteddeserializeProperties(key: string, valueJson: string): void

    Deserializes the properties.

    Parameters:

    Name Type Description
    key string The key.
    valueJson string The value in JSON format.

    Returns: void

    Overrides: BaseStats

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:72


    getAudioMediaQuality

    ▸ getAudioMediaQuality(): number

    Gets the audio streams' minimum estimated media quality.
    The value ranges from 0.0 to 1.0, where 0.0 is the lowest quality and 1.0 is the highest quality.

    Returns: number

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:104


    getAudioNetworkQuality

    ▸ getAudioNetworkQuality(): number

    Gets the audio streams' minimum estimated network quality.
    The value ranges from 0.0 to 1.0, where 0.0 is the lowest quality and 1.0 is the highest quality.

    Returns: number

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:125


    getAudioStream

    ▸ getAudioStream(): MediaStreamStats

    Gets the first audio stream's stats.

    Returns: MediaStreamStats

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:144


    getAudioStreams

    ▸ getAudioStreams(): MediaStreamStats[]

    Gets the audio streams' stats.

    Returns: MediaStreamStats[]

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:156


    getDataStream

    ▸ getDataStream(): DataStreamStats

    Gets the data stream's stats.

    Returns: DataStreamStats

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:177


    getExternalId

    ▸ getExternalId(): string

    Gets the external identifier.

    Returns: string

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:189


    getId

    ▸ getId(): string

    Gets the identifier of the object generating these stats.

    Returns: string

    Inherited from: BaseStats

    Defined in: Generated/TypeScript/fm.liveswitch/BaseStats.ts:57


    getIsHost

    ▸ getIsHost(): boolean

    Gets whether any of the streams are using a transport whose active candidate pair has a host candidate.

    Returns: boolean

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:202


    getIsReflexive

    ▸ getIsReflexive(): boolean

    Gets whether any of the streams are using a transport whose active candidate pair has a reflexive candidate.

    Returns: boolean

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:223


    getIsRelayed

    ▸ getIsRelayed(): boolean

    Gets whether any of the streams are using a transport whose active candidate pair has a relayed candidate.

    Returns: boolean

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:244


    getMediaQuality

    ▸ getMediaQuality(): number

    Gets the connection's estimated media quality as the minimum of the [[fm.liveswitch.connectionStats.audioMediaQuality]] and the [[fm.liveswitch.connectionStats.videoMediaQuality]].
    The value ranges from 0.0 to 1.0, where 0.0 is the lowest quality and 1.0 is the highest quality.

    Returns: number

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:266


    getMediaStream

    ▸ getMediaStream(): MediaStreamStats

    Gets the first media stream's stats.

    Returns: MediaStreamStats

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:278

    ▸ getMediaStream(mediaStreamId: string): MediaStreamStats

    Gets a media stream by its identifier.

    Parameters:

    Name Type Description
    mediaStreamId string The media stream identifier.

    Returns: MediaStreamStats

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:285


    getMediaStreams

    ▸ getMediaStreams(): MediaStreamStats[]

    Gets the media streams' stats.

    Returns: MediaStreamStats[]

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:306


    getNetworkQuality

    ▸ getNetworkQuality(): number

    Gets the connection's estimated network quality as the minimum of the [[fm.liveswitch.connectionStats.audioNetworkQuality]] and the [[fm.liveswitch.connectionStats.videoNetworkQuality]].
    The value ranges from 0.0 to 1.0, where 0.0 is the lowest quality and 1.0 is the highest quality.

    Returns: number

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:320


    getState

    ▸ getState(): ConnectionState

    Gets the state.

    Returns: ConnectionState

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:332


    getStreams

    ▸ getStreams(): StreamStats[]

    Gets the streams' stats.

    Returns: StreamStats[]

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:344


    getTimestamp

    ▸ getTimestamp(): DateTime

    Gets the timestamp when these stats were generated.

    Returns: DateTime

    Inherited from: BaseStats

    Defined in: Generated/TypeScript/fm.liveswitch/BaseStats.ts:70


    getTypeString

    ▸ getTypeString(): string

    Returns: string

    Overrides: BaseStats

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:10


    getVideoMediaQuality

    ▸ getVideoMediaQuality(): number

    Gets the video streams' minimum estimated media quality.
    The value ranges from 0.0 to 1.0, where 0.0 is the lowest quality and 1.0 is the highest quality.

    Returns: number

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:369


    getVideoNetworkQuality

    ▸ getVideoNetworkQuality(): number

    Gets the video streams' minimum estimated network quality.
    The value ranges from 0.0 to 1.0, where 0.0 is the lowest quality and 1.0 is the highest quality.

    Returns: number

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:390


    getVideoStream

    ▸ getVideoStream(): MediaStreamStats

    Gets the first video stream's stats.

    Returns: MediaStreamStats

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:409


    getVideoStreams

    ▸ getVideoStreams(): MediaStreamStats[]

    Gets the video streams' stats.

    Returns: MediaStreamStats[]

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:421


    serializeProperties

    ▸ ProtectedserializeProperties(jsonObject: Hash<string, string>): void

    Serializes the properties.

    Parameters:

    Name Type Description
    jsonObject Hash<string, string> The JSON object.

    Returns: void

    Overrides: BaseStats

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:443


    setExternalId

    ▸ setExternalId(value: string): void

    Sets the external identifier.

    Parameters:

    Name Type
    value string

    Returns: void

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:473


    setState

    ▸ setState(value: ConnectionState): void

    Sets the state.

    Parameters:

    Name Type
    value ConnectionState

    Returns: void

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:493


    toJson

    ▸ toJson(): string

    Serializes this to JSON.

    Returns: string

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:561


    fromJson

    ▸ StaticfromJson(connectionJson: string): ConnectionStats

    Derializes connection stats from JSON.

    Parameters:

    Name Type Description
    connectionJson string The connection's stats JSON.

    Returns: ConnectionStats

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:39


    toJson

    ▸ StatictoJson(connection: ConnectionStats): string

    Serializes connection stats to JSON.

    Parameters:

    Name Type Description
    connection ConnectionStats The connection's stats.

    Returns: string

    Defined in: Generated/TypeScript/fm.liveswitch/ConnectionStats.ts:56

    In This Article
    Back to top Copyright © LiveSwitch Inc. All Rights Reserved. Doc build for LiveSwitch v1.14.6