Export (0) Print
Expand All

CHttpServerContext Class 

Provides the tools that a CHttpServer object needs to process data that a client has sent to the HTTP server.


class CHttpServerContext

CHttpServerContext does not have a base class.

When Microsoft Internet Information Services receives a request from a client browser, a CHttpServer object is created and initialized, and a CHttpServerContext object is created. As the server extension DLL processes requests, it uses CHttpServerContext member functions to perform tasks.

A CHttpServerContext object exists separately from a CHttpServer object in order to allow multithreading. Only one CHttpServer exists in a module, but a server might be required to process multiple client requests simultaneously.

CHttpServer creates a CHttpServerContext for each request to handle these multiple requests. A CHttpServer uses multiple CHttpServerContext objects to run in separate threads. This design allows simultaneous, multiple calls to the CHttpServer object by different client connections.

When an extension DLL (ISA) is called, the member function ServerSupportFunction provides the ISA with some general-purpose functions as well as functions that are specific to HTTP server implementation.

If the server extension must communicate something — for example, an error — back to the client immediately, call WriteClient. Otherwise, the server should output a message to the client to the m_pStream data member owned by the pCtxt parameter passed to it.

Header: afxisapi.h

This class is not supported in Smart Device projects.

Community Additions

ADD
Show:
© 2014 Microsoft