Networking Tools: Thread-hot Internet Classes (int library)
#include <rw/toolpro/httpmeth.h>
thr, net, int, tls (and possibly std)
RWIHttpMethod is an abstract base class used to define HTTP request methods. These methods are defined by the HTTP specifications. For HTTP 1.0, the GET, POST, and HEAD commands are supported. For HTTP 0.9, only the GET command is supported. The RWIHttpMethod class accommodates adding header information to a request and provides methods that allow a full request to be constructed.
RWIHttpMethod(const RWCString& uri);
Constructs an RWIHttpMethod as part of a specific HTTP method.
void addHeader(const RWIHttpHeaderBase& hdr);
Appends hdr to an internal list of headers that are attached to the request.
void addHeader(const RWCString& label, const RWCString& value);
Formats the passed-in data as label: value and appends the result to an internal list of headers that are attached to the request.
virtual RWCString bodyString() const;
Returns an empty string. This method should be overridden by derived classes that have bodies.
virtual RWCString headerString() const;
Returns an RWCString constructed by concatenating together the pieces of header information, following each with a newline.
virtual RWCString name() const = 0;
Returns the request type (for example, "GET") of the actual derived class.
virtual RWCString requestString() const;
Returns RWCString(name() + " " + thisURI), where thisURI is the string that was passed to the constructor.
©Copyright 2000, Rogue Wave Software, Inc.
Contact Rogue Wave about documentation or support issues.