示例#1
0
        static void Main(string[] args)
        {
            var ip   = GlobalConfig.DefaultGateway;
            var port = GlobalConfig.Port;

            if (args.Length > 1)
            {
                ip = args[1];
                if (args.Length == 3)
                {
                    port = int.Parse(args[2]);
                }
            }

            var server = new Models.Server(ip, port);

            server.StartServerListener();
        }
示例#2
0
 /// <summary>
 /// Inicjalizuje nasluchiwacza serwera.
 /// </summary>
 private void InitServerListener()
 {
     _server = new Models.Server(this);
     _server.Listen();
 }