public void Setup()
        {
            var address = IPAddress.Any;
            int port    = 55555;

            _server = new RequestResponseTcpServer(address, port, null);
            _server.Start();
        }
예제 #2
0
        public void Setup()
        {
            var        address         = IPAddress.Any;
            int        port            = 55555;
            IScheduler scheduler       = Scheduler.Default;
            var        requestHandlers = new Dictionary <string, IRequestHandler>()
            {
                { "Ping!", new PingPongHandler() }
            };
            var requestDispatcher = new RequestDispatcher(scheduler, null, requestHandlers);

            _server = new RequestResponseTcpServer(address, port,
                                                   requestDispatcher);
            _server.Start();
        }