Beispiel #1
0
        public StunServer(int refreshInterval, SynchronizationContext ctx)
        {
            _synchronization = ctx;
            _refreshMs       = refreshInterval;
            var blackHole = new UndefinedResolver();

            userResolver = new UsersOnline();
            authresolver = new Authentification();

            var routes = authresolver.Compose(userResolver, blackHole);

            observer = new UDPObserver(_serverPort, ctx, routes);
            _client  = new UdpClient(AddressFamily.InterNetwork);
        }