Module: Internet Protocols Module Package: HTTP
RWHttpDateHeader RWHttpHeaderBase
#include <rw/http/RWHttpDateHeader.h>
RWHttpDateHeader is a specialization class of RWHttpHeaderBase. It defines the HTTP DATE HEADER request. It is a helper class that formats its contents as Date: header_value, where header_value is information on date and time.
RWHttpDateHeader();
Constructs a default RWHttpDateHeader object with the associated value of the Date label as the current date and time.
RWHttpDateHeader(const RWCString& label, RWHttpHeaderType type = RW_HTTP_ENTITY_HEADER);
Constructs an RWHttpDateHeader object with the label of the header equal to label, and its associated value equal to the current date and time. The label is a specific type of the Date header, such as the If-Modified-Since header. The RWCString should contain 7-bit US-ASCII data.
RWHttpDateHeader(const RWHttpDate& d);
Constructs an RWHttpDateHeader object with the value equal to d.
RWHttpDateHeader(const RWCString& label, const RWHttpDate& d, RWHttpHeaderType type = RW_HTTP_ENTITY_HEADER);
Constructs an RWHttpDateHeader object with the label of the header equal to label, and its associated value equal to d. The label is the specific type of the Date header, such as the If-Modified-Since header. The RWCString should contain 7-bit US-ASCII data.
RWHttpDateHeader(const RWHttpGenericHeader& hdr);
Constructs an RWHttpDateHeader object from an RWHttpGenericHeader that represents a Date HTTP header. If the RWHttpGenericHeader does not represent a Date HTTP header or if the value of the RWHttpGenericHeader does not conform to the formatting of a Date value, an RWHttpHeaderParseError exception is thrown.
RWHttpDate getDate() const;
Returns the internal value of the header.
virtual RWCString getValue() const;
Returns the internal value that is associated with the label of the header in an RWCString format. The RWCString should contain 7-bit US-ASCII data. Throws RWInternalErr if internal data is not isValid.
void setDate(const RWHttpDate& d);
Assigns d to the internal value.
© Copyright Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave and SourcePro are registered trademarks of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.
Contact Rogue Wave about documentation or support issues.