ActiveResourceKit
v1.2 (498.0)
|
#import <ActiveResourceKit/ARResource.h>
Go to the source code of this file.
Classes | |
category | ARResource(Private) |
Functions | |
NSNumber * | ARIDFromResponse (ARHTTPResponse *response) |
Extracts the resource identifier from the given HTTP response. | |
BOOL | ARResponseCodeAllowsBody (NSInteger code) |
Determines whether the HTTP 1.1 specification allows a response to have a body (see section 4.4.1 of the specification). | |
NSNumber* ARIDFromResponse | ( | ARHTTPResponse * | response | ) |
Extracts the resource identifier from the given HTTP response.
The HTTP response includes a Location header field specifying the resource's full resource location. Rails places the resource ID at the last element in the location path. The implementation extracts this element using a regular expression.
nil
if the response does not contain a Location header, or if the Location field does not match the format "/foo/bar/1"
. Definition at line 30 of file ARResource+Private.m.
BOOL ARResponseCodeAllowsBody | ( | NSInteger | code | ) |
Determines whether the HTTP 1.1 specification allows a response to have a body (see section 4.4.1 of the specification).
Definition at line 48 of file ARResource+Private.m.