An HttpResponse is sent across an
HTTP connection in response to
receiving a request. For detailed descriptions
about the parts of a response, see the definition of HTTP
RFC 1945.
The create function can be used to create a HttpResponse
object eg.
(create HttpResponse)
Once created, this object is tailored using its properties and methods.
A HttpResponse module supports the following properties:
| property name | property type | description |
|---|---|---|
major |
Integer | the major version of the HTTP protocol |
minor |
Integer | the minor version of the HTTP protocol |
reason |
String | reason for a failure -- if this response response represents an error |
status |
Integer | status of this response (eg. an error code) |
headers |
List | attribute-value list of string pairs |
contentType |
String | the way the data sent with the request is encoded -- eg.
application/text
|
contentEncoding |
String | modifier on the contentType eg. x-gzip
|
data |
Binary | the data sent with the response |
The HttpResponse object supports the following method:
| method name | description |
|---|---|
headerString |
convert the headers into a string |
headerStringConvert the headers into a string.
Arguments: none
Return type: String
| Contents | Index | Current topic: communications | Related topics: communications classes, HTTP request |