Пример #1
0
        /// <summary>
        /// Runs this instance.
        /// </summary>
        public void Run()
        {
            var udpServer = new UdpServer(_logger, _networkManager, _appHost, _json);

            try
            {
                udpServer.Start(PortNumber);

                UdpServer = udpServer;
            }
            catch (SocketException ex)
            {
                _logger.ErrorException("Failed to start UDP Server", ex);
            }
        }
Пример #2
0
        /// <summary>
        /// Runs this instance.
        /// </summary>
        public void Run()
        {
            var udpServer = new UdpServer(_logger, _networkManager, _serverConfigurationManager, _httpServer);

            try
            {
                udpServer.Start(ApplicationHost.UdpServerPort);

                UdpServer = udpServer;
            }
            catch (SocketException ex)
            {
                _logger.ErrorException("Failed to start UDP Server", ex);
            }
        }