Blake Watters
e831e03ccb
Add workaround to avoid potential crash during execution of deletion operations on iOS 5. closes #1266
2013-03-13 22:28:24 -04:00
Blake Watters
e62a9862d7
Rework RKManagedObjectMappingOperationDataSource to avoid performing mutable(Array|Set|OrderedSet)ValueForKeyPath: unless there are existing objects and the identificationAttributes are nil. refs #1232
2013-03-10 14:22:38 -04:00
Blake Watters
47eed616ef
Fix crash due to execution of RKDeleteInvalidNewManagedObject from outside of the dispatch queue of the NSManagedObjectContext that owns the object. fixes #1251
2013-02-21 23:02:23 -05:00
Blake Watters
88246423bb
Fix invalid selector usage in managed object data source. fixes #1236
2013-02-14 22:55:12 -05:00
Blake Watters
4f442b142f
Fix issue where NSManagedObject instances that are invalid due to missing require relationship when finished mapping, but are made valid by connected relationships are deleted prematurely. fixes #1179
2013-01-29 11:44:15 -05:00
Blake Watters
5d7669bcc1
Fix creation of duplicated managed objects when you map a nil source key path onto an indentification attribute. fixes #1194
2013-01-29 10:03:19 -05:00
Blake Watters
039c7c443d
Fix issue where repeatedly mapping a to-many relationship without identification attributes would cause the first object in the relationship to be inappropriately reused
2013-01-26 12:10:55 -05:00
Blake Watters
d761de0ea7
Fix crash when attempting to map nil sourceKeyPath as identification attribute
2013-01-26 00:21:44 -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
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
879ffd73e6
Add support for deleting Core Data managed objects that fail validation out of the mapping context. This enables you to silently drop mapping for managed objects that fail validation. fixes #691 closes #694
2013-01-01 23:56:58 -05:00
Blake Watters
28887d3384
Add support for deletion of mapped objects by predicate. closes #1109
2013-01-01 15:27:01 -05:00
Blake Watters
9dc08ca27b
Drop instancetype from init methods since the compiler will infer it
2013-01-01 15:27:01 -05:00
Blake Watters
5c21e52829
Update Dynamic Mapping API's to match the rest of the 0.20.x style. Introduce support for predicate based dynamic matching.
...
* Rename RKDynamicMappingMatcher to RKObjectMappingMatcher since it is not strictly coupled to dynamic mapping and works with object mappings.
* Rework matchers into using a class cluster style to enable flexible subclassing to introduce additional matchers.
2012-12-27 22:16:40 -05:00
Blake Watters
92458a1e88
Enable support for mapping a relationship flexibly via assignment policies. You can now map a relationship and assign its value by setting, replacing, or unioning (combining) the relationship. closes #1073 , closes #989
2012-12-26 17:56:39 -05:00
Blake Watters
b78deb3eed
Use instancetype in constructors for increased subclassing friendliness
2012-12-22 14:54:49 -05:00
Blake Watters
862e84a515
Hook the RKManagedObjectMappingOperationDataSource into the Managed Object Context save lifecycle to avoid the creation of duplicate objects during sequential mapping operations
2012-12-18 22:00:44 -05:00
Blake Watters
f3cd0f6e07
Implemented connectionBlock property on RKRelationshipConnectionOperation for tracking connection status synchronously
2012-12-09 12:21:53 -05:00
Blake Watters
38480b269c
Rev docs referencing primaryKey as opposed to identificationAttributes
2012-12-08 11:41:48 -05:00
Blake Watters
79e31b524a
Refactored managed object caches and connection support to enable connecting by multiple atributes that are specified as arrays.
...
* Migrated the caches to return `NSSet` to eliminate duplicate objects when your cache keys overlap
* Introduced new recursive strategy for building cache keys in `RKInMemoryManagedObjectCache`
* Added support for array cache key values in `RKFetchRequestManagedObjectCache`
* Re-enabled a slew of tests that were disabled during 0.20 development
2012-12-06 23:43:34 -05:00
Blake Watters
cbb3f70571
Eliminate the RKEntityIdentifier class and migrate the functionality into properties on RKEntityMapping
2012-12-02 13:08:52 -05:00
Blake Watters
4eb765aad8
Switch to %ld and cast counts to long to suppress warnings on OS X
2012-11-29 00:21:56 -05:00
Blake Watters
1196a42e54
Docs for RKConnectionDescription
2012-11-27 22:18:29 -05:00
Blake Watters
8dc54a89b2
Major overhaul to the Core Data managed object identification and relationship connection support.
...
* Replaces primary key with `RKEntityIdentifier`
* Add support for use of compound keys for object identification
* Refactor `RKConnectionMapping` to `RKConnectionDescription` and add support for connecting with multiple attributes
* Clarify naming of representation key methods to better match naming conventions
* Add type transformation support for object identification
* Greatly expand test coverage for object identification
* Drop the `NSEntityDescription` category
* Simplify the `RKManagedObjectCaching` protocol
* Add compound key support to the Fetch Request and In Memory Cache implementations
* Replace Kiwi with Specta for tests where contexts are helpful for organization
* Rename `defaultValueForMissingAttribute` to `defaultValueForAttribute`
2012-11-27 10:29:36 -05:00
Blake Watters
e7505df56c
Fix retain cycles detected by Xcode 4.6 static analyzer
2012-11-05 18:38:23 -05:00
Blake Watters
45c6e1611e
Add delegate for didFailToConnectRelationship:
2012-11-05 18:38:23 -05:00
Blake Watters
117fcbb18c
Fix horrible bugs in previous commit
2012-10-21 15:58:03 -04:00
Blake Watters
f93a044561
Add error condition when attempting to map an RKEntityMapping containing connection mappings with a nil managed object cache.
...
* Add support for the data source to fail mapping operation with an error.
* Clean up error handling within RKMappingOperation
2012-10-21 15:47:16 -04:00
Christopher Swasey
3ca889fd28
Fix a bug in previous commit
2012-10-20 17:02:35 -04:00
Blake Watters
63c9a9e4a0
Fix bug in which relationship connection operations are not enqueued for RKMappingOperation instances whose mapping is an RKDynamicMapping
2012-10-20 16:53:14 -04:00
Blake Watters
845de91e80
Update RKMappingTest to support easier testing of RKEntityMapping objects by reducing the amount of required configuration to get a test configured.
2012-10-15 19:27:35 -04:00
Blake Watters
342c57213b
Updates to relationship connection execution system for better encapsulation and reuse.
...
* Reworked execution of relationship connection operations to use dependencies instead of queue suspension.
* Migrates responsibility for connecting relationships from `RKManagedObjectRequestOperation` into `RKManagedObjectResponseMapperOperation`. This ensures that you get a mapped and connected object graph back from the response mapper if you are using it outside of a request operation.
* Add `parentOperation` to managed object mapping data source to establish dependencies.
2012-10-15 16:06:22 -04:00
Blake Watters
4c401de6bf
Convert RKConnectionMapping into a subclass of RKPropertyMapping. Add delegate callback for tracking the connection of relationships.
2012-09-29 17:54:51 -04:00
Blake Watters
a04e861669
Add missing license boilerplate
2012-09-28 14:59:57 -04:00
Blake Watters
6815ba6444
API refresh for mapping layer. Converted RKObjectMapper to RKMapperOperation. Expanded documentation.
2012-09-21 17:55:32 -04:00
Blake Watters
991ced34da
Docs for mapping operation data source. Still don't love the method names. Maybe we can eliminate this somehow...
2012-09-20 08:12:29 -04:00
Jawwad Ahmad
8cbdb5f7ed
Trailing whitespace cleanup from files in the Code directory.
...
Used the following command from within the Code dir:
git ls-files *.m *.h *.json | xargs /usr/bin/sed -i '' -E 's/[[:space:]]*$//'
2012-09-02 12:51:45 -04:00
Jawwad Ahmad
c70ab49457
Delete @synthesize statements that are no longer needed. (Works with current 4.4.1 release of Xcode).
2012-09-02 12:28:45 -04:00
Blake Watters
ce6b0829e4
Convert RestKit to ARC
2012-08-28 17:34:58 -04:00
Blake Watters
5852d7c997
Eliminate unnecessary manual tracking of inserted objects in favor of MOC insertedObjects:
2012-08-22 18:54:23 -04:00
Blake Watters
9fa7a11fcf
Update connection mapping signatures on RKEntityMapping to be more idiomatic
2012-08-15 16:35:54 -04:00
Blake Watters
232b3eb861
Implemented new search engine for managed objects.
2012-08-01 18:12:53 -04:00
Blake Watters
6b315fbd54
Updates to entity cache and other components to operate in parent/child context world.
2012-07-20 14:48:09 -04:00
Blake Watters
046e277088
Make managedObjectCache optional on RKManagedObjectMappingOperationDataSource; Make RKManagedObjectMappingOperationDataSource.h public
2012-07-17 17:29:30 -04:00
Blake Watters
a8f64e7982
Continued cleanup related to managed object context work
2012-07-17 13:44:50 -04:00
Blake Watters
b25a1833b3
Ported RestKit to using managed object contexts with concurrency types. Numerous cleanups and API updates.
2012-07-16 22:47:06 -04:00
Blake Watters
cfa0df1841
Breakthrough on parent/child MOC setup
2012-07-13 14:11:48 -04:00
Blake Watters
f0706dbdbf
Work in progress
...
Conflicts:
Code/CoreData/RKManagedObjectLoader.h
Code/CoreData/RKManagedObjectLoader.m
Code/CoreData/RKManagedObjectMapping.m
Code/CoreData/RKManagedObjectMappingOperation.m
Code/CoreData/RKManagedObjectStore.m
Code/CoreData/RKManagedObjectThreadSafeInvocation.h
Code/CoreData/RKManagedObjectThreadSafeInvocation.m
Code/CoreData/RKSearchableManagedObject.m
Code/ObjectMapping/RKObjectLoader.m
Code/ObjectMapping/RKObjectMapper.h
Code/ObjectMapping/RKObjectMappingOperation.m
RestKit.xcodeproj/project.pbxproj
Tests/Logic/CoreData/RKManagedObjectThreadSafeInvocationTest.m
2012-07-13 13:07:42 -04:00