Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

PHTTP Class Reference

#include <http.h>

Inheritance diagram for PHTTP:

PInternetProtocol PIndirectChannel PChannel PObject PHTTPClient PHTTPServer List of all members.

Public Types

enum  Commands {
  GET, HEAD, POST, PUT,
  DELETE, TRACE, OPTIONS, CONNECT,
  NumCommands
}
enum  StatusCode {
  Continue = 100, SwitchingProtocols, RequestOK = 200, Created,
  Accepted, NonAuthoritativeInformation, NoContent, ResetContent,
  PartialContent, MultipleChoices = 300, MovedPermanently, MovedTemporarily,
  SeeOther, NotModified, UseProxy, BadRequest = 400,
  UnAuthorised, PaymentRequired, Forbidden, NotFound,
  MethodNotAllowed, NoneAcceptable, ProxyAuthenticationRequired, RequestTimeout,
  Conflict, Gone, LengthRequired, UnlessTrue,
  InternalServerError = 500, NotImplemented, BadGateway, ServiceUnavailable,
  GatewayTimeout
}

Static Public Attributes

const char *const AllowTag
const char *const AuthorizationTag
const char *const ContentEncodingTag
const char *const ContentLengthTag
const char *const ContentTypeTag
const char *const DateTag
const char *const ExpiresTag
const char *const FromTag
const char *const IfModifiedSinceTag
const char *const LastModifiedTag
const char *const LocationTag
const char *const PragmaTag
const char *const PragmaNoCacheTag
const char *const RefererTag
const char *const ServerTag
const char *const UserAgentTag
const char *const WWWAuthenticateTag
const char *const MIMEVersionTag
const char *const ConnectionTag
const char *const KeepAliveTag
const char *const TransferEncodingTag
const char *const ChunkedTag
const char *const ProxyConnectionTag
const char *const ProxyAuthorizationTag
const char *const ProxyAuthenticateTag
const char *const ForwardedTag
const char *const SetCookieTag
const char *const CookieTag

Protected Member Functions

 PHTTP ()
virtual PINDEX ParseResponse (const PString &line)

Detailed Description

A common base class for TCP/IP socket for the HyperText Transfer Protocol version 1.0 client and server.


Member Enumeration Documentation

enum PHTTP::Commands
 

Enumeration values:
GET 
HEAD 
POST 
PUT 
DELETE 
TRACE 
OPTIONS 
CONNECT 
NumCommands 

enum PHTTP::StatusCode
 

Enumeration values:
Continue 
SwitchingProtocols 
RequestOK 
Created 
Accepted 
NonAuthoritativeInformation 
NoContent 
ResetContent 
PartialContent 
MultipleChoices 
MovedPermanently 
MovedTemporarily 
SeeOther 
NotModified 
UseProxy 
BadRequest 
UnAuthorised 
PaymentRequired 
Forbidden 
NotFound  Open fail due to device or file not found.
MethodNotAllowed 
NoneAcceptable 
ProxyAuthenticationRequired 
RequestTimeout 
Conflict 
Gone 
LengthRequired 
UnlessTrue 
InternalServerError 
NotImplemented 
BadGateway 
ServiceUnavailable 
GatewayTimeout 


Constructor & Destructor Documentation

PHTTP::PHTTP  )  [protected]
 

Create a TCP/IP HTTP protocol channel.


Member Function Documentation

virtual PINDEX PHTTP::ParseResponse const PString line  )  [protected, virtual]
 

Parse a response line string into a response code and any extra info on the line. Results are placed into the member variables lastResponseCode and lastResponseInfo.

The default bahaviour looks for a space or a '-' and splits the code and info either side of that character, then returns FALSE.

Returns:
Position of continuation character in response, 0 if no continuation lines are possible.

Reimplemented from PInternetProtocol.


Member Data Documentation

const char* const PHTTP::AllowTag [static]
 

const char* const PHTTP::AuthorizationTag [static]
 

const char* const PHTTP::ChunkedTag [static]
 

const char* const PHTTP::ConnectionTag [static]
 

const char* const PHTTP::ContentEncodingTag [static]
 

const char* const PHTTP::ContentLengthTag [static]
 

const char* const PHTTP::ContentTypeTag [static]
 

const char* const PHTTP::CookieTag [static]
 

const char* const PHTTP::DateTag [static]
 

const char* const PHTTP::ExpiresTag [static]
 

const char* const PHTTP::ForwardedTag [static]
 

const char* const PHTTP::FromTag [static]
 

const char* const PHTTP::IfModifiedSinceTag [static]
 

const char* const PHTTP::KeepAliveTag [static]
 

const char* const PHTTP::LastModifiedTag [static]
 

const char* const PHTTP::LocationTag [static]
 

const char* const PHTTP::MIMEVersionTag [static]
 

const char* const PHTTP::PragmaNoCacheTag [static]
 

const char* const PHTTP::PragmaTag [static]
 

const char* const PHTTP::ProxyAuthenticateTag [static]
 

const char* const PHTTP::ProxyAuthorizationTag [static]
 

const char* const PHTTP::ProxyConnectionTag [static]
 

const char* const PHTTP::RefererTag [static]
 

const char* const PHTTP::ServerTag [static]
 

const char* const PHTTP::SetCookieTag [static]
 

const char* const PHTTP::TransferEncodingTag [static]
 

const char* const PHTTP::UserAgentTag [static]
 

const char* const PHTTP::WWWAuthenticateTag [static]
 


The documentation for this class was generated from the following file:
Generated on Sat Jul 24 15:35:58 2004 for PWLib by doxygen 1.3.7