Public Member Functions | Static Public Member Functions | Properties

OFHTTPRequest Class Reference

A class for storing and performing HTTP requests. More...

#import <OFHTTPRequest.h>

Inheritance diagram for OFHTTPRequest:
OFObject <OFObject>

List of all members.

Public Member Functions

(id) - initWithURL:
(void) - setURL:
(OFURL *) - URL
(void) - setRequestType:
(of_http_request_type_t) - requestType
(void) - setQueryString:
(OFString *) - queryString
(void) - setHeaders:
(OFDictionary *) - headers
(void) - setRedirectsFromHTTPSToHTTPAllowed:
(BOOL) - redirectsFromHTTPSToHTTPAllowed
(OFHTTPRequestResult *) - perform
(OFHTTPRequestResult *) - performWithRedirects:

Static Public Member Functions

(id) + request
(id) + requestWithURL:

Properties

OFURLURL
of_http_request_type_t requestType
OFStringqueryString
OFDictionaryheaders
BOOL redirectsFromHTTPSToHTTPAllowed

Detailed Description

A class for storing and performing HTTP requests.


Member Function Documentation

- (OFDictionary*) headers  
Returns:
A dictionary with headers for the HTTP request.
- (id) initWithURL: (OFURL*)  url  

Initializes an already allocated OFHTTPRequest with the specified URL.

Parameters:
url The URL for the request
Returns:
An initialized OFHTTPRequest
- (OFHTTPRequestResult *) perform  

Performs the HTTP request and returns an OFHTTPRequestResult.

Returns:
An OFHTTPRequestResult with the result of the HTTP request
- (OFHTTPRequestResult *) performWithRedirects: (size_t)  redirects  

Performs the HTTP request and returns an OFHTTPRequestResult.

Parameters:
redirects The maximum number of redirects after which no further attempt is done to follow the redirect, but instead the redirect is returned as an OFHTTPRequest
Returns:
An OFHTTPRequestResult with the result of the HTTP request
- (OFString*) queryString  
Returns:
The query string for the HTTP request
- (BOOL) redirectsFromHTTPSToHTTPAllowed  
Returns:
Whether redirects from HTTPS to HTTP are allowed
+ (id) request  
Returns:
A new, autoreleased OFHTTPRequest
- (of_http_request_type_t) requestType  
Returns:
The request type for the HTTP request
+ (id) requestWithURL: (OFURL*)  url  
Parameters:
url The URL for the request
Returns:
A new, autoreleased OFHTTPRequest
- (void) setHeaders: (OFDictionary*)  headers  

Sets a dictionary with headers for the HTTP request.

Parameters:
headers A dictionary with headers for the HTTP request
- (void) setQueryString: (OFString*)  qs  

Sets the query string for the HTTP request.

Parameters:
qs The query string for the HTTP request
- (void) setRedirectsFromHTTPSToHTTPAllowed: (BOOL)  allowed  

Sets whether redirects from HTTPS to HTTP are allowed.

Parameters:
allowed Whether redirects from HTTPS to HTTP are allowed
- (void) setRequestType: (of_http_request_type_t)  type  

Sets the request type for the HTTP request.

Parameters:
type The request type for the HTTP request
- (void) setURL: (OFURL*)  url  

Sets the URL for the HTTP request.

Parameters:
URL The URL for the HTTP request
- (OFURL*) URL  
Returns:
The URL for the HTTP request

The documentation for this class was generated from the following files:
 All Classes Functions Variables