Search Results for

    Show / Hide Table of Contents

    Class CandidateStats

    Candidate stats.

    Inheritance
    System.Object
    BaseStats
    CandidateStats
    Implements
    IEquivalent<CandidateStats>
    Inherited Members
    BaseStats.Id
    BaseStats.Timestamp
    Namespace: FM.LiveSwitch
    Assembly: FM.LiveSwitch.dll
    Syntax
    public class CandidateStats : BaseStats, IEquivalent<CandidateStats>

    Constructors

    CandidateStats()

    Initializes a new instance of the CandidateStats class.

    Declaration
    public CandidateStats()

    Properties

    IPAddress

    Gets the IP address.

    Declaration
    public string IPAddress { get; }
    Property Value
    Type Description
    System.String

    IsHost

    Gets whether the candidate is host/local.

    Declaration
    public bool IsHost { get; }
    Property Value
    Type Description
    System.Boolean

    IsReflexive

    Gets whether the candidate is reflexive.

    Declaration
    public bool IsReflexive { get; }
    Property Value
    Type Description
    System.Boolean

    IsRelayed

    Gets whether the candidate is relayed.

    Declaration
    public bool IsRelayed { get; }
    Property Value
    Type Description
    System.Boolean

    Port

    Gets the port.

    Declaration
    public int Port { get; }
    Property Value
    Type Description
    System.Int32

    Priority

    Gets the priority.

    Declaration
    public long Priority { get; }
    Property Value
    Type Description
    System.Int64

    Protocol

    Gets the protocol.

    Declaration
    public ProtocolType Protocol { get; }
    Property Value
    Type Description
    ProtocolType

    RelatedIPAddress

    Gets the related IP address.

    Declaration
    public string RelatedIPAddress { get; }
    Property Value
    Type Description
    System.String

    RelatedPort

    Gets the related port.

    Declaration
    public int RelatedPort { get; }
    Property Value
    Type Description
    System.Int32

    RelayProtocol

    Gets the relay protocol.

    Declaration
    public ProtocolType RelayProtocol { get; }
    Property Value
    Type Description
    ProtocolType

    TurnProtocol

    Gets the relay protocol.

    Declaration
    public ProtocolType TurnProtocol { get; }
    Property Value
    Type Description
    ProtocolType

    Type

    Gets the type.

    Declaration
    public CandidateType Type { get; }
    Property Value
    Type Description
    CandidateType

    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
    BaseStats.DeserializeProperties(String, String)

    FromJson(String)

    Derializes candidate stats from JSON.

    Declaration
    public static CandidateStats FromJson(string candidateJson)
    Parameters
    Type Name Description
    System.String candidateJson

    The candidate's stats JSON.

    Returns
    Type Description
    CandidateStats

    FromJsonArray(String)

    Derializes an array of candidate stats from JSON.

    Declaration
    public static CandidateStats[] FromJsonArray(string candidatesJson)
    Parameters
    Type Name Description
    System.String candidatesJson

    The candidates' stats JSON.

    Returns
    Type Description
    CandidateStats[]

    IsEquivalent(CandidateStats)

    Checks if a candidate is equivalent to this one.

    Declaration
    public bool IsEquivalent(CandidateStats instance)
    Parameters
    Type Name Description
    CandidateStats instance

    The candidate.

    Returns
    Type Description
    System.Boolean

    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
    BaseStats.SerializeProperties(Dictionary<String, String>)

    ToJson()

    Serializes this to JSON.

    Declaration
    public string ToJson()
    Returns
    Type Description
    System.String

    ToJson(CandidateStats)

    Serializes candidate stats to JSON.

    Declaration
    public static string ToJson(CandidateStats candidate)
    Parameters
    Type Name Description
    CandidateStats candidate

    The candidate's stats.

    Returns
    Type Description
    System.String

    ToJsonArray(CandidateStats[])

    Serializes an array of candidate stats to JSON.

    Declaration
    public static string ToJsonArray(CandidateStats[] candidates)
    Parameters
    Type Name Description
    CandidateStats[] candidates

    The candidates' stats.

    Returns
    Type Description
    System.String

    Implements

    IEquivalent<T>
    In This Article
    Back to top Copyright © LiveSwitch Inc. All Rights Reserved. Doc build for LiveSwitch v1.15.0