CkHttpResponse Perl Programming Reference Documentation
CkHttpResponse
Represents a complete HTTP response.
Properties
# data is a CkByteData object (output) get_Body( data )
The response body returned as a byte array.
# str is a CkString object (output) get_BodyStr( str )
The response body returned as a string.
# str is a CkString object (output) get_Charset( str )
The response charset, such as "iso-8859-1", if applicable. Obviously, responses for GIF and JPG files will not have a charset.
# Returns an integer value get_ContentLength( )
The content length of the response, in bytes.
# sysTime is a SYSTEMTIME object (output) get_Date( sysTime )
The Date response header field, returned in an easy-to-use date/time data type.
# str is a CkString object (output) get_Domain( str )
The domain of the HTTP server that created this response.
# str is a CkString object (output) get_Header( str )
The full text of the response header.
# Returns an integer value get_NumCookies( )
The number of cookies included in the response.
# Returns an integer value get_NumHeaderFields( )
The number of response header fields.
# Returns an integer value get_StatusCode( )
The status code (as an integer) from the first line of an HTTP response. If the StatusLine = "HTTP/1.0 200 OK", the response status code returned is 200.
# str is a CkString object (output) get_StatusLine( str )
The first line of an HTTP response, such as "HTTP/1.0 200 OK".
# Returns a boolean value get_Utf8( )
# b is a boolean (input) put_Utf8( b )
When set to true, all "const char *" arguments are expected to be utf-8 strings. If set to false, the "const char *" arguments are expected to be ANSI strings.
Methods
# index is an integer (input) # str is a CkString object (output) # Returns a boolean value GetCookieDomain( index, str )
Returns the domain of the Nth cookie in the response. Indexing begins at 0. The number of response cookies is specified in the NumCookies property. Returns 1 for success, 0 for failure.
# index is an integer (input) # sysTime is a SYSTEMTIME object (output) # Returns a boolean value GetCookieExpires( index, sysTime )
Returns the expiration date/time of the Nth cookie in the response. Indexing begins at 0. The number of response cookies is specified in the NumCookies property.
# index is an integer (input) # str is a CkString object (output) # Returns a boolean value GetCookieExpiresStr( index, str )
Returns the expiration date/time of the Nth cookie in the response. Indexing begins at 0. The number of response cookies is specified in the NumCookies property. Returns 1 for success, 0 for failure.
# index is an integer (input) # str is a CkString object (output) # Returns a boolean value GetCookieName( index, str )
Returns the name of the Nth cookie returned in the response. Indexing begins at 0. The number of response cookies is specified in the NumCookies property. Returns 1 for success, 0 for failure.
# index is an integer (input) # str is a CkString object (output) # Returns a boolean value GetCookiePath( index, str )
Returns the path of the Nth cookie returned in the response. Indexing begins at 0. The number of response cookies is specified in the NumCookies property. Returns 1 for success, 0 for failure.
# index is an integer (input) # str is a CkString object (output) # Returns a boolean value GetCookieValue( index, str )
Returns the value of the Nth cookie returned in the response. Indexing begins at 0. The number of response cookies is specified in the NumCookies property. Returns 1 for success, 0 for failure.
# fieldName is a string (input) # str is a CkString object (output) # Returns a boolean value GetHeaderField( fieldName, str )
Returns the value of a response header field accessed by field name. Returns 1 for success, 0 for failure.
# fieldName is a string (input) # attrName is a string (input) # str is a CkString object (output) # Returns a boolean value GetHeaderFieldAttr( fieldName, attrName, str )
Returns a response header field attribute. As an example, the response charset is simply the GetHeaderFieldAttr("content-type","charset") Returns 1 for success, 0 for failure.
# index is an integer (input) # str is a CkString object (output) # Returns a boolean value GetHeaderName( index, str )
Gets the name of the Nth response header field. Indexing begins at 0. The number of response headers is specified by the NumHeaderFields property. Returns 1 for success, 0 for failure.
# index is an integer (input) # str is a CkString object (output) # Returns a boolean value GetHeaderValue( index, str )
Gets the value of the Nth response header field. Indexing begins at 0. The number of response headers is specified by the NumHeaderFields property. Returns 1 for success, 0 for failure.
# Returns a string bodyStr( )
The response body returned as a string.
# Returns a string charset( )
The response charset, such as "iso-8859-1", if applicable. Obviously, responses for GIF and JPG files will not have a charset.
# Returns a string domain( )
The domain of the HTTP server that created this response.
# index is an integer (input) # Returns a string getCookieDomain( index )
Returns the domain of the Nth cookie in the response. Indexing begins at 0. The number of response cookies is specified in the NumCookies property.
# index is an integer (input) # Returns a string getCookieExpiresStr( index )
Returns the expiration date/time of the Nth cookie in the response. Indexing begins at 0. The number of response cookies is specified in the NumCookies property.
# index is an integer (input) # Returns a string getCookieName( index )
Returns the name of the Nth cookie returned in the response. Indexing begins at 0. The number of response cookies is specified in the NumCookies property.
# index is an integer (input) # Returns a string getCookiePath( index )
Returns the path of the Nth cookie returned in the response. Indexing begins at 0. The number of response cookies is specified in the NumCookies property.
# index is an integer (input) # Returns a string getCookieValue( index )
Returns the value of the Nth cookie returned in the response. Indexing begins at 0. The number of response cookies is specified in the NumCookies property.
# fieldName is a string (input) # Returns a string getHeaderField( fieldName )
Returns the value of a response header field accessed by field name.
# fieldName is a string (input) # attrName is a string (input) # Returns a string getHeaderFieldAttr( fieldName, attrName )
Returns a response header field attribute. As an example, the response charset is simply the GetHeaderFieldAttr("content-type","charset")
# index is an integer (input) # Returns a string getHeaderName( index )
Gets the name of the Nth response header field. Indexing begins at 0. The number of response headers is specified by the NumHeaderFields property.
# index is an integer (input) # Returns a string getHeaderValue( index )
Gets the value of the Nth response header field. Indexing begins at 0. The number of response headers is specified by the NumHeaderFields property.
# Returns a string header( )
The full text of the response header.
# Returns a string statusLine( )
The first line of an HTTP response, such as "HTTP/1.0 200 OK".
|