4 using System.Collections.Generic;
5 using System.Net.Sockets;
16 List<IHttpModule> httpModules =
new List<IHttpModule>();
24 #region Public Methods 40 httpModules.Add(httpModule);
44 #region Interface Implementation 59 bool IHandler.HandleReceivedMessage(
Client client,
Message message)
78 bool IHandler.HandleSendMessage(Client client, ref Message message)
87 bool IHandler.InitializeConnection(Client client)
97 bool IHandler.PreHandleReceivedMessage(Client client, ref Message message)
105 void IHandler.Tick(Client tcpClient)
bool HandleResponse(IHandler handler, HttpMessage response)
Handle a response received from the server.
HttpHandler AddModule(IHttpModule httpModule)
Add a http module.
byte [] BuildRequest()
Build the request bytes based on the message contents.
void SendRequest(Client client, HttpMessage request)
Send a request to the server.
Handler for handling client http communication.
void Disconnected(Client client)
Called when the client is disconnected.
void QueueMessage(byte[] message)
Add a message to the message queue.
Handler interface for client communication.
void ParseResponse(byte[] responseBytes)
Parse the received bytes and populate the message contents.
Base class for TCP Client.