Commit Graph

1557 Commits

Author SHA1 Message Date
Blake Watters
2b84f667c1 Add support for obtaining a permanent managed object ID for the targetObject of an RKManagedObjectRequestOperation 2013-01-23 16:12:14 -05:00
Blake Watters
cd877860fd Tweak docs, add test cases for mapping a response with a descriptor that does not specify any attributes/relationships 2013-01-23 15:26:52 -05:00
Blake Watters
23ca0c7ca4 Fix potential crash due to serious Core Data error from failing to obtain a permanent objectID for an object that was just saved to the persistent store, but whose objectID is stale. fixes #1183 2013-01-23 13:20:55 -05:00
Blake Watters
120584e320 Add missing copy support for the entity and deletion predicate. closes #1184 2013-01-23 12:54:41 -05:00
Blake Watters
7ee9a9a866 Add missing EOF in ObjectMapping.h 2013-01-22 09:52:43 -05:00
Blake Watters
1885ee9e89 Add warning about deadlocks if you use waitUntilFinished with a RKManagedObjectRequestOperation on a main queue thread. refs #1173 2013-01-21 16:17:10 -05:00
Blake Watters
966e006990 Fix bug with refetching due to failure to track applied attribute mapping when mapped value is unchanged. closes #1176 2013-01-21 15:03:53 -05:00
Blake Watters
2351fc2472 Add unit test and fix for crash during eviction of cache keys during query for compound identification attributes. closes #1171 2013-01-21 13:18:42 -05:00
Blake Watters
abd207420b Fix missing language in log message 2013-01-21 12:55:39 -05:00
Blake Watters
2cf73d2436 Fix failed assertion when constructing an unprocessable response error for 5xx errors. closes #1169 2013-01-18 18:57:34 -05:00
Blake Watters
a75edcea2e Nil out targetObjectID if given a targetObject that is not an NSManagedObject. closes #1161 2013-01-18 17:28:49 -05:00
Blake Watters
3d971dc666 Encapsulate managed object refetching into an NSProxy object to enable you to defer the refetching until the mapping result is accessed (or skip it entirely if the result is not accessed) 2013-01-18 16:42:11 -05:00
Blake Watters
3d4c7b502d Copy attributeCaches to avoid potential for mutation during enumeration 2013-01-18 14:50:11 -05:00
Blake Watters
fc07e1fef7 Remove unnecessary exception handling for NSUndefinedKeyException 2013-01-18 14:48:22 -05:00
Blake Watters
06f2fe9c7b Radically simplify the implementation of managed object deletion and refetching within RKManagedObjectRequestOperation. closes #1163
1. Eliminates use of visitor in favor of aggregating mapping info during mapping. This avoids having to traverse the mapping graph.
1. Eliminate special case handling of cyclic key paths.
1. Eliminate issues with infinite recursion while traversing the mapping graph.
2013-01-18 12:20:51 -05:00
Blake Watters
ff7f538749 Add temporary workaround for infinite recursion 2013-01-17 23:31:28 -05:00
Blake Watters
f2abd1e107 Add test coverage verifying fix for crash during cyclic graph traversal in RKManagedObjectRequestOperation. closes #1142 2013-01-17 18:47:02 -05:00
Blake Watters
7bf14d4ea9 Rework implementation of cyclic mapping graph traversal. refs #1142 #1158 #1163 2013-01-17 15:08:30 -05:00
Blake Watters
a65a50e8f7 Fix bug with mapping nested attribute values with identification attributes when the identification attribute is not the nesting key. fixes #1129 2013-01-17 11:34:40 -05:00
Blake Watters
a2ca2ec937 Fix crash when serializing NSDate properties mapped at nested keypaths. fixes #1134 2013-01-17 11:01:24 -05:00
Blake Watters
01c34fe289 Fix crash when mapping to NSManagedObject class with Transformable attribute without a backing property. fixes #1162 2013-01-17 10:38:53 -05:00
James Moschou
02952aa2bb Add support for transforming strings 'Y' and 'N' to boolean NSNumber objects 2013-01-16 19:26:04 -05:00
Blake Watters
bcbbd65fbe Fix issue in which managed objects that are the children of non-managed objects were refetched and assigned as a collection rather than as a singular value. fixes #1118 2013-01-16 17:49:32 -05:00
Blake Watters
a8f3887b26 Fix bug with status code handling when statusCodes is nil for any response descriptor. 2013-01-16 13:57:24 -05:00
Blake Watters
c26739ce6b Fix issues with mapping errors from 5xx payloads. Ensure acceptableStatusCodes tracks the status codes configured in the response descriptors. fixes #1157 2013-01-16 12:38:44 -05:00
Blake Watters
868d83be2c Don't create unnecessary objects when mapping temporary managed objects POST'd without identification attributes. closes #1149 2013-01-15 22:45:43 -05:00
Blake Watters
bf521310b2 Replace visitor with simply obtaining permanent objectID's for temporary objects inserted into the context
The visitation implementation was problematic with large object graphs. This will obtain permanent objectID's for all temporary objects, but avoids having to visit each node in the graph.
2013-01-15 16:32:45 -05:00
Blake Watters
259e6c2fe5 Fix all test breakage in OS X Framework tests 2013-01-15 09:07:44 -05:00
Blake Watters
c98dd41c2f Reimplement predicate caching within the RKFetchRequestManagedObjectCache to avoid nasty crash due to malformed predicates. fixes #1141 2013-01-14 23:01:55 -05:00
Blake Watters
840b37a4f9 Fix bug in mapper delegate configuration and add missing test coverage for response mapper operation and both object request operation classes. closes #1156 2013-01-14 14:23:32 -05:00
Blake Watters
3e425707fb Fixed problems with initial implementation of temporary managed objects visitor. The implementation was under tested and only worked with a single relationship. refs #1001 2013-01-11 15:56:36 -05:00
Eric Chamberlain
51d36fb635 Fixed documentation omission
The managed object store provides two managed object contexts, not two managed objects.
2013-01-11 14:28:11 -05:00
Jeff Arena
e0481096cf Fix a few issues identified via static analysis 2013-01-11 11:57:55 -05:00
Blake Watters
91b12aee34 Add an exception if you try to create managed object contexts without adding a persistent store 2013-01-11 11:42:40 -05:00
Blake Watters
f1a35bb884 Style tweak 2013-01-10 19:54:18 -05:00
Blake Watters
281247f8c9 Merge branch 'master' of github.com:AntonPalich/RestKit into development 2013-01-09 22:45:23 -05:00
Blake Watters
f4b805ff52 Fix issues with implementation of error override in RKHTTPRequestOperation. fixes #1140 2013-01-09 22:42:39 -05:00
Blake Watters
139decbc36 Remove accidentally committed debug logging 2013-01-09 22:29:26 -05:00
Blake Watters
b61039c838 Use a visitor to identify all NSManagedObject instances being sent via the object manager which have a temporary managed object ID to avoid crashes during mapping. refs #1001 2013-01-09 21:11:38 -05:00
Blake Watters
bce692d08f Guard against crash due to Nil value retrieved for managedObjectClassName in the property inspector 2013-01-09 09:47:51 -05:00
Антон Щукин
3164c6d557 Fixed issue when body could be null on device
stringWithUTF8String accept NULL terminated C array of UTF8-encoded
bytes.
But NSData stores encoded data not like NULL terminated string.
2013-01-09 11:26:10 +04:00
Blake Watters
4612121ae5 Unify RKHTTPRequestOperation and RKObjectRequestOperation subclass customization via registration API's. closes #1131 2013-01-08 21:33:45 -05:00
Blake Watters
4c0e62a62a Add new RKManagedObjectStore method for assisting in performing migrations when you have made dynamic modifications to the managed object model (such as when you leverage the Search indexing support) 2013-01-08 18:26:05 -05:00
Blake Watters
70180022be Add support for customizing the RKObjectRequestOperation and RKManagedObjectRequestOperation instances built through the object manager using a registration API very similar to that of AFHTTPClient. closes #1131 2013-01-08 10:49:49 -05:00
Blake Watters
905048f737 Fix issue where unsaved managed object POST'd to the server with unsaved changes are not persisted if no mapping occurs. fixes #1130 2013-01-07 19:56:14 -05:00
Blake Watters
a21213e9c1 Add a more informative assertion when an RKManagedObjectResponseMapperOperation instance is not configured properly 2013-01-07 14:17:53 -05:00
Blake Watters
e9d5a87f7b Drop unnecessary performBlockAndWait: invocation that may be correlated with occasional crashes seen in GateGuru 2013-01-07 13:50:03 -05:00
Blake Watters
7f8320c514 Add helpful error message if you call requestMapping on an RKObjectMapping subclass 2013-01-06 01:11:09 -05:00
Blake Watters
0d74946808 Add another mention about the objectClass in RKRequestDescriptor 2013-01-06 00:46:43 -05:00
Blake Watters
226f3f7dc7 Fix static analyzer warning about uninitialized success variable in RKMappingTest 2013-01-06 00:46:14 -05:00