Exemplo n.º 1
0
        public HttpServer(int port, HttpServerResponseAsync callback)
        {
            this.ServerResponseCallbackAsync = callback;

            this.listener = new StreamSocketListener();
            this.listener.ConnectionReceived += (s, e) => ProcessRequestAsync(e.Socket);
            this.listener.BindServiceNameAsync(port.ToString());
        }
Exemplo n.º 2
0
        public HttpServer(int port, HttpServerResponseAsync callback)
        {
            this.ServerResponseCallbackAsync = callback;

            this.listener = new StreamSocketListener();
            this.listener.ConnectionReceived += (s, e) => ProcessRequestAsync(e.Socket);
            this.listener.BindServiceNameAsync(port.ToString());
        }