Exemplo n.º 1
0
        public AutoconnectManager(Network network, int connectionCount)
        {
            this.network = network;

            connectingToHandler       = NewConnection;
            incomingConnectionHandler = NewConnection;
            connectionReadyHandler    = OnConnectionReady;
            connectionClosedHandler   = OnConnectionClosed;

            // The number of connections to try to keep open
            this.connectionCount = connectionCount;
        }
Exemplo n.º 2
0
        public AutoconnectManager(Network network, int connectionCount)
        {
            this.network = network;

            connectingToHandler       = new NetworkLocalNodeConnectionEventHandler(NewConnection);
            incomingConnectionHandler = new NetworkLocalNodeConnectionEventHandler(NewConnection);
            connectionReadyHandler    = new LocalNodeConnectionEventHandler(OnConnectionReady);
            connectionClosedHandler   = new LocalNodeConnectionEventHandler(OnConnectionClosed);

            // The number of connections to try to keep open
            this.connectionCount = connectionCount;
        }