|
|
|
Location:
http\thttphdrval.h
Link against: http.lib
class THTTPHdrVal
Supported from 7.0
A representation of a value found in an HTTP header field.
Three fundamental types are used in HTTP: integers, strings (which may be free text, 'enumeration values', URIs, etc.), and date/times. The class allows any of the three values to be held and the current value, as well as its type, to be determined.
THTTPHdrVal instances are used to assign values to header fields, their parts and their associated parameters.
Defined in THTTPHdrVal:
Copy(), DateTime(), Int(), KDateVal, KNoType, KStrFVal, KStrVal, KTIntVal, SetDateTime(), SetInt(), SetStr(), SetStrF(), Str(), StrF(), THTTPHdrVal(), THTTPHdrVal(), THTTPHdrVal(), THTTPHdrVal(), THTTPHdrVal(), THTTPValType, TQConv, Type(), iMoreSpace, iType, iVal, operator !=(), operator ==(), operator RString(), operator RStringF(), operator TDateTime(), operator()
THTTPHdrVal();
Default constructor.
This is used when constructing an empty field value that is to be filled in by a later function.
THTTPHdrVal Copy() const;
Copies this field value.
It is critical to use this when the field contains a string, since a new string reference must be created.
|
THTTPValType Type() const;
Gets the type of this field value.
|
TInt Int() const;
Gets the field's integer value.
This panics if the field value is not an integer.
|
inline operator TInt() const;
Cast operator to obtain the field value as an integer.
Note this doesn't convert from a non-integer field to an integer.
This panics if the field value is not an integer.
RStringF StrF() const;
Gets the field's string value as an RStringF.
This panics if the field value is not a string.
|
RString Str() const;
Gets the field's string value as an RString.
This panics if the field value is not a string.
|
inline operator RStringF() const;
Cast operator to obtain the field value as a string (RStringF).
Note this doesn't convert from a non-string field to a string.
This panics if the field value is not a string.
inline operator RString() const;
Cast operator to obtain the field value as a string (RString).
Note this doesn't convert from a non-string field to a string.
This panics if the field value is not a string.
TDateTime DateTime() const;
Gets the field's date/time value.
This panics if the field value is not a date/time value.
|
inline operator TDateTime() const;
Cast operator to obtain the field value as a date/time value.
Note this doesn't convert from a non-date/time value field to a date/time value.
This panics if the field value is not a date/time value.
void SetInt(TInt aIntVal);
Sets the field value to the specified integer.
Any previous value, or its type, are lost.
|
void SetStrF(RStringF aStrVal);
Set the field value to be the specified string (RStringF).
Any previous value, or its type, are lost.
|
void SetStr(RString aStrVal);
Set the field value to be the specified string (RString).
Any previous value, or its type, are lost.
|
void SetDateTime(TDateTime aDateVal);
Set the field value to be the specified date/time value.
Any previous value, or its type, are lost.
|
TBool operator ==(THTTPHdrVal aVal) const;
Equality operator.
|
|
TBool operator !=(THTTPHdrVal aVal) const;
Inequality operator.
|
|
THTTPValType
Defines types of header field values.
|
class TQConv
Utility class that allows clients to convert 'q' values when placing them as parameters to header fields.
Defined in THTTPHdrVal::TQConv:
TQConv(), TQConv(), iFQ, iQ
TQConv()TQConv(TReal aQ);
Constructor specifying a real value.
|
TQConv()TQConv(TInt aQ);
Constructor specifying an integer value.
|
iQprivate: TReal iQ;
This is internal and not intended for use.
iFQprivate: TInt iFQ;
This is internal and not intended for use.
private: TInt iMoreSpace;
This is internal and not intended for use.