ObjFW  Diff

Differences From Artifact [f5735e078a]:

To Artifact [5980347de8]:


31
32
33
34
35
36
37
38

39
40
41
42
43
44
45
46

47
48
49
50
51
52
53
31
32
33
34
35
36
37

38
39
40
41
42
43
44
45

46
47
48
49
50
51
52
53







-
+







-
+







 * @brief A class for storing HTTP requests.
 */
@interface OFHTTPRequest: OFObject
{
	OFURL *URL;
	of_http_request_type_t requestType;
	OFDictionary *headers;
	OFDataArray *postData;
	OFDataArray *POSTData;
	OFString *MIMEType;
}

#ifdef OF_HAVE_PROPERTIES
@property (copy) OFURL *URL;
@property of_http_request_type_t requestType;
@property (copy) OFDictionary *headers;
@property (retain) OFDataArray *postData;
@property (retain) OFDataArray *POSTData;
@property (copy) OFString *MIMEType;
#endif

/*!
 * @brief Creates a new OFHTTPRequest.
 *
 * @return A new, autoreleased OFHTTPRequest
111
112
113
114
115
116
117
118

119
120

121
122
123
124
125
126
127

128
129
130
131
132
133
134
111
112
113
114
115
116
117

118
119

120
121
122
123
124
125
126

127
128
129
130
131
132
133
134







-
+

-
+






-
+







 * @return A dictionary with headers for the HTTP request.
 */
- (OFDictionary*)headers;

/*!
 * @brief Sets the POST data of the HTTP request.
 *
 * @param postData The POST data of the HTTP request
 * @param POSTData The POST data of the HTTP request
 */
- (void)setPostData: (OFDataArray*)postData;
- (void)setPOSTData: (OFDataArray*)postData;

/*!
 * @brief Returns the POST data of the HTTP request.
 *
 * @return The POST data of the HTTP request
 */
- (OFDataArray*)postData;
- (OFDataArray*)POSTData;

/*!
 * @brief Sets the MIME type for the POST data.
 *
 * @param MIMEType The MIME type for the POST data
 */
- (void)setMIMEType: (OFString*)MIMEType;