Module: Internet Protocols Module Package: HTTP
Does not inherit
#include <rw/http/RWHttpRange.h>
RWHttpRange represents an HTTP/1.1 format range for requesting portions of a document.
enum rangeEnd { head, tail };
Defines from which end of the document to start counting bytes. Used with the last constructor listed below and used with setRange().
RWHttpRange();
Constructs a default RWHttpRange object where the range is the complete document.
RWHttpRange(const RWCString& range);
Constructs an RWHttpRange object from an RWCString. The RWCString must be a properly formatted range according to RFC 2616. The RWCString should contain 7-bit US-ASCII data.
RWHttpRange(size t offset, size t length = 0);
Constructs an RWHttpRange object where the range starts at offset and continues for length bytes. A length of 0 means that the range continues to the end of the document.
RWHttpRange(size t length, rangeEnd end);
Constructs an RWHttpRange object where the range extends length bytes from end. If end is head, length runs forward from the beginning of the document. If end is tail, length runs backward from the end of the document.
RWCString getValue(void) const;
Returns the range as an RWCString. The RWCString should contain 7-bit US-ASCII data.
void setRange(const RWCString& range);
Sets the range to range. RWCString must be a properly formatted range according to RFC 2616. The RWCString should contain 7-bit US-ASCII data.
void setRange(size t offset, size t length);
Sets the range to start at offset and to continue for length bytes.
void setRange(size t length, rangeEnd end);
Sets the range to start at end and to extend for length bytes. If end is head, length runs forward from the beginning of the document. If end is tail, length runs backward from the end of the document.
© 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.