ObjFW  Diff

Differences From Artifact [47ebc74e15]:

To Artifact [116a255b13]:

  • File src/OFHTTPRequest.h — part of check-in [0a73af49f0] at 2017-04-30 13:35:16 on branch trunk — Use nonatomic for properties and clean up

    This changes retaining behavior, meaning properties are not returned
    retained and autoreleased anymore, so a property returned from a getter
    now needs to be manually retained and autoreleased before calling the
    setter. However, this is rarely the case and not using atomic improves
    performance. (user: js, size: 5384) [annotate] [blame] [check-ins using]


81
82
83
84
85
86
87
88

89
90
91
92
93
94
95
96
97
98

99
100
101
102
103
104

105
106
107
108
109
110

111
112
113
114
115

116
117
118
119
120
121
122
81
82
83
84
85
86
87

88
89
90
91
92
93
94
95
96
97

98
99
100
101
102
103

104
105
106
107
108
109

110
111
112
113
114

115
116
117
118
119
120
121
122







-
+









-
+





-
+





-
+




-
+







	OFDataArray *_body;
	OFString *_remoteAddress;
}

/*!
 * The URL of the HTTP request.
 */
@property (copy) OFURL *URL;
@property (nonatomic, copy) OFURL *URL;

/*!
 * The request method of the HTTP request.
 */
@property of_http_request_method_t method;

/*!
 * The headers for the HTTP request.
 */
@property OF_NULLABLE_PROPERTY (copy)
@property OF_NULLABLE_PROPERTY (nonatomic, copy)
    OFDictionary OF_GENERIC(OFString*, OFString*) *headers;

/*!
 * The cookies for the HTTP request.
 */
@property OF_NULLABLE_PROPERTY (copy)
@property OF_NULLABLE_PROPERTY (nonatomic, copy)
    OFArray OF_GENERIC(OFHTTPCookie*) *cookies;

/*!
 * The entity body of the HTTP request.
 */
@property OF_NULLABLE_PROPERTY (retain) OFDataArray *body;
@property OF_NULLABLE_PROPERTY (nonatomic, retain) OFDataArray *body;

/*!
 * The remote address from which the request originates.
 */
@property OF_NULLABLE_PROPERTY (copy) OFString *remoteAddress;
@property OF_NULLABLE_PROPERTY (nonatomic, copy) OFString *remoteAddress;

/*!
 * @brief Creates a new OFHTTPRequest.
 *
 * @return A new, autoreleased OFHTTPRequest
 */
+ (instancetype)request;