Inherits IDisposable.
Public Member Functions | |
Controller (IceConfig config) | |
void | Update () |
void | OnFailedToSelectCandidate (Transaction< Stun.Message > transaction) |
void | StartAsHost (Action< string, ushort > onReadyForMatchmaking=null, Action< CandidatePair > onCandidatePairSelected=null, Action< CandidatePair, CandidatePair > onConnectionReEstablished=null) |
void | StartAsClient (IPEndPoint relayEndPoint, Action< CandidatePair > onCandidatePairSelected, Action< CandidatePair, CandidatePair > onConnectionReEstablished) |
void | FinalizeSession (Session session) |
void | GatherLocalCandidates () |
void | GatherHostCandidates () |
void | GatherReflexiveAndRelayCandidates () |
void | OnUnRecoverableAllocationLoss (bool wasInitialConnection=false) |
void | OnAllocationFailed (Candidate candidate, Stun.Message message, List< Candidate > failedAllocationCandidates, ManualResetEvent finishedEvent) |
Candidate | OnAllocateSuccess (Candidate hostCandidate, Stun.Message response, ManualResetEvent finishedEvent=null) |
void | Dispose () |
Static Public Member Functions | |
static bool | IsGlobalIPv6 (IPAddress address) |
Public Attributes | |
IceConfig | iceConfig = new IceConfig() |
Guid | PeerGUID = Guid.NewGuid() |
List< Candidate > | localHostCandidates = new List<Candidate>() |
object | localCandidatesLock = new object() |
List< Candidate > | localCandidates = new List<Candidate>() |
Stun.Controller | sdpStunController |
Candidate | sipRelayCandidate |
object | candidateStunControllersLock = new object() |
readonly List< Stun.Controller > | candidateStunControllers = new List<Stun.Controller>() |
SessionList | sessions = new SessionList() |
IPEndPoint | relayServerEndPointV4 |
IPEndPoint | relayServerEndPointV6 |
Action< CandidatePair > | onCandidatePairSelected |
ActionQueue | actionQueue = new ActionQueue() |
int | controllerID |
IPEndPoint | sendOfferToThisAddressAfterGatheringLocalCandidates = null |
Action< CandidatePair, CandidatePair > | onConnectionReEstablished = null |
A method to call when an allocation is lost and replaced. More... | |
Static Public Attributes | |
static RNGCryptoServiceProvider | RNG = new RNGCryptoServiceProvider() |
Properties | |
IPEndPoint | relayEndPoint [get] |
The primary address of the primary relay More... | |
NobleConnect.Ice.Controller.Controller | ( | IceConfig | config | ) |
void NobleConnect.Ice.Controller.Dispose | ( | ) |
void NobleConnect.Ice.Controller.FinalizeSession | ( | Session | session | ) |
void NobleConnect.Ice.Controller.GatherHostCandidates | ( | ) |
void NobleConnect.Ice.Controller.GatherLocalCandidates | ( | ) |
void NobleConnect.Ice.Controller.GatherReflexiveAndRelayCandidates | ( | ) |
|
static |
Candidate NobleConnect.Ice.Controller.OnAllocateSuccess | ( | Candidate | hostCandidate, |
Stun.Message | response, | ||
ManualResetEvent | finishedEvent = null |
||
) |
void NobleConnect.Ice.Controller.OnAllocationFailed | ( | Candidate | candidate, |
Stun.Message | message, | ||
List< Candidate > | failedAllocationCandidates, | ||
ManualResetEvent | finishedEvent | ||
) |
void NobleConnect.Ice.Controller.OnFailedToSelectCandidate | ( | Transaction< Stun.Message > | transaction | ) |
void NobleConnect.Ice.Controller.OnUnRecoverableAllocationLoss | ( | bool | wasInitialConnection = false | ) |
void NobleConnect.Ice.Controller.StartAsClient | ( | IPEndPoint | relayEndPoint, |
Action< CandidatePair > | onCandidatePairSelected, | ||
Action< CandidatePair, CandidatePair > | onConnectionReEstablished | ||
) |
void NobleConnect.Ice.Controller.StartAsHost | ( | Action< string, ushort > | onReadyForMatchmaking = null , |
Action< CandidatePair > | onCandidatePairSelected = null , |
||
Action< CandidatePair, CandidatePair > | onConnectionReEstablished = null |
||
) |
void NobleConnect.Ice.Controller.Update | ( | ) |
ActionQueue NobleConnect.Ice.Controller.actionQueue = new ActionQueue() |
readonly List<Stun.Controller> NobleConnect.Ice.Controller.candidateStunControllers = new List<Stun.Controller>() |
object NobleConnect.Ice.Controller.candidateStunControllersLock = new object() |
int NobleConnect.Ice.Controller.controllerID |
object NobleConnect.Ice.Controller.localCandidatesLock = new object() |
Action<CandidatePair> NobleConnect.Ice.Controller.onCandidatePairSelected |
Action<CandidatePair, CandidatePair> NobleConnect.Ice.Controller.onConnectionReEstablished = null |
A method to call when an allocation is lost and replaced.
This is used by Peers to correct the application bridges when an allocation changes.
Guid NobleConnect.Ice.Controller.PeerGUID = Guid.NewGuid() |
IPEndPoint NobleConnect.Ice.Controller.relayServerEndPointV4 |
IPEndPoint NobleConnect.Ice.Controller.relayServerEndPointV6 |
|
static |
Stun.Controller NobleConnect.Ice.Controller.sdpStunController |
IPEndPoint NobleConnect.Ice.Controller.sendOfferToThisAddressAfterGatheringLocalCandidates = null |
SessionList NobleConnect.Ice.Controller.sessions = new SessionList() |
Candidate NobleConnect.Ice.Controller.sipRelayCandidate |
|
get |
The primary address of the primary relay
This is the address a peer is most likely to be able to receive on. The initial sip invite and response are sent over this end point. Ultimately this end point may or may not be used for the actual connection. If a better (non-relay) connection is found it will be used instead.