private void manager_connectionEvent(ConnectionInformation connection) { uint ID = connection.GetConnectionID(); connection.OnConnectionClosed += connectionChanged; liveConnections.Add(ID, connection); connection.StartPacketProcessing(); }
public Session(ConnectionInformation pSock) { mSock = pSock; Authorizated = false; (pSock.Parser as HeartbeatParser).OnDataReceived += BytesReceived; Logging.WriteLine("Received connection"); SendData("authreq"); pSock.StartPacketProcessing(); }
public void StartConnection() { if (_connection == null) { return; } PingCount = 0; (_connection.Parser as InitialPacketParser).PolicyRequest += PolicyRequest; (_connection.Parser as InitialPacketParser).SwitchParserRequest += SwitchParserRequest; _connection.StartPacketProcessing(); }