Class MediaStreamStats
Media stream stats.
Inherited Members
Namespace: FM.LiveSwitch
Assembly: FM.LiveSwitch.dll
Syntax
public class MediaStreamStats : StreamStats
Properties
Direction
Gets the direction.
Declaration
public StreamDirection Direction { get; }
Property Value
| Type | Description |
|---|---|
| StreamDirection |
MaxReceiveBitrate
Gets the max receive bitrate.
Declaration
public int MaxReceiveBitrate { get; }
Property Value
| Type | Description |
|---|---|
| System.Int32 |
MaxSendBitrate
Gets the max send bitrate.
Declaration
public int MaxSendBitrate { get; }
Property Value
| Type | Description |
|---|---|
| System.Int32 |
MediaQuality
Gets the stream's estimated media quality as the minimum of the sender media quality and the receiver 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.
Declaration
public double MediaQuality { get; }
Property Value
| Type | Description |
|---|---|
| System.Double |
NetworkQuality
Gets the stream's estimated network quality as the minimum of the SenderNetworkQuality and the ReceiverNetworkQuality.
The value ranges from 0.0 to 1.0, where 0.0 is the lowest quality and 1.0 is the highest quality.
Declaration
public double NetworkQuality { get; }
Property Value
| Type | Description |
|---|---|
| System.Double |
Receiver
Gets the first receiver's stats.
Declaration
public MediaReceiverStats Receiver { get; }
Property Value
| Type | Description |
|---|---|
| MediaReceiverStats |
ReceiverMediaQuality
Gets the receivers' 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.
Declaration
public double ReceiverMediaQuality { get; }
Property Value
| Type | Description |
|---|---|
| System.Double |
ReceiverNetworkQuality
Gets the receivers' 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.
Declaration
public double ReceiverNetworkQuality { get; }
Property Value
| Type | Description |
|---|---|
| System.Double |
ReceiverNetworkScore
Gets the receivers' estimated network score.
The value ranges from 1.0 to 5.0, where 1.0 is the lowest score and 5.0 is the highest score.
Declaration
public double ReceiverNetworkScore { get; }
Property Value
| Type | Description |
|---|---|
| System.Double |
Receivers
Gets the receivers' stats.
Declaration
public MediaReceiverStats[] Receivers { get; }
Property Value
| Type | Description |
|---|---|
| MediaReceiverStats[] |
Sender
Gets the first sender's stats.
Declaration
public MediaSenderStats Sender { get; }
Property Value
| Type | Description |
|---|---|
| MediaSenderStats |
SenderMediaQuality
Gets the senders' 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.
Declaration
public double SenderMediaQuality { get; }
Property Value
| Type | Description |
|---|---|
| System.Double |
SenderNetworkQuality
Gets the senders' 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.
Declaration
public double SenderNetworkQuality { get; }
Property Value
| Type | Description |
|---|---|
| System.Double |
Senders
Gets the senders' stats.
Declaration
public MediaSenderStats[] Senders { get; }
Property Value
| Type | Description |
|---|---|
| MediaSenderStats[] |
Methods
DeserializeProperties(String, String)
Deserializes the properties.
Declaration
protected override void DeserializeProperties(string key, string valueJson)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | key | The key. |
| System.String | valueJson | The value in JSON format. |
Overrides
FromJson(String)
Derializes media stream stats from JSON.
Declaration
public static MediaStreamStats FromJson(string mediaStreamJson)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | mediaStreamJson | The media stream's stats JSON. |
Returns
| Type | Description |
|---|---|
| MediaStreamStats |
FromJsonArray(String)
Derializes an array of media stream stats from JSON.
Declaration
public static MediaStreamStats[] FromJsonArray(string mediaStreamsJson)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | mediaStreamsJson | The media streams' stats JSON. |
Returns
| Type | Description |
|---|---|
| MediaStreamStats[] |
SerializeProperties(Dictionary<String, String>)
Serializes the properties.
Declaration
protected override void SerializeProperties(Dictionary<string, string> jsonObject)
Parameters
| Type | Name | Description |
|---|---|---|
| Dictionary<System.String, System.String> | jsonObject | The JSON object. |
Overrides
ToJson()
Serializes this to JSON.
Declaration
public string ToJson()
Returns
| Type | Description |
|---|---|
| System.String |
ToJson(MediaStreamStats)
Serializes media stream stats to JSON.
Declaration
public static string ToJson(MediaStreamStats mediaStream)
Parameters
| Type | Name | Description |
|---|---|---|
| MediaStreamStats | mediaStream | The media stream's stats. |
Returns
| Type | Description |
|---|---|
| System.String |
ToJsonArray(MediaStreamStats[])
Serializes an array of media stream stats to JSON.
Declaration
public static string ToJsonArray(MediaStreamStats[] mediaStreams)
Parameters
| Type | Name | Description |
|---|---|---|
| MediaStreamStats[] | mediaStreams | The media streams' stats. |
Returns
| Type | Description |
|---|---|
| System.String |