private void Handler(object param) { var client = (Socket)param; lock (Clients) { Clients.Add(client); } var processor = new SimpleHttpProcessor(client, this); processor.Process(); try { client.Shutdown(SocketShutdown.Both); client.Disconnect(false); } catch (SocketException) { } catch (ObjectDisposedException) { } catch (PlatformNotSupportedException) { } lock (Clients) { Clients.Remove(client); } }
public virtual void HandlePostRequest(SimpleHttpProcessor processor, StreamReader inputData) { }
public virtual void HandleGetRequest(SimpleHttpProcessor processor) { }