From ce8f6c7eb466279be1e58a50a0e980adedbcb8a0 Mon Sep 17 00:00:00 2001 From: Patrick Pierson Date: Fri, 6 Feb 2015 16:07:55 -0500 Subject: [PATCH 01/94] Fault updated objects before merging changes into mainQueueManagedObjectContext. This enables NSFetchedResultsController to update and re-sort its fetch results and to call its delegate methods in response Managed Object updates merged from another context. See: http://stackoverflow.com/a/3927811/489376 http://stackoverflow.com/a/16296365/489376 for issue details. --- Code/CoreData/RKManagedObjectStore.m | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/Code/CoreData/RKManagedObjectStore.m b/Code/CoreData/RKManagedObjectStore.m index 93e680155f..ef9f96ecaa 100644 --- a/Code/CoreData/RKManagedObjectStore.m +++ b/Code/CoreData/RKManagedObjectStore.m @@ -103,6 +103,31 @@ - (void)handleManagedObjectContextDidSaveNotification:(NSNotification *)notifica NSAssert([notification object] == self.observedContext, @"Received Managed Object Context Did Save Notification for Unexpected Context: %@", [notification object]); if (! [self.objectIDsFromChildDidSaveNotification isEqual:RKSetOfManagedObjectIDsFromManagedObjectContextDidSaveNotification(notification)]) { [self.mergeContext performBlock:^{ + + /* + Fault updated objects before merging changes into mainQueueManagedObjectContext. + + This enables NSFetchedResultsController to update and re-sort its fetch results and to call its delegate methods + in response Managed Object updates merged from another context. + See: + http://stackoverflow.com/a/3927811/489376 + http://stackoverflow.com/a/16296365/489376 + for issue details. + */ + for (NSManagedObject *object in [[notification userInfo] objectForKey:NSUpdatedObjectsKey]) { + NSManagedObjectID *objectID = [object objectID]; + if (objectID && ![objectID isTemporaryID]) { + NSError *error = nil; + NSManagedObject * updatedObject = [self.mergeContext existingObjectWithID:objectID error:&error]; + if (error) { + RKLogDebug(@"Failed to get existing object for objectID (%@). Failed with error: %@", objectID, error); + } + else { + [updatedObject willAccessValueForKey:nil]; + } + } + } + [self.mergeContext mergeChangesFromContextDidSaveNotification:notification]; }]; } else { From 8d0894848384c3c3a0e258fceacb14bfbdc39ee5 Mon Sep 17 00:00:00 2001 From: Simon Booth Date: Fri, 1 May 2015 14:38:25 +0100 Subject: [PATCH 02/94] Add identificationPredicateBlock to filter matches based on the JSON representation --- Code/CoreData/RKEntityMapping.h | 7 ++++ Code/CoreData/RKEntityMapping.m | 1 + ...KManagedObjectMappingOperationDataSource.m | 4 +++ Tests/Logic/CoreData/RKEntityMappingTest.m | 2 ++ ...agedObjectMappingOperationDataSourceTest.m | 36 +++++++++++++++++++ 5 files changed, 50 insertions(+) diff --git a/Code/CoreData/RKEntityMapping.h b/Code/CoreData/RKEntityMapping.h index 7170053fc1..65be05562d 100644 --- a/Code/CoreData/RKEntityMapping.h +++ b/Code/CoreData/RKEntityMapping.h @@ -114,6 +114,13 @@ */ @property (nonatomic, copy) NSPredicate *identificationPredicate; +/** + An optional block which returns a predicate used to filter identified objects during mapping. + + @return The identification predicate block. + */ +@property (nonatomic, copy) NSPredicate *(^identificationPredicateBlock)(NSDictionary *representation, NSManagedObjectContext *managedObjectContext); + /** An optional attribute of the receiver's entity that can be used to detect modification of a given instance. This is used to improve the performance of mapping operations by skipping the property mappings for a given object if it is found to be not modified. diff --git a/Code/CoreData/RKEntityMapping.m b/Code/CoreData/RKEntityMapping.m index 1e0ef0c091..247ee486ff 100644 --- a/Code/CoreData/RKEntityMapping.m +++ b/Code/CoreData/RKEntityMapping.m @@ -190,6 +190,7 @@ - (id)copyWithZone:(NSZone *)zone copy.entity = self.entity; copy.identificationAttributes = self.identificationAttributes; copy.identificationPredicate = self.identificationPredicate; + copy.identificationPredicateBlock = self.identificationPredicateBlock; copy.deletionPredicate = self.deletionPredicate; copy.modificationAttribute = self.modificationAttribute; copy.mutableConnections = [NSMutableArray array]; diff --git a/Code/CoreData/RKManagedObjectMappingOperationDataSource.m b/Code/CoreData/RKManagedObjectMappingOperationDataSource.m index fe18347226..cf1ca6d12c 100644 --- a/Code/CoreData/RKManagedObjectMappingOperationDataSource.m +++ b/Code/CoreData/RKManagedObjectMappingOperationDataSource.m @@ -277,6 +277,10 @@ - (id)mappingOperation:(RKMappingOperation *)mappingOperation targetObjectForRep attributeValues:entityIdentifierAttributes inManagedObjectContext:self.managedObjectContext]; if (entityMapping.identificationPredicate) objects = [objects filteredSetUsingPredicate:entityMapping.identificationPredicate]; + if (entityMapping.identificationPredicateBlock) { + NSPredicate *predicate = entityMapping.identificationPredicateBlock(representation, self.managedObjectContext); + if (predicate) objects = [objects filteredSetUsingPredicate:predicate]; + } if ([objects count] > 0) { managedObject = [objects anyObject]; if ([objects count] > 1) RKLogWarning(@"Managed object cache returned %ld objects for the identifier configured for the '%@' entity, expected 1.", (long) [objects count], [entity name]); diff --git a/Tests/Logic/CoreData/RKEntityMappingTest.m b/Tests/Logic/CoreData/RKEntityMappingTest.m index 6a515d92f2..03bca00a66 100644 --- a/Tests/Logic/CoreData/RKEntityMappingTest.m +++ b/Tests/Logic/CoreData/RKEntityMappingTest.m @@ -328,6 +328,7 @@ - (void)testEntityMappingCopy RKEntityMapping *entityMapping = [RKEntityMapping mappingForEntityForName:@"Human" inManagedObjectStore:managedObjectStore]; entityMapping.identificationAttributes = RKIdentificationAttributesInferredFromEntity(entityMapping.entity); entityMapping.identificationPredicate = [NSPredicate predicateWithValue:YES]; + entityMapping.identificationPredicateBlock = ^(NSDictionary *representation, NSManagedObjectContext *context) { return [NSPredicate predicateWithValue:YES]; }; entityMapping.deletionPredicate = [NSPredicate predicateWithValue:NO]; [entityMapping setModificationAttributeForName:@"railsID"]; [entityMapping addConnectionForRelationship:@"cats" connectedBy:@{ @"railsID": @"railsID", @"name": @"name" }]; @@ -337,6 +338,7 @@ - (void)testEntityMappingCopy expect(entityMappingCopy.entity).to.equal(entityMapping.entity); expect(entityMappingCopy.identificationAttributes).to.equal(entityMapping.identificationAttributes); expect(entityMappingCopy.identificationPredicate).to.equal(entityMapping.identificationPredicate); + expect(entityMappingCopy.identificationPredicateBlock).to.equal(entityMapping.identificationPredicateBlock); expect(entityMappingCopy.deletionPredicate).to.equal(entityMapping.deletionPredicate); expect(entityMappingCopy.modificationAttribute).to.equal(entityMapping.modificationAttribute); expect(entityMappingCopy.connections.count == entityMapping.connections.count); diff --git a/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m b/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m index c5e0bcdc39..8bda2db5dc 100644 --- a/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m +++ b/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m @@ -580,6 +580,42 @@ - (void)testEntityIdentifierWithPredicate expect(object).to.equal(human1); } +- (void)testEntityIdentifierWithPredicateBlock +{ + RKManagedObjectStore *managedObjectStore = [RKTestFactory managedObjectStore]; + managedObjectStore.managedObjectCache = [RKFetchRequestManagedObjectCache new]; + RKEntityMapping *mapping = [RKEntityMapping mappingForEntityForName:@"Human" inManagedObjectStore:managedObjectStore]; + mapping.identificationAttributes = @[ @"railsID" ]; + mapping.identificationPredicateBlock = ^(NSDictionary *representation, NSManagedObjectContext *context) { + return [NSPredicate predicateWithFormat:@"age + 94 < %@", representation[@"id"]]; + }; + [mapping addPropertyMapping:[RKAttributeMapping attributeMappingFromKeyPath:@"id" toKeyPath:@"railsID"]]; + + // Create two humans matching the identifier, but differ in matching the + RKHuman *human1 = [NSEntityDescription insertNewObjectForEntityForName:@"Human" inManagedObjectContext:managedObjectStore.persistentStoreManagedObjectContext]; + human1.name = @"Colin"; + human1.railsID = @123; + human1.age = @28; + + RKHuman *human2 = [NSEntityDescription insertNewObjectForEntityForName:@"Human" inManagedObjectContext:managedObjectStore.persistentStoreManagedObjectContext]; + human2.name = @"Blake"; + human2.railsID = @123; + human2.age = @30; + [managedObjectStore.persistentStoreManagedObjectContext save:nil]; + + NSError *error = nil; + NSFetchRequest *fetchRequest = [NSFetchRequest fetchRequestWithEntityName:@"Human"]; + NSUInteger count = [managedObjectStore.persistentStoreManagedObjectContext countForFetchRequest:fetchRequest error:&error]; + expect(count).to.beGreaterThan(0); + + RKManagedObjectMappingOperationDataSource *dataSource = [[RKManagedObjectMappingOperationDataSource alloc] initWithManagedObjectContext:managedObjectStore.persistentStoreManagedObjectContext + cache:managedObjectStore.managedObjectCache]; + NSDictionary *data = @{@"id": @123}; + id object = [dataSource mappingOperation:nil targetObjectForRepresentation:data withMapping:mapping inRelationship:nil]; + expect(object).notTo.beNil(); + expect(object).to.equal(human1); +} + - (void)testMappingInPrivateQueue { RKManagedObjectStore *managedObjectStore = [RKTestFactory managedObjectStore]; From 36be35de1d260e56daa113280598125d56a72547 Mon Sep 17 00:00:00 2001 From: razmara Date: Sat, 2 May 2015 20:47:09 -0700 Subject: [PATCH 03/94] Don't expect to receive the same object in the receiver --- Code/Network/RKObjectManager.m | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Code/Network/RKObjectManager.m b/Code/Network/RKObjectManager.m index 800f84e4a8..ea8640b0f7 100644 --- a/Code/Network/RKObjectManager.m +++ b/Code/Network/RKObjectManager.m @@ -668,8 +668,9 @@ - (id)appropriateObjectRequestOperationWithObject:(id)object // Non-Core Data operation operation = [self objectRequestOperationWithRequest:request success:nil failure:nil]; #endif - - if (RKDoesArrayOfResponseDescriptorsContainMappingForClass(self.responseDescriptors, [object class])) operation.targetObject = object; + // Don't expect to receive the same object in the receiver + /*if (RKDoesArrayOfResponseDescriptorsContainMappingForClass(self.responseDescriptors, [object class])) operation.targetObject = object; + */ operation.mappingMetadata = routingMetadata; return operation; } From 4c0e70add8535117d0fa30a593235eea6dd12cb3 Mon Sep 17 00:00:00 2001 From: razmara Date: Sat, 2 May 2015 20:55:10 -0700 Subject: [PATCH 04/94] updated podspec --- RestKit.podspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/RestKit.podspec b/RestKit.podspec index a39e508c58..3e1c6db25b 100644 --- a/RestKit.podspec +++ b/RestKit.podspec @@ -5,7 +5,7 @@ Pod::Spec.new do |s| s.homepage = 'http://www.restkit.org' s.social_media_url = 'https://twitter.com/RestKit' s.author = { 'Blake Watters' => 'blakewatters@gmail.com' } - s.source = { :git => 'https://github.com/RestKit/RestKit.git', :tag => "v#{s.version}" } + s.source = { :git => 'https://github.com/razmara/RestKit.git', :tag => "v#{s.version}" } s.license = 'Apache License, Version 2.0' # Platform setup From 8a1b812aec347aeac4652af844861f59a7bb1f9f Mon Sep 17 00:00:00 2001 From: Charlie Savage Date: Thu, 14 May 2015 21:28:22 -0600 Subject: [PATCH 05/94] Fix concurrency issues triggered by setting debug flag -com.apple.CoreData.ConcurrencyDebug 1. --- .../RKRelationshipConnectionOperation.m | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/Code/CoreData/RKRelationshipConnectionOperation.m b/Code/CoreData/RKRelationshipConnectionOperation.m index 8848924c43..ecd3869608 100644 --- a/Code/CoreData/RKRelationshipConnectionOperation.m +++ b/Code/CoreData/RKRelationshipConnectionOperation.m @@ -148,7 +148,14 @@ - (id)findConnectedValueForConnection:(RKConnectionDescription *)connection shou { *shouldConnectRelationship = YES; id connectionResult = nil; - if (connection.sourcePredicate && ![connection.sourcePredicate evaluateWithObject:self.managedObject]) return nil; + if (connection.sourcePredicate) { + __block BOOL evaluationResult; + [self.managedObject.managedObjectContext performBlockAndWait:^{ + evaluationResult = [connection.sourcePredicate evaluateWithObject:self.managedObject]; + }]; + + if (!evaluationResult) return nil; + } if ([connection isForeignKeyConnection]) { NSDictionary *attributeValues = RKConnectionAttributeValuesWithObject(connection, self.managedObject); @@ -157,11 +164,15 @@ - (id)findConnectedValueForConnection:(RKConnectionDescription *)connection shou *shouldConnectRelationship = NO; return nil; } - NSSet *managedObjects = [self.managedObjectCache managedObjectsWithEntity:[connection.relationship destinationEntity] + __block NSSet *managedObjects = [self.managedObjectCache managedObjectsWithEntity:[connection.relationship destinationEntity] attributeValues:attributeValues inManagedObjectContext:self.managedObjectContext]; - if (connection.destinationPredicate) managedObjects = [managedObjects filteredSetUsingPredicate:connection.destinationPredicate]; - if (!connection.includesSubentities) managedObjects = [managedObjects filteredSetUsingPredicate:[NSPredicate predicateWithFormat:@"entity == %@", [connection.relationship destinationEntity]]]; + + [self.managedObjectContext performBlockAndWait:^{ + if (connection.destinationPredicate) managedObjects = [managedObjects filteredSetUsingPredicate:connection.destinationPredicate]; + if (!connection.includesSubentities) managedObjects = [managedObjects filteredSetUsingPredicate:[NSPredicate predicateWithFormat:@"entity == %@", [connection.relationship destinationEntity]]]; + }]; + if ([connection.relationship isToMany]) { connectionResult = managedObjects; } else { From 4d3c8e12c838580b5ea1d12e2ab6e4e921122abd Mon Sep 17 00:00:00 2001 From: Charlie Savage Date: Fri, 15 May 2015 14:17:24 -0600 Subject: [PATCH 06/94] Fix alignment in method call. --- Code/CoreData/RKRelationshipConnectionOperation.m | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Code/CoreData/RKRelationshipConnectionOperation.m b/Code/CoreData/RKRelationshipConnectionOperation.m index ecd3869608..5cba533edd 100644 --- a/Code/CoreData/RKRelationshipConnectionOperation.m +++ b/Code/CoreData/RKRelationshipConnectionOperation.m @@ -165,8 +165,8 @@ - (id)findConnectedValueForConnection:(RKConnectionDescription *)connection shou return nil; } __block NSSet *managedObjects = [self.managedObjectCache managedObjectsWithEntity:[connection.relationship destinationEntity] - attributeValues:attributeValues - inManagedObjectContext:self.managedObjectContext]; + attributeValues:attributeValues + inManagedObjectContext:self.managedObjectContext]; [self.managedObjectContext performBlockAndWait:^{ if (connection.destinationPredicate) managedObjects = [managedObjects filteredSetUsingPredicate:connection.destinationPredicate]; From 0170270fddfb0eafd596bc88825f71b4a184bf91 Mon Sep 17 00:00:00 2001 From: "Samuel E. Giddins" Date: Tue, 19 May 2015 16:04:07 -0500 Subject: [PATCH 07/94] [Bundle] Update CocoaPods --- Gemfile | 2 +- Gemfile.lock | 27 ++++++++++++++------------- 2 files changed, 15 insertions(+), 14 deletions(-) diff --git a/Gemfile b/Gemfile index a2cb1129af..4ca77d3bbf 100644 --- a/Gemfile +++ b/Gemfile @@ -4,6 +4,6 @@ gem 'rakeup', '~> 1.2.0' gem 'sinatra', '~> 1.4.0' gem 'sinatra-contrib', '~> 1.4.0' gem 'thin', '~> 1.5.0' -gem 'cocoapods', '~> 0.36.0' +gem 'cocoapods', '~> 0.37.0' gem 'xctasks', '~> 0.5.0' gem 'xcpretty', '~> 0.1.6' diff --git a/Gemfile.lock b/Gemfile.lock index a0e4dbad65..16a5621328 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -9,21 +9,20 @@ GEM tzinfo (~> 1.1) backports (3.6.4) claide (0.8.1) - cocoapods (0.36.4) + cocoapods (0.37.1) activesupport (>= 3.2.15) claide (~> 0.8.1) - cocoapods-core (= 0.36.4) + cocoapods-core (= 0.37.1) cocoapods-downloader (~> 0.9.0) - cocoapods-plugins (~> 0.4.1) + cocoapods-plugins (~> 0.4.2) cocoapods-trunk (~> 0.6.0) - cocoapods-try (~> 0.4.3) + cocoapods-try (~> 0.4.4) colored (~> 1.2) escape (~> 0.0.4) - molinillo (~> 0.2.1) + molinillo (~> 0.2.3) nap (~> 0.8) - open4 (~> 1.3) - xcodeproj (~> 0.23.1) - cocoapods-core (0.36.4) + xcodeproj (~> 0.24.1) + cocoapods-core (0.37.1) activesupport (>= 3.2.15) fuzzy_match (~> 2.0.4) nap (~> 0.8.0) @@ -33,7 +32,7 @@ GEM cocoapods-trunk (0.6.0) nap (>= 0.8) netrc (= 0.7.8) - cocoapods-try (0.4.3) + cocoapods-try (0.4.4) colored (1.2) daemons (1.2.2) escape (0.0.4) @@ -42,14 +41,13 @@ GEM i18n (0.7.0) json (1.8.2) mini_portile (0.6.2) - minitest (5.6.0) + minitest (5.6.1) molinillo (0.2.3) multi_json (1.11.0) nap (0.8.0) netrc (0.7.8) nokogiri (1.6.6.2) mini_portile (~> 0.6.0) - open4 (1.3.4) rack (1.5.2) rack-protection (1.5.3) rack @@ -78,7 +76,7 @@ GEM tilt (1.4.1) tzinfo (1.2.2) thread_safe (~> 0.1) - xcodeproj (0.23.1) + xcodeproj (0.24.1) activesupport (>= 3) colored (~> 1.2) xcpretty (0.1.9) @@ -90,10 +88,13 @@ PLATFORMS ruby DEPENDENCIES - cocoapods (~> 0.36.0) + cocoapods (~> 0.37.0) rakeup (~> 1.2.0) sinatra (~> 1.4.0) sinatra-contrib (~> 1.4.0) thin (~> 1.5.0) xcpretty (~> 0.1.6) xctasks (~> 0.5.0) + +BUNDLED WITH + 1.10.0.pre.2 From 562a8d89c022fd325e9a9bc364f83f793ac570bf Mon Sep 17 00:00:00 2001 From: Michael Ozeryansky Date: Wed, 10 Jun 2015 02:08:22 -0700 Subject: [PATCH 08/94] Updated broken URLs for those which have a working alternative --- CONTRIBUTING.md | 2 +- .../Advanced_RestKit_Tutorial.md | 4 ++-- Docs/MobileTuts Introduction to RestKit/index.html | 2 +- Docs/WRITING_DOCS.md | 6 +++--- README.md | 12 ++++++------ Tests/README.md | 10 ++++++---- Vendor/LibComponentLogging/Core/README.md | 10 +++++----- 7 files changed, 24 insertions(+), 22 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 763ff0b51e..5565d68e7c 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,6 +1,6 @@ ## Issues -GitHub Issues is for reporting bugs in RestKit and discussing changes to RestKit itself. Please check the [documentation](http://cocoadocs.org/docsets/RestKit/), [wiki](https://github.com/RestKit/RestKit/wiki), and [existing issues](https://github.com/RestKit/RestKit/issues?state=closed) before opening a new issue. +GitHub Issues is for reporting bugs in RestKit and discussing changes to RestKit itself. Please check the [documentation](http://cocoadocs.org/docsets/RestKit/), [wiki](https://github.com/RestKit/RestKit/wiki), and [existing issues](https://github.com/RestKit/RestKit/issues?q=is:issue) before opening a new issue. Additionaly, please do not post general usage questions to Issues, but instead take them to [Stack Overflow](http://stackoverflow.com/questions/tagged/restkit). diff --git a/Docs/MobileTuts Advanced RestKit/Advanced_RestKit_Tutorial.md b/Docs/MobileTuts Advanced RestKit/Advanced_RestKit_Tutorial.md index f3f3e853c8..3790c6fe2b 100644 --- a/Docs/MobileTuts Advanced RestKit/Advanced_RestKit_Tutorial.md +++ b/Docs/MobileTuts Advanced RestKit/Advanced_RestKit_Tutorial.md @@ -717,7 +717,7 @@ We hope that you have found learning about RestKit fun and rewarding. At this po ## Learning More * RestKit: [http://restkit.org]() -* Github: [https://github.com/twotoasters/RestKit]() -* API Docs: [http://restkit.org/api/]() +* Github: [https://github.com/RestKit/RestKit]() +* API Docs: [http://cocoadocs.org/docsets/RestKit/]() * Google Group: [http://groups.google.com/group/restkit]() * Brought to you by Two Toasters: [http://twotoasters.com/]() diff --git a/Docs/MobileTuts Introduction to RestKit/index.html b/Docs/MobileTuts Introduction to RestKit/index.html index d8d1429ebe..a63765795b 100644 --- a/Docs/MobileTuts Introduction to RestKit/index.html +++ b/Docs/MobileTuts Introduction to RestKit/index.html @@ -381,7 +381,7 @@

Learning More

\ No newline at end of file diff --git a/Docs/WRITING_DOCS.md b/Docs/WRITING_DOCS.md index 2314f7799d..10c4721f06 100644 --- a/Docs/WRITING_DOCS.md +++ b/Docs/WRITING_DOCS.md @@ -1,7 +1,7 @@ Writing Documentation ===================== -RestKit utilizes the excellent [Appledoc](http://www.gentlebytes.com/home/appledocapp/) utility from [Gentle Bytes](http://www.gentlebytes.com/). +RestKit utilizes the excellent [Appledoc](http://www.gentlebytes.com/appledoc/) utility from [Gentle Bytes](http://www.gentlebytes.com/). Appledoc provides a commandline utility for parsing and generating documentation from Objective-C code in HTML and DocSet format. This HTML can be published to the Web and installed directly within Xcode. @@ -21,7 +21,7 @@ The tasks available for working with Appledoc are: ## Writing Documentation -Writing documentation in Appledoc markup is simple. There is extensive documentation available on the [Appledoc project page](http://tomaz.github.com/appledoc/comments.html), but +Writing documentation in Appledoc markup is simple. There is extensive documentation available on the [Appledoc project page](https://github.com/tomaz/appledoc), but the guidelines below should be sufficient for basic authoring tasks. For clarity, let's consider the following example class: /** @@ -107,6 +107,6 @@ If you want to contribute documentation, the process is simple: 1. Edit the headers in Code/ and regenerate the docs via `rake docs` 1. Repeat the editing and reload cycle until your are happy. 1. Commit the code and push to Github -1. Submit a Pull Request to the RestKit repository on Github at: https://github.com/RestKit/RestKit/pull/new/master +1. Submit a Pull Request to the RestKit repository on Github at: https://github.com/RestKit/RestKit/compare You may want to coordinate your efforts via the mailing list to ensure nobody else is working on documentation in the same place. diff --git a/README.md b/README.md index 8037e42866..a963eac306 100644 --- a/README.md +++ b/README.md @@ -38,7 +38,7 @@ RKObjectRequestOperation *operation = [[RKObjectRequestOperation alloc] initWith - First time with RestKit? Read the ["Overview"](#overview) section below and then check out the ["Getting Acquainted with RestKit"](https://github.com/RestKit/RKGist/blob/master/TUTORIAL.md) tutorial and [Object Mapping Reference](https://github.com/RestKit/RestKit/wiki/Object-mapping) documents in the wiki to jump right in. - Upgrading from RestKit 0.9.x or 0.10.x? Read the ["Upgrading to RestKit 0.20.x"](https://github.com/RestKit/RestKit/wiki/Upgrading-from-v0.10.x-to-v0.20.0) guide in the wiki - Adding RestKit to an existing [AFNetworking](https://github.com/AFNetworking/AFNetworking) application? Read the [AFNetworking Integration](https://github.com/RestKit/RestKit/wiki/AFNetworking-Integration) document to learn details about how the frameworks fit together. -- Review the [source code API documentation](http://restkit.org/api/latest) for a detailed look at the classes and API's in RestKit. A great place to start is [RKObjectManager](http://restkit.org/api/latest/Classes/RKObjectManager.html). +- Review the [source code API documentation](http://cocoadocs.org/docsets/RestKit/) for a detailed look at the classes and API's in RestKit. A great place to start is [RKObjectManager](http://restkit.org/api/latest/Classes/RKObjectManager.html). - Still need some help? Ask questions on [Stack Overflow](http://stackoverflow.com/questions/tagged/restkit) or the [mailing list](http://groups.google.com/group/restkit), ping us on [Twitter](http://twitter.com/RestKit) or chat with us on [IRC](https://kiwiirc.com/client/irc.freenode.net/?nick=rkuser|?&theme=basic#RestKit). ## Overview @@ -60,7 +60,7 @@ Object mapping is a deep topic and is explored in exhaustive detail in the [Obje RestKit is broken into several modules that cleanly separate the mapping engine from the HTTP and Core Data integrations to provide maximum flexibility. Key classes in each module are highlighted below and each module is hyperlinked to the README.md contained within the source code. - + @@ -534,7 +534,7 @@ Several third-party open source libraries are used within RestKit, including: 1. [AFNetworking](https://github.com/AFNetworking/AFNetworking) - Networking Support 2. [LibComponentLogging](http://0xc0.de/LibComponentLogging) - Logging Support -3. [SOCKit](https://github.com/jverkoey/sockit) - String <-> Object Coding +3. [SOCKit](https://github.com/NimbusKit/sockit) - String <-> Object Coding 4. [iso8601parser](http://boredzo.org/iso8601parser/) - Support for parsing and generating ISO-8601 dates The following Cocoa frameworks must be linked into the application target for proper compilation: @@ -590,11 +590,11 @@ $ touch Podfile $ edit Podfile platform :ios, '5.0' # Or platform :osx, '10.7' -pod 'RestKit', '~> 0.20.0' +pod 'RestKit', '~> 0.24.0' # Testing and Search are optional components -pod 'RestKit/Testing', '~> 0.20.0' -pod 'RestKit/Search', '~> 0.20.0' +pod 'RestKit/Testing', '~> 0.24.0' +pod 'RestKit/Search', '~> 0.24.0' ``` Install into your project: diff --git a/Tests/README.md b/Tests/README.md index e7719e024b..76f23d94ab 100644 --- a/Tests/README.md +++ b/Tests/README.md @@ -6,7 +6,7 @@ RestKit ships with a testing infrastructure built around OCUnit and a Ruby testi 1. Install the Xcode **Command Line Tools** by selecting the **Xcode** > **Preferences…** menu and then navigating to the **Downloads** tab, then clicking the **Install** button next to the appropriate entry in the table. 1. After installation completes, ensure your command line Xcode installation is configured by executing `xcode-select -print-path`. If no path is returned, configure xcode-select by executing `xcode-select -switch /Applications/Xcode.app/Contents/Developer`. 1. Check out the Git submodules: `git submodule update --init --recursive` -1. Ensure that you have **Ruby 2.0.0** available. We recommend installation via [rbenv](https://github.com/sstephenson/rbenv), [RVM](http://beginrescueend.com/rvm/install/) or [Homebrew](http://mxcl.github.com/homebrew/). +1. Ensure that you have **Ruby 2.0.0** available. We recommend installation via [rbenv](https://github.com/sstephenson/rbenv), [RVM](https://rvm.io/) or [Homebrew](http://brew.sh/). 1. Install the Ruby Bundler Gem (if necessary): `gem install bundler` 1. Install the other required Gems via Bundler: `bundle` 1. Install the required CocoaPods: `pod install` @@ -66,13 +66,13 @@ configured and there are integration tests that test the full request/response l 1. Tests are implemented in Objective-C and run inside the Simulator or on the Device. 1. Test files live in sub-directories under Tests/ appropriate to the layer the code under test belongs to 1. Tests begin with "test" and should be camel-cased descriptive. i.e. testShouldConsiderA200ResponseSuccessful -1. Expectations are provided using [Expecta](https://github.com/petejkim/expecta) and [OCHamcrest](http://jonreid.github.com/OCHamcrest/). Expectations are generally of th form: +1. Expectations are provided using [Expecta](https://github.com/specta/expecta) and [OCHamcrest](https://github.com/hamcrest/OCHamcrest). Expectations are generally of th form: expect(someObject).to.equal(@"some value"); // Expecta assertThat([someObject someMethod], is(equalTo(@"some value"))); // OCHamcrest There is a corresponding `notTo` and `isNot` method available as well. 1. The RKTestEnvironment.h header includes a number of helpers for initializing and configuring a clean testing environment. -1. OCMock is available for mock objects support. See [http://www.mulle-kybernetik.com/software/OCMock/](http://www.mulle-kybernetik.com/software/OCMock/) for details. +1. OCMock is available for mock objects support. See [http://ocmock.org/](http://ocmock.org/) for details. 1. RestKit is available for 32bit (iOS) and 64bit (OS X) platforms. This introduces some complexity when working with integer data types as NSInteger and NSUInteger are int's on 32bit and long's on 64bit. Cocoa and OC Hamcrest provide helper methods for dealing with these differences. Rather than using the **Int** flavor of methods (i.e. `[NSNumber numberWithInt:3]`) use the **Integer** flavor (i.e. `[NSNumber numberWithInteger:]`). This will account for the type differences without @@ -125,12 +125,14 @@ That's really all there is to it. Consult the existing test code in Tests/ for r Continuous Integration ------------- +**Note:** RestKit currently uses [Travis CI](https://travis-ci.org/RestKit/RestKit) + The RestKit team keeps the master, development, and active branches of RestKit under the watchful eye of the [Jenkins Continuous Integration Server](http://jenkins-ci.org/). There is a fair amount of complexity involved in getting iOS projects running under Jenkins, so to make things as easy as possible all Jenkins configuration has been collected into a single script within the source code. Currently use of the Jenkins build **requires** the use of RVM for managing the Ruby environment. To configure Jenkins to build RestKit, do the following: 1. Ensure the RestKit test suite executes cleanly on the CI host using the above reference. -1. Install Jenkins (again, we recommend [Homebrew](http://mxcl.github.com/)): `brew install jenkins` +1. Install Jenkins (again, we recommend [Homebrew](https://github.com/Homebrew/homebrew)): `brew install jenkins` 2. Install Jenkins as a system service. Instructions are printed post installation via Homebrew 3. Configure your CI user's OS X account to automatically manage the RVM environment. Create an `~/.rvmrc` file and populate it with the following: ```bash diff --git a/Vendor/LibComponentLogging/Core/README.md b/Vendor/LibComponentLogging/Core/README.md index 56d8018058..c8f3181406 100644 --- a/Vendor/LibComponentLogging/Core/README.md +++ b/Vendor/LibComponentLogging/Core/README.md @@ -24,15 +24,15 @@ This Git repository contains the library's Core part. Download the files of the library Core and a logging back-end, e.g. the LogFile logger, from their repositories on GitHub: -* [Library Core](http://github.com/aharren/LibComponentLogging-Core/downloads) +* [Library Core](http://github.com/aharren/LibComponentLogging-Core) -* [LogFile Logger](http://github.com/aharren/LibComponentLogging-LogFile/downloads) +* [LogFile Logger](http://github.com/aharren/LibComponentLogging-LogFile) -* [SystemLog Logger](http://github.com/aharren/LibComponentLogging-SystemLog/downloads) +* [SystemLog Logger](http://github.com/aharren/LibComponentLogging-SystemLog) -* [NSLog Logger](http://github.com/aharren/LibComponentLogging-NSLog/downloads) +* [NSLog Logger](http://github.com/aharren/LibComponentLogging-NSLog) -* [NSLogger Logger](http://github.com/aharren/LibComponentLogging-NSLogger/downloads) +* [NSLogger Logger](http://github.com/aharren/LibComponentLogging-NSLogger) Extract the files and copy the extracted files to your application's source directory. From 219ced5378aa069f764cff915abf41fe99395c01 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ce=CC=81dric=20Luthi?= Date: Wed, 10 Jun 2015 15:10:26 +0200 Subject: [PATCH 09/94] Define contexts for CocoaLumberjack As recommended by [CocoaLumberjack logging contexts documentation](https://github.com/CocoaLumberjack/CocoaLumberjack/blob/8adde11d0b16843cb45b81dc9b60d1430eb9b538/Documentation/CustomContext.md#example-2) > This will allow application developers to easily manage the log statements coming from your framework. --- Code/Support/RKLumberjackLogger.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Support/RKLumberjackLogger.m b/Code/Support/RKLumberjackLogger.m index 34b2cc8ca7..9f51b8a785 100644 --- a/Code/Support/RKLumberjackLogger.m +++ b/Code/Support/RKLumberjackLogger.m @@ -75,7 +75,7 @@ + (void)logWithComponent:(_RKlcl_component_t)component [DDLog log:async level:componentLevel flag:flag - context:0 /* Could define a special value here to identify RestKit logs to any backend loggers */ + context:0x524B5F00 + component file:path function:function line:line tag:nil format:format args:args]; From 8fe3c12c33e89a740f79dc77afd2fbdc9ef7fcb9 Mon Sep 17 00:00:00 2001 From: Victor Ilinskiy Date: Thu, 11 Jun 2015 15:09:10 +0300 Subject: [PATCH 10/94] Fix for issue #2232. RKAttributeMapping not copying valueTransformer and propertyValueClass properties --- Code/ObjectMapping/RKPropertyMapping.m | 2 ++ .../ObjectMapping/RKAttributeMappingTest.m | 17 +++++++++++++++++ 2 files changed, 19 insertions(+) diff --git a/Code/ObjectMapping/RKPropertyMapping.m b/Code/ObjectMapping/RKPropertyMapping.m index 6d4debd251..0fc2ca1128 100644 --- a/Code/ObjectMapping/RKPropertyMapping.m +++ b/Code/ObjectMapping/RKPropertyMapping.m @@ -44,6 +44,8 @@ - (id)copyWithZone:(NSZone *)zone RKPropertyMapping *copy = [[[self class] allocWithZone:zone] init]; copy.sourceKeyPath = self.sourceKeyPath; copy.destinationKeyPath = self.destinationKeyPath; + copy.propertyValueClass = self.propertyValueClass; + copy.valueTransformer = self.valueTransformer; return copy; } diff --git a/Tests/Logic/ObjectMapping/RKAttributeMappingTest.m b/Tests/Logic/ObjectMapping/RKAttributeMappingTest.m index 6f1ac4202e..bee0d019ac 100644 --- a/Tests/Logic/ObjectMapping/RKAttributeMappingTest.m +++ b/Tests/Logic/ObjectMapping/RKAttributeMappingTest.m @@ -8,6 +8,7 @@ #import "RKTestEnvironment.h" #import "RKAttributeMapping.h" +#import "RKValueTransformers.h" @interface RKAttributeMappingTest : RKTestCase @@ -31,4 +32,20 @@ - (void)testThatAttributeMappingsWithDifferingKeyPathsAreNotConsideredEqual assertThatBool([mapping1 isEqualToMapping:mapping2], is(equalToBool(NO))); } +- (void)testAttributeMappingCopy { + RKAttributeMapping *propertyMapping = [RKAttributeMapping attributeMappingFromKeyPath:@"source" toKeyPath:@"destination"]; + propertyMapping.valueTransformer = [RKBlockValueTransformer valueTransformerWithValidationBlock:^BOOL(__unsafe_unretained Class inputValueClass, __unsafe_unretained Class outputValueClass) { + return [inputValueClass isSubclassOfClass:[NSString class]] && [outputValueClass isSubclassOfClass:[NSString class]]; + } transformationBlock:^BOOL(id inputValue, __autoreleasing id *outputValue, __unsafe_unretained Class outputClass, NSError *__autoreleasing *error) { + return YES; + }]; + propertyMapping.propertyValueClass = [NSString class]; + + RKAttributeMapping *propertyMappingCopy = [propertyMapping copy]; + expect([propertyMappingCopy.sourceKeyPath isEqual:propertyMapping.sourceKeyPath]); + expect([propertyMappingCopy.destinationKeyPath isEqual:propertyMapping.destinationKeyPath]); + expect(propertyMappingCopy.propertyValueClass == propertyMapping.propertyValueClass); + expect([propertyMappingCopy.valueTransformer isEqual:propertyMapping.valueTransformer]); +} + @end From 2566a9bddc10646a3655f01171c651881c50bd77 Mon Sep 17 00:00:00 2001 From: Emlyn Bolton Date: Wed, 17 Jun 2015 15:16:17 -0700 Subject: [PATCH 11/94] Fix for compilation on iOS < 7.0. See https://github.com/RestKit/RestKit/issues/2237#issuecomment-112951812 --- Code/Support/RestKit-Prefix.pch | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Code/Support/RestKit-Prefix.pch b/Code/Support/RestKit-Prefix.pch index 2297f18246..37c35ba574 100644 --- a/Code/Support/RestKit-Prefix.pch +++ b/Code/Support/RestKit-Prefix.pch @@ -5,6 +5,11 @@ #ifdef __OBJC__ #import +// Fix for compilation on iOS 6 where this is not defined. +#if !defined NS_DESIGNATED_INITIALIZER +#define NS_DESIGNATED_INITIALIZER +#endif + #import #if __IPHONE_OS_VERSION_MIN_REQUIRED #import From 26ff9ab6e71480191f5f741eb90b134d70a21bf2 Mon Sep 17 00:00:00 2001 From: Patrick Pierson Date: Mon, 20 Apr 2015 18:27:59 -0400 Subject: [PATCH 12/94] Test case for NSFetchedResultsController observing Managed Object updates merged from another context. --- RestKit.xcodeproj/project.pbxproj | 4 + .../RKFetchedResultsControllerUpdateTest.m | 121 ++++++++++++++++++ 2 files changed, 125 insertions(+) create mode 100644 Tests/Logic/CoreData/RKFetchedResultsControllerUpdateTest.m diff --git a/RestKit.xcodeproj/project.pbxproj b/RestKit.xcodeproj/project.pbxproj index 88cad46df0..5b4c7bc254 100644 --- a/RestKit.xcodeproj/project.pbxproj +++ b/RestKit.xcodeproj/project.pbxproj @@ -593,6 +593,7 @@ 73D3907A14CA1DD50093E3D6 /* channels.xml in Resources */ = {isa = PBXBuildFile; fileRef = 73D3907814CA1D710093E3D6 /* channels.xml */; }; 7AF2905218DF249C009AEB94 /* RKObjectiveCppTest.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2501405215366000004E0466 /* RKObjectiveCppTest.mm */; }; 7F9CBC6174004E31AEC35813 /* libPods-osx.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 86EC453810D648768BF62304 /* libPods-osx.a */; }; + 8AB68F0B1AE5B3B300DD655A /* RKFetchedResultsControllerUpdateTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 8AB68F0A1AE5B3B300DD655A /* RKFetchedResultsControllerUpdateTest.m */; }; BE05BDD11782109F00F7C9C9 /* RKRouteTest.m in Sources */ = {isa = PBXBuildFile; fileRef = BE05BDCF1782109F00F7C9C9 /* RKRouteTest.m */; }; BE05BDD2178214AA00F7C9C9 /* RKRouteTest.m in Sources */ = {isa = PBXBuildFile; fileRef = BE05BDCF1782109F00F7C9C9 /* RKRouteTest.m */; }; C0F11CE3190883380054AEA0 /* RKPathMatcher.h in Headers */ = {isa = PBXBuildFile; fileRef = C0F11CE1190883380054AEA0 /* RKPathMatcher.h */; settings = {ATTRIBUTES = (Public, ); }; }; @@ -981,6 +982,7 @@ 73D3907314CA1A4A0093E3D6 /* child.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = child.json; sourceTree = ""; }; 73D3907814CA1D710093E3D6 /* channels.xml */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = channels.xml; sourceTree = ""; }; 86EC453810D648768BF62304 /* libPods-osx.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-osx.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + 8AB68F0A1AE5B3B300DD655A /* RKFetchedResultsControllerUpdateTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKFetchedResultsControllerUpdateTest.m; sourceTree = ""; }; BE05BDCF1782109F00F7C9C9 /* RKRouteTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKRouteTest.m; sourceTree = ""; }; C0F11CE1190883380054AEA0 /* RKPathMatcher.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKPathMatcher.h; sourceTree = ""; }; C0F11CE2190883380054AEA0 /* RKPathMatcher.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKPathMatcher.m; sourceTree = ""; }; @@ -1353,6 +1355,7 @@ 2564E40A16173F7B00C12D7D /* RKRelationshipConnectionOperationTest.m */, 2546A95716628EDD0078E044 /* RKConnectionDescriptionTest.m */, 2582F56C173038750043B8BB /* RKInMemoryManagedObjectCacheTest.m */, + 8AB68F0A1AE5B3B300DD655A /* RKFetchedResultsControllerUpdateTest.m */, ); name = CoreData; path = Logic/CoreData; @@ -2386,6 +2389,7 @@ 25E36E0215195CED00F9E448 /* RKFetchRequestMappingCacheTest.m in Sources */, 25DB7508151BD551009F01AF /* NSManagedObjectContext+RKAdditionsTest.m in Sources */, 259D985A1550C6BE008C90F5 /* RKEntityByAttributeCacheTest.m in Sources */, + 8AB68F0B1AE5B3B300DD655A /* RKFetchedResultsControllerUpdateTest.m in Sources */, 259D986415521B20008C90F5 /* RKEntityCacheTest.m in Sources */, 252029091577C78600076FB4 /* RKRouteSetTest.m in Sources */, 2519764315823BA1004FE9DD /* RKAttributeMappingTest.m in Sources */, diff --git a/Tests/Logic/CoreData/RKFetchedResultsControllerUpdateTest.m b/Tests/Logic/CoreData/RKFetchedResultsControllerUpdateTest.m new file mode 100644 index 0000000000..9799430421 --- /dev/null +++ b/Tests/Logic/CoreData/RKFetchedResultsControllerUpdateTest.m @@ -0,0 +1,121 @@ +// +// RKFetchedResultsControllerUpdateTest.m +// RestKit +// +// Created by Patrick Pierson on 4/20/15. +// Copyright (c) 2015 RestKit. All rights reserved. +// + +#import "RKTestEnvironment.h" +#import "RKHuman.h" +#import + +@interface MockFRCDelegate : NSObject + +@property (nonatomic, copy) void (^controllerDidChangeContentBlock)(); + +@end + +@implementation MockFRCDelegate + +#pragma mark - NSFetchedResultsControllerDelegate +- (void)controllerDidChangeContent:(NSFetchedResultsController *)controller +{ + if (self.controllerDidChangeContentBlock) self.controllerDidChangeContentBlock(); +} + +@end + +//-------- + +@interface RKFetchedResultsControllerUpdateTest : RKTestCase + +@end + +@implementation RKFetchedResultsControllerUpdateTest + +- (void)setUp +{ + [RKTestFactory setUp]; +} + +- (void)tearDown +{ + [RKTestFactory tearDown]; +} + +- (void)testFetchedResultsController +{ + //Managed object store and managed object contexts + RKManagedObjectStore *managedObjectStore = [RKTestFactory managedObjectStore]; + NSManagedObjectContext *persistentStoreContext = managedObjectStore.persistentStoreManagedObjectContext; + NSManagedObjectContext *persistentStoreChild = [managedObjectStore newChildManagedObjectContextWithConcurrencyType:NSPrivateQueueConcurrencyType tracksChanges:NO]; + NSManagedObjectContext *mainQueueContext = managedObjectStore.mainQueueManagedObjectContext; + + //1. Create initial ManagedObjects and save to store + [persistentStoreContext performBlockAndWait:^{ + RKHuman *human1 = [persistentStoreContext insertNewObjectForEntityForName:@"Human"]; + human1.name = @"human1"; + human1.railsID = @1; + + NSError *error = nil; + [persistentStoreContext save:&error]; + if (error) { + XCTAssertNil(error, @"Error: %@", error); + } + }]; + + //2. Create NSFetchedResultsController + NSFetchRequest *fetchRequest = [[NSFetchRequest alloc] initWithEntityName:@"Human"]; + fetchRequest.sortDescriptors = @[[NSSortDescriptor sortDescriptorWithKey:@"name" ascending:YES]]; + NSFetchedResultsController *fetchedResultsController = [[NSFetchedResultsController alloc] initWithFetchRequest:fetchRequest managedObjectContext:mainQueueContext sectionNameKeyPath:nil cacheName:nil]; + + //3. Add delegate to detect FRC updates + XCTestExpectation *expectation = [self expectationWithDescription:@"NSFetchedResultsController Updates"]; + MockFRCDelegate *frcDelegate = [[MockFRCDelegate alloc] init]; + frcDelegate.controllerDidChangeContentBlock = ^{ + [expectation fulfill]; + }; + fetchedResultsController.delegate = frcDelegate; + [fetchedResultsController performFetch:nil]; + + XCTAssert(fetchedResultsController.fetchedObjects.count == 1, @"Expecting NSFetchedResultsController to contain single human object."); + + //4. Update name of managed object in child managed object context + [persistentStoreChild performBlockAndWait:^{ + NSFetchRequest *human1FetchRequest = [[NSFetchRequest alloc] initWithEntityName:@"Human"]; + NSError *error = nil; + NSArray *results = [persistentStoreChild executeFetchRequest:human1FetchRequest error:&error]; + XCTAssertNil(error, @"Error: %@", error); + + RKHuman *childHuman1 = [results firstObject]; + XCTAssertNotNil(childHuman1, @"Failed to fetch human1"); + + childHuman1.name = @"Updated Human"; + + error = nil; + [persistentStoreChild save:&error]; + if (error) { + XCTAssertNil(error, @"Error: %@", error); + } + }]; + + //5. Save persistent store context to store + [persistentStoreContext performBlockAndWait:^{ + NSError *error = nil; + [persistentStoreContext save:&error]; + XCTAssertNil(error, @"Error: %@", error); + }]; + + //6. Wait for NSFetchedResultsController update expectation + [self waitForExpectationsWithTimeout:1 handler:^(NSError *error) { + XCTAssertNil(error, @"Error: %@", error); + }]; + + //7. Check for new human name update in NSFetchedResultsController + NSArray *humanNames = [fetchedResultsController.fetchedObjects valueForKeyPath:@"name"]; + XCTAssertTrue([humanNames containsObject:@"Updated Human"], @"Does not contain updated human name."); + XCTAssertFalse([humanNames containsObject:@"human1"], @"FetchedResultsController contains original human name."); +} + +@end From 36955d4d3c85bd02aa9c32eb71c04634ce0f8f34 Mon Sep 17 00:00:00 2001 From: Sam Krishna Date: Tue, 21 Jul 2015 08:27:42 -0700 Subject: [PATCH 13/94] Added macro conditionals to remove build warnings built against post-iOS 7 and post-OSX 10.9 SDKs --- Code/ObjectMapping/RKHTTPUtilities.m | 29 +++++++++++++++++++++++++--- 1 file changed, 26 insertions(+), 3 deletions(-) diff --git a/Code/ObjectMapping/RKHTTPUtilities.m b/Code/ObjectMapping/RKHTTPUtilities.m index e789c4b47a..1b4aafe657 100644 --- a/Code/ObjectMapping/RKHTTPUtilities.m +++ b/Code/ObjectMapping/RKHTTPUtilities.m @@ -344,8 +344,13 @@ RKRequestMethod RKRequestMethodFromString(NSString *methodName) int parsed = 0, cs = 1; NSDate *date = NULL; +#if (defined(__IPHONE_OS_VERSION_MAX_ALLOWED) && (__IPHONE_OS_VERSION_MAX_ALLOWED < 70000)) || \ +(defined(MAC_OS_X_VERSION_MAX_ALLOWED) && (MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_9)) CFGregorianDate gdate; memset(&gdate, 0, sizeof(CFGregorianDate)); +#else + NSDateComponents *gdate = [[NSDateComponents alloc] init]; +#endif { int _slen, _trans; @@ -397,11 +402,29 @@ RKRequestMethod RKRequestMethodFromString(NSString *methodName) _out: {} } - static CFTimeZoneRef gmtTimeZone; static dispatch_once_t onceToken; - dispatch_once(&onceToken, ^{ gmtTimeZone = CFTimeZoneCreateWithTimeIntervalFromGMT(NULL, 0.0); }); - if(parsed == 1) { date = [NSDate dateWithTimeIntervalSinceReferenceDate:CFGregorianDateGetAbsoluteTime(gdate, gmtTimeZone)]; } +#if (defined(__IPHONE_OS_VERSION_MAX_ALLOWED) && (__IPHONE_OS_VERSION_MAX_ALLOWED < 70000)) || \ +(defined(MAC_OS_X_VERSION_MAX_ALLOWED) && (MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_9)) + static CFTimeZoneRef gmtTimeZone; + dispatch_once(&onceToken, ^{ + gmtTimeZone = CFTimeZoneCreateWithTimeIntervalFromGMT(NULL, 0.0); + }); + + if (parsed == 1) { + date = [NSDate dateWithTimeIntervalSinceReferenceDate:CFGregorianDateGetAbsoluteTime(gdate, gmtTimeZone)]; + } +#else + static NSCalendar *gregorian; + dispatch_once(&onceToken, ^{ + gregorian = [[NSCalendar alloc] initWithCalendarIdentifier:NSCalendarIdentifierGregorian]; + gregorian.timeZone = [NSTimeZone timeZoneForSecondsFromGMT:0]; + }); + + if (parsed == 1) { + date = [gregorian dateFromComponents:gdate]; + } +#endif return(date); } From 0b8baca8faa0be28f4f56485082a1adf4cac1beb Mon Sep 17 00:00:00 2001 From: "Samuel E. Giddins" Date: Tue, 21 Jul 2015 23:36:18 -0700 Subject: [PATCH 14/94] Bump ruby version to 2.2.2 --- .ruby-version | 2 +- .travis.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.ruby-version b/.ruby-version index c043eea776..b1b25a5ffa 100644 --- a/.ruby-version +++ b/.ruby-version @@ -1 +1 @@ -2.2.1 +2.2.2 diff --git a/.travis.yml b/.travis.yml index 769bd0077e..6971100594 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,5 +1,5 @@ language: objective-c -rvm: 2.2.1 +rvm: 2.2.2 install: - bundle install - bundle exec pod install From de2d31d4641083c957051add3344578d0e6a5dcb Mon Sep 17 00:00:00 2001 From: "Samuel E. Giddins" Date: Tue, 21 Jul 2015 23:37:03 -0700 Subject: [PATCH 15/94] [Bundle] Update --- Gemfile.lock | 46 +++++++++++++++++++++++----------------------- 1 file changed, 23 insertions(+), 23 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 16a5621328..b587a93a3f 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,54 +1,54 @@ GEM remote: https://rubygems.org/ specs: - activesupport (4.2.1) + activesupport (4.2.3) i18n (~> 0.7) json (~> 1.7, >= 1.7.7) minitest (~> 5.1) thread_safe (~> 0.3, >= 0.3.4) tzinfo (~> 1.1) - backports (3.6.4) - claide (0.8.1) - cocoapods (0.37.1) + backports (3.6.5) + claide (0.8.2) + cocoapods (0.37.2) activesupport (>= 3.2.15) claide (~> 0.8.1) - cocoapods-core (= 0.37.1) + cocoapods-core (= 0.37.2) cocoapods-downloader (~> 0.9.0) cocoapods-plugins (~> 0.4.2) - cocoapods-trunk (~> 0.6.0) - cocoapods-try (~> 0.4.4) + cocoapods-trunk (~> 0.6.1) + cocoapods-try (~> 0.4.5) colored (~> 1.2) escape (~> 0.0.4) molinillo (~> 0.2.3) nap (~> 0.8) - xcodeproj (~> 0.24.1) - cocoapods-core (0.37.1) + xcodeproj (~> 0.24.2) + cocoapods-core (0.37.2) activesupport (>= 3.2.15) fuzzy_match (~> 2.0.4) nap (~> 0.8.0) - cocoapods-downloader (0.9.0) + cocoapods-downloader (0.9.1) cocoapods-plugins (0.4.2) nap - cocoapods-trunk (0.6.0) + cocoapods-trunk (0.6.1) nap (>= 0.8) netrc (= 0.7.8) - cocoapods-try (0.4.4) + cocoapods-try (0.4.5) colored (1.2) - daemons (1.2.2) + daemons (1.2.3) escape (0.0.4) eventmachine (1.0.7) fuzzy_match (2.0.4) i18n (0.7.0) - json (1.8.2) + json (1.8.3) mini_portile (0.6.2) - minitest (5.6.1) + minitest (5.7.0) molinillo (0.2.3) - multi_json (1.11.0) + multi_json (1.11.2) nap (0.8.0) netrc (0.7.8) nokogiri (1.6.6.2) mini_portile (~> 0.6.0) - rack (1.5.2) + rack (1.5.5) rack-protection (1.5.3) rack rack-test (0.6.3) @@ -61,25 +61,25 @@ GEM rack (~> 1.4) rack-protection (~> 1.4) tilt (>= 1.3, < 3) - sinatra-contrib (1.4.2) + sinatra-contrib (1.4.6) backports (>= 2.0) multi_json rack-protection rack-test sinatra (~> 1.4.0) - tilt (~> 1.3) + tilt (>= 1.3, < 3) thin (1.5.1) daemons (>= 1.0.9) eventmachine (>= 0.12.6) rack (>= 1.0.0) thread_safe (0.3.5) - tilt (1.4.1) + tilt (2.0.1) tzinfo (1.2.2) thread_safe (~> 0.1) - xcodeproj (0.24.1) + xcodeproj (0.24.3) activesupport (>= 3) colored (~> 1.2) - xcpretty (0.1.9) + xcpretty (0.1.10) xctasks (0.5.0) nokogiri (~> 1.6, >= 1.6.3.1) rake (~> 10.0, >= 10.0.0) @@ -97,4 +97,4 @@ DEPENDENCIES xctasks (~> 0.5.0) BUNDLED WITH - 1.10.0.pre.2 + 1.10.5 From 560e96e49cabd0ae44ff4622beb71b2da6f978d8 Mon Sep 17 00:00:00 2001 From: "Samuel E. Giddins" Date: Tue, 21 Jul 2015 23:37:44 -0700 Subject: [PATCH 16/94] [Bundle] Update CocoaPods to 0.38 --- Gemfile | 2 +- Gemfile.lock | 26 +++++++++++++++----------- 2 files changed, 16 insertions(+), 12 deletions(-) diff --git a/Gemfile b/Gemfile index 4ca77d3bbf..5cd08006e6 100644 --- a/Gemfile +++ b/Gemfile @@ -4,6 +4,6 @@ gem 'rakeup', '~> 1.2.0' gem 'sinatra', '~> 1.4.0' gem 'sinatra-contrib', '~> 1.4.0' gem 'thin', '~> 1.5.0' -gem 'cocoapods', '~> 0.37.0' +gem 'cocoapods', '~> 0.38.0' gem 'xctasks', '~> 0.5.0' gem 'xcpretty', '~> 0.1.6' diff --git a/Gemfile.lock b/Gemfile.lock index b587a93a3f..1332e29096 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -8,27 +8,30 @@ GEM thread_safe (~> 0.3, >= 0.3.4) tzinfo (~> 1.1) backports (3.6.5) - claide (0.8.2) - cocoapods (0.37.2) + claide (0.9.1) + cocoapods (0.38.0) activesupport (>= 3.2.15) - claide (~> 0.8.1) - cocoapods-core (= 0.37.2) - cocoapods-downloader (~> 0.9.0) + claide (~> 0.9.1) + cocoapods-core (= 0.38.0) + cocoapods-downloader (~> 0.9.1) cocoapods-plugins (~> 0.4.2) + cocoapods-stats (~> 0.5.3) cocoapods-trunk (~> 0.6.1) cocoapods-try (~> 0.4.5) colored (~> 1.2) escape (~> 0.0.4) - molinillo (~> 0.2.3) + molinillo (~> 0.3.0) nap (~> 0.8) - xcodeproj (~> 0.24.2) - cocoapods-core (0.37.2) + xcodeproj (~> 0.26.2) + cocoapods-core (0.38.0) activesupport (>= 3.2.15) fuzzy_match (~> 2.0.4) nap (~> 0.8.0) cocoapods-downloader (0.9.1) cocoapods-plugins (0.4.2) nap + cocoapods-stats (0.5.3) + nap (~> 0.8) cocoapods-trunk (0.6.1) nap (>= 0.8) netrc (= 0.7.8) @@ -42,7 +45,7 @@ GEM json (1.8.3) mini_portile (0.6.2) minitest (5.7.0) - molinillo (0.2.3) + molinillo (0.3.0) multi_json (1.11.2) nap (0.8.0) netrc (0.7.8) @@ -76,8 +79,9 @@ GEM tilt (2.0.1) tzinfo (1.2.2) thread_safe (~> 0.1) - xcodeproj (0.24.3) + xcodeproj (0.26.2) activesupport (>= 3) + claide (~> 0.9.1) colored (~> 1.2) xcpretty (0.1.10) xctasks (0.5.0) @@ -88,7 +92,7 @@ PLATFORMS ruby DEPENDENCIES - cocoapods (~> 0.37.0) + cocoapods (~> 0.38.0) rakeup (~> 1.2.0) sinatra (~> 1.4.0) sinatra-contrib (~> 1.4.0) From fcff50c9a78522ff7d5f1a35e592cb65e2522699 Mon Sep 17 00:00:00 2001 From: "Samuel E. Giddins" Date: Sat, 24 Jan 2015 18:58:57 -0800 Subject: [PATCH 17/94] Add support for inclusion of RestKit as a Clang Module Maintains support for the use of vendored dependencies inside the main Xcode project itself, rather than using subprojects. --- Code/Network/RKHTTPRequestOperation.h | 9 +++++++-- Code/Network/RKObjectManager.h | 13 +++++++++---- Code/Network/RKObjectManager.m | 14 +++++++------- Code/ObjectMapping.h | 7 ++++++- Code/ObjectMapping/RKObjectMapping.h | 7 ++++++- Code/Support/lcl_config_components_RK.h | 21 +++++++++++---------- Vendor/LibComponentLogging/Core/lcl_RK.h | 4 +++- Vendor/LibComponentLogging/Core/lcl_RK.m | 6 +++--- 8 files changed, 52 insertions(+), 29 deletions(-) diff --git a/Code/Network/RKHTTPRequestOperation.h b/Code/Network/RKHTTPRequestOperation.h index f18d9f2e40..39f8a10c79 100644 --- a/Code/Network/RKHTTPRequestOperation.h +++ b/Code/Network/RKHTTPRequestOperation.h @@ -18,8 +18,13 @@ // limitations under the License. // -#import "AFHTTPClient.h" -#import "AFHTTPRequestOperation.h" +#if __has_include() +# import +# import +#else +# import "AFHTTPClient.h" +# import "AFHTTPRequestOperation.h" +#endif // Expose the default headers from AFNetworking's AFHTTPClient @interface AFHTTPClient () diff --git a/Code/Network/RKObjectManager.h b/Code/Network/RKObjectManager.h index a1cd3ed042..e351bf544c 100644 --- a/Code/Network/RKObjectManager.h +++ b/Code/Network/RKObjectManager.h @@ -21,12 +21,17 @@ #import "RKRouter.h" #import "RKPaginator.h" #import "RKMacros.h" -#import "AFNetworking.h" -#ifdef _COREDATADEFINES_H -#if __has_include("RKCoreData.h") -#define RKCoreDataIncluded +#if __has_include() +# import +#else +# import "AFNetworking.h" #endif + +#ifdef _COREDATADEFINES_H +# if __has_include("RKCoreData.h") +# define RKCoreDataIncluded +# endif #endif @protocol RKSerialization; diff --git a/Code/Network/RKObjectManager.m b/Code/Network/RKObjectManager.m index 800f84e4a8..2d27428724 100644 --- a/Code/Network/RKObjectManager.m +++ b/Code/Network/RKObjectManager.m @@ -38,16 +38,16 @@ #import "RKRouteSet.h" #ifdef _COREDATADEFINES_H -#if __has_include("RKCoreData.h") -#define RKCoreDataIncluded -#import "RKManagedObjectStore.h" -#import "RKManagedObjectRequestOperation.h" -#endif +# if __has_include("RKCoreData.h") +# define RKCoreDataIncluded +# import "RKManagedObjectStore.h" +# import "RKManagedObjectRequestOperation.h" +# endif #endif #if !__has_feature(objc_arc) -#error RestKit must be built with ARC. -// You can turn on ARC for only RestKit files by adding "-fobjc-arc" to the build phase for each of its files. +#error RestKit must be built with ARC. \ +You can turn on ARC for only RestKit files by adding "-fobjc-arc" to the build phase for each of its files. #endif ////////////////////////////////// diff --git a/Code/ObjectMapping.h b/Code/ObjectMapping.h index 54c84dfdbd..152fcb1571 100644 --- a/Code/ObjectMapping.h +++ b/Code/ObjectMapping.h @@ -21,8 +21,13 @@ #import "RKObjectMapping.h" #import "RKAttributeMapping.h" #import "RKRelationshipMapping.h" -#import "RKValueTransformers.h" #import "RKMappingResult.h" #import "RKMapperOperation.h" #import "RKDynamicMapping.h" #import "RKErrorMessage.h" + +#if __has_include() +# import +#else +# import "RKValueTransformers.h" +#endif diff --git a/Code/ObjectMapping/RKObjectMapping.h b/Code/ObjectMapping/RKObjectMapping.h index 888477806c..afd388b738 100644 --- a/Code/ObjectMapping/RKObjectMapping.h +++ b/Code/ObjectMapping/RKObjectMapping.h @@ -20,7 +20,12 @@ #import "RKMacros.h" #import "RKMapping.h" -#import "RKValueTransformers.h" + +#if __has_include() +# import +#else +# import "RKValueTransformers.h" +#endif @class RKPropertyMapping, RKAttributeMapping, RKRelationshipMapping; @protocol RKValueTransforming; diff --git a/Code/Support/lcl_config_components_RK.h b/Code/Support/lcl_config_components_RK.h index 3638292044..e71025472b 100644 --- a/Code/Support/lcl_config_components_RK.h +++ b/Code/Support/lcl_config_components_RK.h @@ -49,14 +49,15 @@ // RestKit Logging Components // -_RKlcl_component(App, "app", "App") -_RKlcl_component(RestKit, "restkit", "RestKit") -_RKlcl_component(RestKitCoreData, "restkit.core_data", "RestKit/CoreData") -_RKlcl_component(RestKitCoreDataCache, "restkit.core_data.cache", "RestKit/CoreData/Cache") -_RKlcl_component(RestKitNetwork, "restkit.network", "RestKit/Network") -_RKlcl_component(RestKitNetworkCoreData, "restkit.network.core_data", "RestKit/Network/CoreData") -_RKlcl_component(RestKitObjectMapping, "restkit.object_mapping", "RestKit/ObjectMapping") -_RKlcl_component(RestKitSearch, "restkit.search", "RestKit/Search") -_RKlcl_component(RestKitSupport, "restkit.support", "RestKit/Support") -_RKlcl_component(RestKitTesting, "restkit.testing", "RestKit/Testing") +#define RKLCLComponentDefinitions \ +_RKlcl_component(App, "app", "App") \ +_RKlcl_component(RestKit, "restkit", "RestKit") \ +_RKlcl_component(RestKitCoreData, "restkit.core_data", "RestKit/CoreData") \ +_RKlcl_component(RestKitCoreDataCache, "restkit.core_data.cache", "RestKit/CoreData/Cache") \ +_RKlcl_component(RestKitNetwork, "restkit.network", "RestKit/Network") \ +_RKlcl_component(RestKitNetworkCoreData, "restkit.network.core_data", "RestKit/Network/CoreData") \ +_RKlcl_component(RestKitObjectMapping, "restkit.object_mapping", "RestKit/ObjectMapping") \ +_RKlcl_component(RestKitSearch, "restkit.search", "RestKit/Search") \ +_RKlcl_component(RestKitSupport, "restkit.support", "RestKit/Support") \ +_RKlcl_component(RestKitTesting, "restkit.testing", "RestKit/Testing") \ _RKlcl_component(RestKitUI, "restkit.ui", "RestKit/UI") diff --git a/Vendor/LibComponentLogging/Core/lcl_RK.h b/Vendor/LibComponentLogging/Core/lcl_RK.h index c4e3324ef0..25ff99dcb7 100644 --- a/Vendor/LibComponentLogging/Core/lcl_RK.h +++ b/Vendor/LibComponentLogging/Core/lcl_RK.h @@ -31,6 +31,8 @@ #define _RKLCL_VERSION_BUILD 1 #define _RKLCL_VERSION_SUFFIX "" +#import "lcl_config_components_RK.h" + // // lcl -- LibComponentLogging, embedded, RestKit/RK // @@ -131,7 +133,7 @@ enum _RKlcl_enum_component_t { # define _RKlcl_component(_identifier, _header, _name) \ RKlcl_c##_identifier, \ __RKlcl_log_symbol_RKlcl_c##_identifier = RKlcl_c##_identifier, -# include "lcl_config_components_RK.h" + RKLCLComponentDefinitions # undef _RKlcl_component _RKlcl_component_t_count, diff --git a/Vendor/LibComponentLogging/Core/lcl_RK.m b/Vendor/LibComponentLogging/Core/lcl_RK.m index 9c2a6b8cda..c8602967fb 100644 --- a/Vendor/LibComponentLogging/Core/lcl_RK.m +++ b/Vendor/LibComponentLogging/Core/lcl_RK.m @@ -34,7 +34,7 @@ const char * const _RKlcl_component_identifier[] = { # define _RKlcl_component(_identifier, _header, _name) \ #_identifier, -# include "lcl_config_components_RK.h" + RKLCLComponentDefinitions # undef _RKlcl_component }; @@ -42,7 +42,7 @@ const char * const _RKlcl_component_header[] = { # define _RKlcl_component(_identifier, _header, _name) \ _header, -# include "lcl_config_components_RK.h" + RKLCLComponentDefinitions # undef _RKlcl_component }; @@ -50,7 +50,7 @@ const char * const _RKlcl_component_name[] = { # define _RKlcl_component(_identifier, _header, _name) \ _name, -# include "lcl_config_components_RK.h" + RKLCLComponentDefinitions # undef _RKlcl_component }; From 67b89b888b2bb883e9b65cb6b0c16ebdf3a6e347 Mon Sep 17 00:00:00 2001 From: "Samuel E. Giddins" Date: Sat, 24 Jan 2015 22:33:14 -0800 Subject: [PATCH 18/94] [TestEnvironment] Import instead of include --- Tests/RKTestEnvironment.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Tests/RKTestEnvironment.m b/Tests/RKTestEnvironment.m index ce7be65108..3ea5201975 100644 --- a/Tests/RKTestEnvironment.m +++ b/Tests/RKTestEnvironment.m @@ -18,7 +18,7 @@ // limitations under the License. // -#include +#import #import "RKTestEnvironment.h" @implementation RKTestCase From 4282232ee706f1c1a45fed2eeee1ce9a4603f018 Mon Sep 17 00:00:00 2001 From: "Samuel E. Giddins" Date: Sat, 24 Jan 2015 22:33:40 -0800 Subject: [PATCH 19/94] [LumberjackLogger] Use new macro definition of component definitions --- Code/Support/RKLumberjackLogger.m | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Code/Support/RKLumberjackLogger.m b/Code/Support/RKLumberjackLogger.m index 9f51b8a785..cdf0d51a28 100644 --- a/Code/Support/RKLumberjackLogger.m +++ b/Code/Support/RKLumberjackLogger.m @@ -86,6 +86,8 @@ + (void)logWithComponent:(_RKlcl_component_t)component /* Create a DDRegisteredDynamicLogging class for each RestKit component */ +#import "lcl_config_components_RK.h" + #undef _RKlcl_component #define _RKlcl_component(_identifier, _header, _name) \ @interface RKLumberjackLog##_identifier : NSObject \ @@ -100,7 +102,8 @@ + (void)ddSetLogLevel:(int)logLevel { } \ @end -#include "lcl_config_components_RK.h" +RKLCLComponentDefinitions + #undef _RKlcl_component From 3064187de2668169c2f7258b625b1c879e5350f2 Mon Sep 17 00:00:00 2001 From: "Samuel E. Giddins" Date: Sat, 13 Jun 2015 19:03:24 -0700 Subject: [PATCH 20/94] Always build using CocoaPods --- .gitignore | 1 + .gitmodules | 6 - Podfile | 14 +- Podfile.lock | 9 +- Resources/PLISTs/RestKitFramework-Info.plist | 2 +- RestKit.xcodeproj/project.pbxproj | 443 ++++++------------ .../xcschemes/Build All Examples.xcscheme | 5 +- Vendor/AFNetworking | 1 - Vendor/ISO8601DateFormatterValueTransformer | 1 - Vendor/RKValueTransformers | 1 - Vendor/SOCKit | 1 - Vendor/TransitionKit | 1 - 12 files changed, 174 insertions(+), 311 deletions(-) delete mode 160000 Vendor/AFNetworking delete mode 160000 Vendor/ISO8601DateFormatterValueTransformer delete mode 160000 Vendor/RKValueTransformers delete mode 160000 Vendor/SOCKit delete mode 160000 Vendor/TransitionKit diff --git a/.gitignore b/.gitignore index d7356f40af..54eaeeff2d 100644 --- a/.gitignore +++ b/.gitignore @@ -33,3 +33,4 @@ DerivedData # Bundler binstubs .bundle bin +RestKit.xcscmblueprint diff --git a/.gitmodules b/.gitmodules index f6265ec0e3..946ac987de 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,12 +1,6 @@ [submodule "Vendor/AFNetworking"] path = Vendor/AFNetworking url = https://github.com/AFNetworking/AFNetworking.git -[submodule "Vendor/TransitionKit"] - path = Vendor/TransitionKit - url = https://github.com/blakewatters/TransitionKit.git -[submodule "Vendor/RKValueTransformers"] - path = Vendor/RKValueTransformers - url = https://github.com/RestKit/RKValueTransformers.git [submodule "Vendor/ISO8601DateFormatterValueTransformer"] path = Vendor/ISO8601DateFormatterValueTransformer url = https://github.com/blakewatters/ISO8601DateFormatterValueTransformer.git diff --git a/Podfile b/Podfile index 5a87788340..2277a10625 100644 --- a/Podfile +++ b/Podfile @@ -2,16 +2,26 @@ source 'https://github.com/CocoaPods/Specs.git' inhibit_all_warnings! +target :RestKit do + platform :ios, '5.1.1' + podspec +end + +target :RestKitFramework do + platform :osx, '10.7' + podspec +end + def import_pods pod 'RestKit', :path => '.' pod 'RestKit/Testing', :path => '.' pod 'RestKit/Search', :path => '.' - + pod 'Specta', '0.2.1' pod 'OCMock', '2.2.4' pod 'OCHamcrest', '3.0.1' pod 'Expecta', '0.3.1' - + # Used for testing Value Transformer integration pod 'RKCLLocationValueTransformer', '~> 1.1.0' end diff --git a/Podfile.lock b/Podfile.lock index 72a146e7c9..4efa442371 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -36,14 +36,19 @@ PODS: - TransitionKit (2.1.1) DEPENDENCIES: + - AFNetworking (~> 1.3.0) - Expecta (= 0.3.1) + - ISO8601DateFormatterValueTransformer (~> 0.6.0) - OCHamcrest (= 3.0.1) - OCMock (= 2.2.4) - RestKit (from `.`) - RestKit/Search (from `.`) - RestKit/Testing (from `.`) - RKCLLocationValueTransformer (~> 1.1.0) + - RKValueTransformers (~> 1.1.0) + - SOCKit - Specta (= 0.2.1) + - TransitionKit (~> 2.1.0) EXTERNAL SOURCES: RestKit: @@ -57,9 +62,9 @@ SPEC CHECKSUMS: OCMock: a6a7dc0e3997fb9f35d99f72528698ebf60d64f2 RestKit: 1987b5efef289c6b27bd980714d6ca48d3871b78 RKCLLocationValueTransformer: 2cf0ea0fb7cd4bc70c56834fb92abc717c66f982 - RKValueTransformers: 66ac5e4f077fdbe3496e792d89eeff4c3eb67701 + RKValueTransformers: d016f1967ae67997e492520fd0f9c512ccf168ae SOCKit: c7376ac262bea9115b8f749358f762522a47d392 Specta: 15a276a6343867b426d5ed135d5aa4d04123a573 TransitionKit: 3a14b6acc7cf2d1dd3e454e24dbad1cfab9a1ef1 -COCOAPODS: 0.36.3 +COCOAPODS: 0.37.2 diff --git a/Resources/PLISTs/RestKitFramework-Info.plist b/Resources/PLISTs/RestKitFramework-Info.plist index 4723995c04..4acc7e4c10 100644 --- a/Resources/PLISTs/RestKitFramework-Info.plist +++ b/Resources/PLISTs/RestKitFramework-Info.plist @@ -9,7 +9,7 @@ CFBundleIconFile CFBundleIdentifier - org.restkit.${PRODUCT_NAME:rfc1034identifier} + $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundleName diff --git a/RestKit.xcodeproj/project.pbxproj b/RestKit.xcodeproj/project.pbxproj index f912ec9910..7d4dc6d4d8 100644 --- a/RestKit.xcodeproj/project.pbxproj +++ b/RestKit.xcodeproj/project.pbxproj @@ -107,10 +107,6 @@ 25160EE31456532C0060A5C5 /* lcl_RK.h in Headers */ = {isa = PBXBuildFile; fileRef = 25160EA21456532C0060A5C5 /* lcl_RK.h */; settings = {ATTRIBUTES = (Public, ); }; }; 25160EE41456532C0060A5C5 /* lcl_RK.m in Sources */ = {isa = PBXBuildFile; fileRef = 25160EA31456532C0060A5C5 /* lcl_RK.m */; }; 25160EE51456532C0060A5C5 /* lcl_RK.m in Sources */ = {isa = PBXBuildFile; fileRef = 25160EA31456532C0060A5C5 /* lcl_RK.m */; }; - 25160F081456532C0060A5C5 /* SOCKit.h in Headers */ = {isa = PBXBuildFile; fileRef = 25160EBD1456532C0060A5C5 /* SOCKit.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 25160F091456532C0060A5C5 /* SOCKit.h in Headers */ = {isa = PBXBuildFile; fileRef = 25160EBD1456532C0060A5C5 /* SOCKit.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 25160F0A1456532C0060A5C5 /* SOCKit.m in Sources */ = {isa = PBXBuildFile; fileRef = 25160EBE1456532C0060A5C5 /* SOCKit.m */; settings = {COMPILER_FLAGS = "-fno-objc-arc"; }; }; - 25160F0B1456532C0060A5C5 /* SOCKit.m in Sources */ = {isa = PBXBuildFile; fileRef = 25160EBE1456532C0060A5C5 /* SOCKit.m */; settings = {COMPILER_FLAGS = "-fno-objc-arc"; }; }; 25160F25145655AF0060A5C5 /* RestKit.h in Headers */ = {isa = PBXBuildFile; fileRef = 25160DA1145650490060A5C5 /* RestKit.h */; settings = {ATTRIBUTES = (Public, ); }; }; 25160F44145655C60060A5C5 /* RKDynamicMapping.h in Headers */ = {isa = PBXBuildFile; fileRef = 25160D7C145650490060A5C5 /* RKDynamicMapping.h */; settings = {ATTRIBUTES = (Public, ); }; }; 25160F45145655C60060A5C5 /* RKDynamicMapping.m in Sources */ = {isa = PBXBuildFile; fileRef = 25160D7D145650490060A5C5 /* RKDynamicMapping.m */; }; @@ -283,18 +279,6 @@ 2520290A1577C78600076FB4 /* RKRouteSetTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 252029081577C78600076FB4 /* RKRouteSetTest.m */; }; 252205CC162B242400F7B11E /* RKHTTPUtilitiesTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 252205CB162B242400F7B11E /* RKHTTPUtilitiesTest.m */; }; 252205CD162B242400F7B11E /* RKHTTPUtilitiesTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 252205CB162B242400F7B11E /* RKHTTPUtilitiesTest.m */; }; - 252CCE6617E08E2D00B7F0BF /* RKValueTransformers.h in Headers */ = {isa = PBXBuildFile; fileRef = 252CCE6017E08E2D00B7F0BF /* RKValueTransformers.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 252CCE6717E08E2D00B7F0BF /* RKValueTransformers.h in Headers */ = {isa = PBXBuildFile; fileRef = 252CCE6017E08E2D00B7F0BF /* RKValueTransformers.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 252CCE6817E08E2D00B7F0BF /* RKValueTransformers.m in Sources */ = {isa = PBXBuildFile; fileRef = 252CCE6117E08E2D00B7F0BF /* RKValueTransformers.m */; }; - 252CCE6917E08E2D00B7F0BF /* RKValueTransformers.m in Sources */ = {isa = PBXBuildFile; fileRef = 252CCE6117E08E2D00B7F0BF /* RKValueTransformers.m */; }; - 252CCE7217E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.h in Headers */ = {isa = PBXBuildFile; fileRef = 252CCE6E17E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 252CCE7317E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.h in Headers */ = {isa = PBXBuildFile; fileRef = 252CCE6E17E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 252CCE7417E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.m in Sources */ = {isa = PBXBuildFile; fileRef = 252CCE6F17E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.m */; }; - 252CCE7517E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.m in Sources */ = {isa = PBXBuildFile; fileRef = 252CCE6F17E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.m */; }; - 252CCE7617E0CA2700B7F0BF /* RKISO8601DateFormatter.h in Headers */ = {isa = PBXBuildFile; fileRef = 252CCE7017E0CA2700B7F0BF /* RKISO8601DateFormatter.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 252CCE7717E0CA2700B7F0BF /* RKISO8601DateFormatter.h in Headers */ = {isa = PBXBuildFile; fileRef = 252CCE7017E0CA2700B7F0BF /* RKISO8601DateFormatter.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 252CCE7817E0CA2700B7F0BF /* RKISO8601DateFormatter.m in Sources */ = {isa = PBXBuildFile; fileRef = 252CCE7117E0CA2700B7F0BF /* RKISO8601DateFormatter.m */; }; - 252CCE7917E0CA2700B7F0BF /* RKISO8601DateFormatter.m in Sources */ = {isa = PBXBuildFile; fileRef = 252CCE7117E0CA2700B7F0BF /* RKISO8601DateFormatter.m */; }; 252EFAFA14D8EAEC004863C8 /* RKEvent.m in Sources */ = {isa = PBXBuildFile; fileRef = 252EFAF914D8EAEC004863C8 /* RKEvent.m */; }; 252EFAFB14D8EAEC004863C8 /* RKEvent.m in Sources */ = {isa = PBXBuildFile; fileRef = 252EFAF914D8EAEC004863C8 /* RKEvent.m */; }; 252EFB2814DA0689004863C8 /* NakedEvents.json in Resources */ = {isa = PBXBuildFile; fileRef = 252EFB2714DA0689004863C8 /* NakedEvents.json */; }; @@ -407,44 +391,6 @@ 2598889015EC169E006CAE95 /* RKPropertyMapping.m in Sources */ = {isa = PBXBuildFile; fileRef = 2598888C15EC169E006CAE95 /* RKPropertyMapping.m */; }; 259AC481162B05C80012D2F9 /* RKObjectRequestOperationTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 259AC480162B05C80012D2F9 /* RKObjectRequestOperationTest.m */; }; 259AC482162B05C80012D2F9 /* RKObjectRequestOperationTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 259AC480162B05C80012D2F9 /* RKObjectRequestOperationTest.m */; }; - 259B96D51604CCCC0000C250 /* AFHTTPClient.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96C21604CCCC0000C250 /* AFHTTPClient.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96D61604CCCC0000C250 /* AFHTTPClient.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96C21604CCCC0000C250 /* AFHTTPClient.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96D71604CCCC0000C250 /* AFHTTPClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96C31604CCCC0000C250 /* AFHTTPClient.m */; }; - 259B96D81604CCCC0000C250 /* AFHTTPClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96C31604CCCC0000C250 /* AFHTTPClient.m */; }; - 259B96D91604CCCC0000C250 /* AFHTTPRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96C41604CCCC0000C250 /* AFHTTPRequestOperation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96DA1604CCCC0000C250 /* AFHTTPRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96C41604CCCC0000C250 /* AFHTTPRequestOperation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96DB1604CCCC0000C250 /* AFHTTPRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96C51604CCCC0000C250 /* AFHTTPRequestOperation.m */; }; - 259B96DC1604CCCC0000C250 /* AFHTTPRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96C51604CCCC0000C250 /* AFHTTPRequestOperation.m */; }; - 259B96DD1604CCCC0000C250 /* AFImageRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96C61604CCCC0000C250 /* AFImageRequestOperation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96DE1604CCCC0000C250 /* AFImageRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96C61604CCCC0000C250 /* AFImageRequestOperation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96DF1604CCCC0000C250 /* AFImageRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96C71604CCCC0000C250 /* AFImageRequestOperation.m */; }; - 259B96E01604CCCC0000C250 /* AFImageRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96C71604CCCC0000C250 /* AFImageRequestOperation.m */; }; - 259B96E11604CCCC0000C250 /* AFJSONRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96C81604CCCC0000C250 /* AFJSONRequestOperation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96E21604CCCC0000C250 /* AFJSONRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96C81604CCCC0000C250 /* AFJSONRequestOperation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96E31604CCCC0000C250 /* AFJSONRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96C91604CCCC0000C250 /* AFJSONRequestOperation.m */; }; - 259B96E41604CCCC0000C250 /* AFJSONRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96C91604CCCC0000C250 /* AFJSONRequestOperation.m */; }; - 259B96E51604CCCC0000C250 /* AFNetworkActivityIndicatorManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96CA1604CCCC0000C250 /* AFNetworkActivityIndicatorManager.m */; }; - 259B96E61604CCCC0000C250 /* AFNetworkActivityIndicatorManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96CA1604CCCC0000C250 /* AFNetworkActivityIndicatorManager.m */; }; - 259B96E71604CCCC0000C250 /* AFPropertyListRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96CB1604CCCC0000C250 /* AFPropertyListRequestOperation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96E81604CCCC0000C250 /* AFPropertyListRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96CB1604CCCC0000C250 /* AFPropertyListRequestOperation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96E91604CCCC0000C250 /* AFPropertyListRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96CC1604CCCC0000C250 /* AFPropertyListRequestOperation.m */; }; - 259B96EA1604CCCC0000C250 /* AFPropertyListRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96CC1604CCCC0000C250 /* AFPropertyListRequestOperation.m */; }; - 259B96EB1604CCCC0000C250 /* AFURLConnectionOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96CD1604CCCC0000C250 /* AFURLConnectionOperation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96EC1604CCCC0000C250 /* AFURLConnectionOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96CD1604CCCC0000C250 /* AFURLConnectionOperation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96ED1604CCCC0000C250 /* AFURLConnectionOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96CE1604CCCC0000C250 /* AFURLConnectionOperation.m */; }; - 259B96EE1604CCCC0000C250 /* AFURLConnectionOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96CE1604CCCC0000C250 /* AFURLConnectionOperation.m */; }; - 259B96EF1604CCCC0000C250 /* AFXMLRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96CF1604CCCC0000C250 /* AFXMLRequestOperation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96F01604CCCC0000C250 /* AFXMLRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96CF1604CCCC0000C250 /* AFXMLRequestOperation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96F11604CCCC0000C250 /* AFXMLRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96D01604CCCC0000C250 /* AFXMLRequestOperation.m */; }; - 259B96F21604CCCC0000C250 /* AFXMLRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96D01604CCCC0000C250 /* AFXMLRequestOperation.m */; }; - 259B96F31604CCCC0000C250 /* UIImageView+AFNetworking.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96D11604CCCC0000C250 /* UIImageView+AFNetworking.m */; }; - 259B96F41604CCCC0000C250 /* UIImageView+AFNetworking.m in Sources */ = {isa = PBXBuildFile; fileRef = 259B96D11604CCCC0000C250 /* UIImageView+AFNetworking.m */; }; - 259B96F51604CCCC0000C250 /* AFNetworkActivityIndicatorManager.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96D21604CCCC0000C250 /* AFNetworkActivityIndicatorManager.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96F61604CCCC0000C250 /* AFNetworkActivityIndicatorManager.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96D21604CCCC0000C250 /* AFNetworkActivityIndicatorManager.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96F71604CCCC0000C250 /* UIImageView+AFNetworking.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96D31604CCCC0000C250 /* UIImageView+AFNetworking.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96F81604CCCC0000C250 /* UIImageView+AFNetworking.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96D31604CCCC0000C250 /* UIImageView+AFNetworking.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96F91604CCCC0000C250 /* AFNetworking.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96D41604CCCC0000C250 /* AFNetworking.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 259B96FA1604CCCC0000C250 /* AFNetworking.h in Headers */ = {isa = PBXBuildFile; fileRef = 259B96D41604CCCC0000C250 /* AFNetworking.h */; settings = {ATTRIBUTES = (Public, ); }; }; 259D983C154F6C90008C90F5 /* benchmark_parents_and_children.json in Resources */ = {isa = PBXBuildFile; fileRef = 259D983B154F6C90008C90F5 /* benchmark_parents_and_children.json */; }; 259D983D154F6C90008C90F5 /* benchmark_parents_and_children.json in Resources */ = {isa = PBXBuildFile; fileRef = 259D983B154F6C90008C90F5 /* benchmark_parents_and_children.json */; }; 259D98541550C69A008C90F5 /* RKEntityByAttributeCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 259D98521550C69A008C90F5 /* RKEntityByAttributeCache.h */; settings = {ATTRIBUTES = (Public, ); }; }; @@ -510,20 +456,6 @@ 25C20466160ABC4800D418D5 /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 251611281456F50F0060A5C5 /* SystemConfiguration.framework */; }; 25C246A415C83B090032212E /* RKSearchTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 25C246A315C83B090032212E /* RKSearchTest.m */; }; 25C246A515C83B090032212E /* RKSearchTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 25C246A315C83B090032212E /* RKSearchTest.m */; }; - 25C6C0BD1716F6F800C98A73 /* TKEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 25C6C0A51716F6F800C98A73 /* TKEvent.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 25C6C0BE1716F6F800C98A73 /* TKEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 25C6C0A51716F6F800C98A73 /* TKEvent.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 25C6C0BF1716F6F800C98A73 /* TKEvent.m in Sources */ = {isa = PBXBuildFile; fileRef = 25C6C0A61716F6F800C98A73 /* TKEvent.m */; }; - 25C6C0C01716F6F800C98A73 /* TKEvent.m in Sources */ = {isa = PBXBuildFile; fileRef = 25C6C0A61716F6F800C98A73 /* TKEvent.m */; }; - 25C6C0C11716F6F800C98A73 /* TKState.h in Headers */ = {isa = PBXBuildFile; fileRef = 25C6C0A71716F6F800C98A73 /* TKState.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 25C6C0C21716F6F800C98A73 /* TKState.h in Headers */ = {isa = PBXBuildFile; fileRef = 25C6C0A71716F6F800C98A73 /* TKState.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 25C6C0C31716F6F800C98A73 /* TKState.m in Sources */ = {isa = PBXBuildFile; fileRef = 25C6C0A81716F6F800C98A73 /* TKState.m */; }; - 25C6C0C41716F6F800C98A73 /* TKState.m in Sources */ = {isa = PBXBuildFile; fileRef = 25C6C0A81716F6F800C98A73 /* TKState.m */; }; - 25C6C0C51716F6F800C98A73 /* TKStateMachine.h in Headers */ = {isa = PBXBuildFile; fileRef = 25C6C0A91716F6F800C98A73 /* TKStateMachine.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 25C6C0C61716F6F800C98A73 /* TKStateMachine.h in Headers */ = {isa = PBXBuildFile; fileRef = 25C6C0A91716F6F800C98A73 /* TKStateMachine.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 25C6C0C71716F6F800C98A73 /* TKStateMachine.m in Sources */ = {isa = PBXBuildFile; fileRef = 25C6C0AA1716F6F800C98A73 /* TKStateMachine.m */; }; - 25C6C0C81716F6F800C98A73 /* TKStateMachine.m in Sources */ = {isa = PBXBuildFile; fileRef = 25C6C0AA1716F6F800C98A73 /* TKStateMachine.m */; }; - 25C6C0CB1716F6F800C98A73 /* TransitionKit.h in Headers */ = {isa = PBXBuildFile; fileRef = 25C6C0AC1716F6F800C98A73 /* TransitionKit.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 25C6C0CC1716F6F800C98A73 /* TransitionKit.h in Headers */ = {isa = PBXBuildFile; fileRef = 25C6C0AC1716F6F800C98A73 /* TransitionKit.h */; settings = {ATTRIBUTES = (Public, ); }; }; 25C6C0E81716F79B00C98A73 /* RKOperationStateMachine.h in Headers */ = {isa = PBXBuildFile; fileRef = 25C6C0E61716F79B00C98A73 /* RKOperationStateMachine.h */; settings = {ATTRIBUTES = (Public, ); }; }; 25C6C0E91716F79B00C98A73 /* RKOperationStateMachine.h in Headers */ = {isa = PBXBuildFile; fileRef = 25C6C0E61716F79B00C98A73 /* RKOperationStateMachine.h */; settings = {ATTRIBUTES = (Public, ); }; }; 25C6C0EA1716F79B00C98A73 /* RKOperationStateMachine.m in Sources */ = {isa = PBXBuildFile; fileRef = 25C6C0E71716F79B00C98A73 /* RKOperationStateMachine.m */; }; @@ -537,10 +469,6 @@ 25CAAA9515254E7800CAE5D7 /* ArrayOfHumans.json in Resources */ = {isa = PBXBuildFile; fileRef = 25CAAA9315254E7800CAE5D7 /* ArrayOfHumans.json */; }; 25CDA0E7161E828D00F583F3 /* RKISODateFormatterTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 25CDA0E2161E821000F583F3 /* RKISODateFormatterTest.m */; }; 25CDA0E8161E828E00F583F3 /* RKISODateFormatterTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 25CDA0E2161E821000F583F3 /* RKISODateFormatterTest.m */; }; - 25DA356F1836741D001A56A0 /* TKTransition.h in Headers */ = {isa = PBXBuildFile; fileRef = 25DA356D1836741C001A56A0 /* TKTransition.h */; }; - 25DA35701836741D001A56A0 /* TKTransition.h in Headers */ = {isa = PBXBuildFile; fileRef = 25DA356D1836741C001A56A0 /* TKTransition.h */; }; - 25DA35711836741D001A56A0 /* TKTransition.m in Sources */ = {isa = PBXBuildFile; fileRef = 25DA356E1836741C001A56A0 /* TKTransition.m */; }; - 25DA35721836741D001A56A0 /* TKTransition.m in Sources */ = {isa = PBXBuildFile; fileRef = 25DA356E1836741C001A56A0 /* TKTransition.m */; }; 25DB7508151BD551009F01AF /* NSManagedObjectContext+RKAdditionsTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 25DB7507151BD551009F01AF /* NSManagedObjectContext+RKAdditionsTest.m */; }; 25DB7509151BD551009F01AF /* NSManagedObjectContext+RKAdditionsTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 25DB7507151BD551009F01AF /* NSManagedObjectContext+RKAdditionsTest.m */; }; 25E36E0215195CED00F9E448 /* RKFetchRequestMappingCacheTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 25E36E0115195CED00F9E448 /* RKFetchRequestMappingCacheTest.m */; }; @@ -577,6 +505,7 @@ 25FBB853159272DD00955D27 /* RKRouter.h in Headers */ = {isa = PBXBuildFile; fileRef = 25FBB850159272DD00955D27 /* RKRouter.h */; settings = {ATTRIBUTES = (Public, ); }; }; 25FBB854159272DD00955D27 /* RKRouter.m in Sources */ = {isa = PBXBuildFile; fileRef = 25FBB851159272DD00955D27 /* RKRouter.m */; }; 25FBB855159272DD00955D27 /* RKRouter.m in Sources */ = {isa = PBXBuildFile; fileRef = 25FBB851159272DD00955D27 /* RKRouter.m */; }; + 3304DA75F9D62CBBA0F1D286 /* libPods-ios.a in Frameworks */ = {isa = PBXBuildFile; fileRef = DC09A8FD6016D24B797977A1 /* libPods-ios.a */; }; 54CDB45B17B408B100FAC285 /* RKStringTokenizer.h in Headers */ = {isa = PBXBuildFile; fileRef = 54CDB45917B408B100FAC285 /* RKStringTokenizer.h */; settings = {ATTRIBUTES = (Public, ); }; }; 54CDB45C17B408B100FAC285 /* RKStringTokenizer.h in Headers */ = {isa = PBXBuildFile; fileRef = 54CDB45917B408B100FAC285 /* RKStringTokenizer.h */; settings = {ATTRIBUTES = (Public, ); }; }; 54CDB45D17B408B100FAC285 /* RKStringTokenizer.m in Sources */ = {isa = PBXBuildFile; fileRef = 54CDB45A17B408B100FAC285 /* RKStringTokenizer.m */; }; @@ -591,6 +520,7 @@ 5C927E151608FFFD00DC8B07 /* RKDictionaryUtilitiesTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 5C927E131608FFFD00DC8B07 /* RKDictionaryUtilitiesTest.m */; }; 5CCC295615B7124A0045F0F5 /* RKMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = 5CCC295515B7124A0045F0F5 /* RKMacros.h */; settings = {ATTRIBUTES = (Public, ); }; }; 5CCC295715B7124A0045F0F5 /* RKMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = 5CCC295515B7124A0045F0F5 /* RKMacros.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 6CEFFA4880A12A78BAA45D14 /* libPods-RestKitFramework.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 9B15BBB1F11B91C32F72DFBF /* libPods-RestKitFramework.a */; }; 73D3907414CA1AE00093E3D6 /* parent.json in Resources */ = {isa = PBXBuildFile; fileRef = 73D3907114CA19F90093E3D6 /* parent.json */; }; 73D3907514CA1AE20093E3D6 /* parent.json in Resources */ = {isa = PBXBuildFile; fileRef = 73D3907114CA19F90093E3D6 /* parent.json */; }; 73D3907614CA1AE60093E3D6 /* child.json in Resources */ = {isa = PBXBuildFile; fileRef = 73D3907314CA1A4A0093E3D6 /* child.json */; }; @@ -598,7 +528,7 @@ 73D3907914CA1DD40093E3D6 /* channels.xml in Resources */ = {isa = PBXBuildFile; fileRef = 73D3907814CA1D710093E3D6 /* channels.xml */; }; 73D3907A14CA1DD50093E3D6 /* channels.xml in Resources */ = {isa = PBXBuildFile; fileRef = 73D3907814CA1D710093E3D6 /* channels.xml */; }; 7AF2905218DF249C009AEB94 /* RKObjectiveCppTest.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2501405215366000004E0466 /* RKObjectiveCppTest.mm */; }; - 7F9CBC6174004E31AEC35813 /* libPods-osx.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 86EC453810D648768BF62304 /* libPods-osx.a */; }; + 80AA296AE84490C074C75E91 /* libPods-osx.a in Frameworks */ = {isa = PBXBuildFile; fileRef = DB867C56C81696C5E9366366 /* libPods-osx.a */; }; 8AB68F0B1AE5B3B300DD655A /* RKFetchedResultsControllerUpdateTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 8AB68F0A1AE5B3B300DD655A /* RKFetchedResultsControllerUpdateTest.m */; }; BE05BDD11782109F00F7C9C9 /* RKRouteTest.m in Sources */ = {isa = PBXBuildFile; fileRef = BE05BDCF1782109F00F7C9C9 /* RKRouteTest.m */; }; BE05BDD2178214AA00F7C9C9 /* RKRouteTest.m in Sources */ = {isa = PBXBuildFile; fileRef = BE05BDCF1782109F00F7C9C9 /* RKRouteTest.m */; }; @@ -612,7 +542,7 @@ DB1148451A0B26B100C8A00A /* RKLumberjackLogger.h in Headers */ = {isa = PBXBuildFile; fileRef = DB1148421A0B26B100C8A00A /* RKLumberjackLogger.h */; settings = {ATTRIBUTES = (Public, ); }; }; DB1148461A0B26B100C8A00A /* RKLumberjackLogger.m in Sources */ = {isa = PBXBuildFile; fileRef = DB1148431A0B26B100C8A00A /* RKLumberjackLogger.m */; }; DB1148471A0B26B100C8A00A /* RKLumberjackLogger.m in Sources */ = {isa = PBXBuildFile; fileRef = DB1148431A0B26B100C8A00A /* RKLumberjackLogger.m */; }; - E2F2B89961FC462B981CEB7A /* libPods-ios.a in Frameworks */ = {isa = PBXBuildFile; fileRef = E457EFC3D502479D8B4FCF2A /* libPods-ios.a */; }; + FFD7948D0AE44A4290977909 /* libPods-RestKit.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5EA1EF52129B3341280753E4 /* libPods-RestKit.a */; }; /* End PBXBuildFile section */ /* Begin PBXContainerItemProxy section */ @@ -645,9 +575,8 @@ /* End PBXCopyFilesBuildPhase section */ /* Begin PBXFileReference section */ - 04D69B4B2A54475834B333CF /* Pods-osx.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-osx.release.xcconfig"; path = "Pods/Target Support Files/Pods-osx/Pods-osx.release.xcconfig"; sourceTree = ""; }; - 061E3E4524CE8EF78257C26C /* Pods-ios.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ios.release.xcconfig"; path = "Pods/Target Support Files/Pods-ios/Pods-ios.release.xcconfig"; sourceTree = ""; }; - 147F950728350A64F103F55D /* Pods-ios.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ios.debug.xcconfig"; path = "Pods/Target Support Files/Pods-ios/Pods-ios.debug.xcconfig"; sourceTree = ""; }; + 0B096CE4874E766ECE78D229 /* Pods-ios.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ios.debug.xcconfig"; path = "Pods/Target Support Files/Pods-ios/Pods-ios.debug.xcconfig"; sourceTree = ""; }; + 1ABDEC386A27292EF883B0BE /* Pods-RestKitFramework.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RestKitFramework.release.xcconfig"; path = "Pods/Target Support Files/Pods-RestKitFramework/Pods-RestKitFramework.release.xcconfig"; sourceTree = ""; }; 2501405215366000004E0466 /* RKObjectiveCppTest.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = RKObjectiveCppTest.mm; sourceTree = ""; }; 2502C8E715F79CF70060FD75 /* CoreData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CoreData.h; sourceTree = ""; }; 2502C8E815F79CF70060FD75 /* Network.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Network.h; sourceTree = ""; }; @@ -728,8 +657,6 @@ 25160EA21456532C0060A5C5 /* lcl_RK.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = lcl_RK.h; sourceTree = ""; }; 25160EA31456532C0060A5C5 /* lcl_RK.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = lcl_RK.m; sourceTree = ""; }; 25160EA71456532C0060A5C5 /* README.md */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = README.md; sourceTree = ""; }; - 25160EBD1456532C0060A5C5 /* SOCKit.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SOCKit.h; sourceTree = ""; }; - 25160EBE1456532C0060A5C5 /* SOCKit.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SOCKit.m; sourceTree = ""; }; 25160F161456538B0060A5C5 /* libxml2.dylib */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "compiled.mach-o.dylib"; name = libxml2.dylib; path = usr/lib/libxml2.dylib; sourceTree = SDKROOT; }; 25160F7B145657220060A5C5 /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = SDKs/MacOSX10.7.sdk/System/Library/Frameworks/SystemConfiguration.framework; sourceTree = DEVELOPER_DIR; }; 25160F7D1456572F0060A5C5 /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = SDKs/MacOSX10.7.sdk/System/Library/Frameworks/Cocoa.framework; sourceTree = DEVELOPER_DIR; }; @@ -817,12 +744,6 @@ 252029021577AE1800076FB4 /* RKRoute.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKRoute.m; sourceTree = ""; }; 252029081577C78600076FB4 /* RKRouteSetTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKRouteSetTest.m; sourceTree = ""; }; 252205CB162B242400F7B11E /* RKHTTPUtilitiesTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKHTTPUtilitiesTest.m; sourceTree = ""; }; - 252CCE6017E08E2D00B7F0BF /* RKValueTransformers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKValueTransformers.h; sourceTree = ""; }; - 252CCE6117E08E2D00B7F0BF /* RKValueTransformers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKValueTransformers.m; sourceTree = ""; }; - 252CCE6E17E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ISO8601DateFormatterValueTransformer.h; sourceTree = ""; }; - 252CCE6F17E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ISO8601DateFormatterValueTransformer.m; sourceTree = ""; }; - 252CCE7017E0CA2700B7F0BF /* RKISO8601DateFormatter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKISO8601DateFormatter.h; sourceTree = ""; }; - 252CCE7117E0CA2700B7F0BF /* RKISO8601DateFormatter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKISO8601DateFormatter.m; sourceTree = ""; }; 252EFAF814D8EAEC004863C8 /* RKEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKEvent.h; sourceTree = ""; }; 252EFAF914D8EAEC004863C8 /* RKEvent.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKEvent.m; sourceTree = ""; }; 252EFAFC14D8EB30004863C8 /* RKTestNotificationObserver.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RKTestNotificationObserver.h; path = Testing/RKTestNotificationObserver.h; sourceTree = ""; }; @@ -884,25 +805,6 @@ 2598888B15EC169E006CAE95 /* RKPropertyMapping.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKPropertyMapping.h; sourceTree = ""; }; 2598888C15EC169E006CAE95 /* RKPropertyMapping.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKPropertyMapping.m; sourceTree = ""; }; 259AC480162B05C80012D2F9 /* RKObjectRequestOperationTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKObjectRequestOperationTest.m; sourceTree = ""; }; - 259B96C21604CCCC0000C250 /* AFHTTPClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFHTTPClient.h; sourceTree = ""; }; - 259B96C31604CCCC0000C250 /* AFHTTPClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFHTTPClient.m; sourceTree = ""; }; - 259B96C41604CCCC0000C250 /* AFHTTPRequestOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFHTTPRequestOperation.h; sourceTree = ""; }; - 259B96C51604CCCC0000C250 /* AFHTTPRequestOperation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFHTTPRequestOperation.m; sourceTree = ""; }; - 259B96C61604CCCC0000C250 /* AFImageRequestOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFImageRequestOperation.h; sourceTree = ""; }; - 259B96C71604CCCC0000C250 /* AFImageRequestOperation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFImageRequestOperation.m; sourceTree = ""; }; - 259B96C81604CCCC0000C250 /* AFJSONRequestOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFJSONRequestOperation.h; sourceTree = ""; }; - 259B96C91604CCCC0000C250 /* AFJSONRequestOperation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFJSONRequestOperation.m; sourceTree = ""; }; - 259B96CA1604CCCC0000C250 /* AFNetworkActivityIndicatorManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFNetworkActivityIndicatorManager.m; sourceTree = ""; }; - 259B96CB1604CCCC0000C250 /* AFPropertyListRequestOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFPropertyListRequestOperation.h; sourceTree = ""; }; - 259B96CC1604CCCC0000C250 /* AFPropertyListRequestOperation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFPropertyListRequestOperation.m; sourceTree = ""; }; - 259B96CD1604CCCC0000C250 /* AFURLConnectionOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFURLConnectionOperation.h; sourceTree = ""; }; - 259B96CE1604CCCC0000C250 /* AFURLConnectionOperation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFURLConnectionOperation.m; sourceTree = ""; }; - 259B96CF1604CCCC0000C250 /* AFXMLRequestOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFXMLRequestOperation.h; sourceTree = ""; }; - 259B96D01604CCCC0000C250 /* AFXMLRequestOperation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFXMLRequestOperation.m; sourceTree = ""; }; - 259B96D11604CCCC0000C250 /* UIImageView+AFNetworking.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIImageView+AFNetworking.m"; sourceTree = ""; }; - 259B96D21604CCCC0000C250 /* AFNetworkActivityIndicatorManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFNetworkActivityIndicatorManager.h; sourceTree = ""; }; - 259B96D31604CCCC0000C250 /* UIImageView+AFNetworking.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIImageView+AFNetworking.h"; sourceTree = ""; }; - 259B96D41604CCCC0000C250 /* AFNetworking.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFNetworking.h; sourceTree = ""; }; 259D983B154F6C90008C90F5 /* benchmark_parents_and_children.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = benchmark_parents_and_children.json; sourceTree = ""; }; 259D98521550C69A008C90F5 /* RKEntityByAttributeCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKEntityByAttributeCache.h; sourceTree = ""; }; 259D98531550C69A008C90F5 /* RKEntityByAttributeCache.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKEntityByAttributeCache.m; sourceTree = ""; }; @@ -942,13 +844,6 @@ 25B6EA0714CF947D00B1E881 /* CoreGraphics.framework */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; }; 25BB392D161F4FD700E5C72A /* RKPathUtilitiesTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKPathUtilitiesTest.m; sourceTree = ""; }; 25C246A315C83B090032212E /* RKSearchTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKSearchTest.m; sourceTree = ""; }; - 25C6C0A51716F6F800C98A73 /* TKEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TKEvent.h; path = Code/TKEvent.h; sourceTree = ""; }; - 25C6C0A61716F6F800C98A73 /* TKEvent.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = TKEvent.m; path = Code/TKEvent.m; sourceTree = ""; }; - 25C6C0A71716F6F800C98A73 /* TKState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TKState.h; path = Code/TKState.h; sourceTree = ""; }; - 25C6C0A81716F6F800C98A73 /* TKState.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = TKState.m; path = Code/TKState.m; sourceTree = ""; }; - 25C6C0A91716F6F800C98A73 /* TKStateMachine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TKStateMachine.h; path = Code/TKStateMachine.h; sourceTree = ""; }; - 25C6C0AA1716F6F800C98A73 /* TKStateMachine.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = TKStateMachine.m; path = Code/TKStateMachine.m; sourceTree = ""; }; - 25C6C0AC1716F6F800C98A73 /* TransitionKit.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TransitionKit.h; path = Code/TransitionKit.h; sourceTree = ""; }; 25C6C0E61716F79B00C98A73 /* RKOperationStateMachine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKOperationStateMachine.h; sourceTree = ""; }; 25C6C0E71716F79B00C98A73 /* RKOperationStateMachine.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKOperationStateMachine.m; sourceTree = ""; }; 25C954A415542A47005C9E08 /* RKTestConstants.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = RKTestConstants.m; path = Testing/RKTestConstants.m; sourceTree = ""; }; @@ -956,8 +851,6 @@ 25CAAA9315254E7800CAE5D7 /* ArrayOfHumans.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = ArrayOfHumans.json; sourceTree = ""; }; 25CC5C58161DDADD0008BD21 /* RKResponseDescriptorTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKResponseDescriptorTest.m; sourceTree = ""; }; 25CDA0E2161E821000F583F3 /* RKISODateFormatterTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKISODateFormatterTest.m; sourceTree = ""; }; - 25DA356D1836741C001A56A0 /* TKTransition.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TKTransition.h; path = Code/TKTransition.h; sourceTree = ""; }; - 25DA356E1836741C001A56A0 /* TKTransition.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = TKTransition.m; path = Code/TKTransition.m; sourceTree = ""; }; 25DB7507151BD551009F01AF /* NSManagedObjectContext+RKAdditionsTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSManagedObjectContext+RKAdditionsTest.m"; sourceTree = ""; }; 25E36E0115195CED00F9E448 /* RKFetchRequestMappingCacheTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKFetchRequestMappingCacheTest.m; sourceTree = ""; }; 25E88C86165C5CC30042ABD0 /* RKConnectionDescription.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKConnectionDescription.h; sourceTree = ""; }; @@ -981,6 +874,7 @@ 5910B0BD1AC9A23E00721876 /* catsWithParent_issue_2194.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = catsWithParent_issue_2194.json; sourceTree = ""; }; 5C927E131608FFFD00DC8B07 /* RKDictionaryUtilitiesTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKDictionaryUtilitiesTest.m; sourceTree = ""; }; 5CCC295515B7124A0045F0F5 /* RKMacros.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKMacros.h; sourceTree = ""; }; + 5EA1EF52129B3341280753E4 /* libPods-RestKit.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-RestKit.a"; sourceTree = BUILT_PRODUCTS_DIR; }; 7394DF3514CF157A00CE7BCE /* RKManagedObjectCaching.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKManagedObjectCaching.h; sourceTree = ""; }; 7394DF3814CF168C00CE7BCE /* RKFetchRequestManagedObjectCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKFetchRequestManagedObjectCache.h; sourceTree = ""; }; 7394DF3914CF168C00CE7BCE /* RKFetchRequestManagedObjectCache.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKFetchRequestManagedObjectCache.m; sourceTree = ""; }; @@ -989,17 +883,23 @@ 73D3907114CA19F90093E3D6 /* parent.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = parent.json; sourceTree = ""; }; 73D3907314CA1A4A0093E3D6 /* child.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = child.json; sourceTree = ""; }; 73D3907814CA1D710093E3D6 /* channels.xml */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = channels.xml; sourceTree = ""; }; - 86EC453810D648768BF62304 /* libPods-osx.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-osx.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + 9B15BBB1F11B91C32F72DFBF /* libPods-RestKitFramework.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-RestKitFramework.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + A339C3AFD7C094BEAFE92A93 /* Pods-ios.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ios.release.xcconfig"; path = "Pods/Target Support Files/Pods-ios/Pods-ios.release.xcconfig"; sourceTree = ""; }; + A920AEDAEC3C6599433D2720 /* Pods-osx.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-osx.debug.xcconfig"; path = "Pods/Target Support Files/Pods-osx/Pods-osx.debug.xcconfig"; sourceTree = ""; }; + AD144E244684975F290D70ED /* Pods-RestKit.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RestKit.release.xcconfig"; path = "Pods/Target Support Files/Pods-RestKit/Pods-RestKit.release.xcconfig"; sourceTree = ""; }; + AD2DD8D9C9EA769B53865C88 /* Pods-RestKit.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RestKit.debug.xcconfig"; path = "Pods/Target Support Files/Pods-RestKit/Pods-RestKit.debug.xcconfig"; sourceTree = ""; }; 8AB68F0A1AE5B3B300DD655A /* RKFetchedResultsControllerUpdateTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKFetchedResultsControllerUpdateTest.m; sourceTree = ""; }; BE05BDCF1782109F00F7C9C9 /* RKRouteTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKRouteTest.m; sourceTree = ""; }; C0F11CE1190883380054AEA0 /* RKPathMatcher.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKPathMatcher.h; sourceTree = ""; }; C0F11CE2190883380054AEA0 /* RKPathMatcher.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKPathMatcher.m; sourceTree = ""; }; C0F11CE71908C7E60054AEA0 /* RKCoreData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKCoreData.h; sourceTree = ""; }; - D8EFCBE1978F7946E0081FAD /* Pods-osx.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-osx.debug.xcconfig"; path = "Pods/Target Support Files/Pods-osx/Pods-osx.debug.xcconfig"; sourceTree = ""; }; + C5608EB544CBB19BBACC13BA /* Pods-RestKitFramework.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RestKitFramework.debug.xcconfig"; path = "Pods/Target Support Files/Pods-RestKitFramework/Pods-RestKitFramework.debug.xcconfig"; sourceTree = ""; }; DB1148421A0B26B100C8A00A /* RKLumberjackLogger.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKLumberjackLogger.h; sourceTree = ""; }; DB1148431A0B26B100C8A00A /* RKLumberjackLogger.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKLumberjackLogger.m; sourceTree = ""; }; - E457EFC3D502479D8B4FCF2A /* libPods-ios.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-ios.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + DB867C56C81696C5E9366366 /* libPods-osx.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-osx.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + DC09A8FD6016D24B797977A1 /* libPods-ios.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-ios.a"; sourceTree = BUILT_PRODUCTS_DIR; }; F66056291744FF9000A87A45 /* and_cats.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = and_cats.json; sourceTree = ""; }; + F6B428543BF5CF359F239FE1 /* Pods-osx.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-osx.release.xcconfig"; path = "Pods/Target Support Files/Pods-osx/Pods-osx.release.xcconfig"; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -1009,6 +909,7 @@ files = ( 25C20466160ABC4800D418D5 /* SystemConfiguration.framework in Frameworks */, 25160D1A14564E810060A5C5 /* Foundation.framework in Frameworks */, + FFD7948D0AE44A4290977909 /* libPods-RestKit.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -1026,7 +927,7 @@ 251611291456F50F0060A5C5 /* SystemConfiguration.framework in Frameworks */, 25160D2A14564E820060A5C5 /* UIKit.framework in Frameworks */, 25160D2B14564E820060A5C5 /* Foundation.framework in Frameworks */, - E2F2B89961FC462B981CEB7A /* libPods-ios.a in Frameworks */, + 3304DA75F9D62CBBA0F1D286 /* libPods-ios.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -1037,6 +938,7 @@ 25A34245147D8AAA0009758D /* Security.framework in Frameworks */, 25160F7E145657300060A5C5 /* Cocoa.framework in Frameworks */, 25160F7C145657220060A5C5 /* SystemConfiguration.framework in Frameworks */, + 6CEFFA4880A12A78BAA45D14 /* libPods-RestKitFramework.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -1047,20 +949,24 @@ 25565959161FC3CD00F5BB20 /* SystemConfiguration.framework in Frameworks */, 25565956161FC3C300F5BB20 /* CoreServices.framework in Frameworks */, 25160E7A145651060060A5C5 /* Cocoa.framework in Frameworks */, - 7F9CBC6174004E31AEC35813 /* libPods-osx.a in Frameworks */, + 80AA296AE84490C074C75E91 /* libPods-osx.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXFrameworksBuildPhase section */ /* Begin PBXGroup section */ - 15BB5BBD8E8B9B2C9C8B11BC /* Pods */ = { + 21C3ABBAD1E23EF5D671E158 /* Pods */ = { isa = PBXGroup; children = ( - 147F950728350A64F103F55D /* Pods-ios.debug.xcconfig */, - 061E3E4524CE8EF78257C26C /* Pods-ios.release.xcconfig */, - D8EFCBE1978F7946E0081FAD /* Pods-osx.debug.xcconfig */, - 04D69B4B2A54475834B333CF /* Pods-osx.release.xcconfig */, + AD2DD8D9C9EA769B53865C88 /* Pods-RestKit.debug.xcconfig */, + AD144E244684975F290D70ED /* Pods-RestKit.release.xcconfig */, + C5608EB544CBB19BBACC13BA /* Pods-RestKitFramework.debug.xcconfig */, + 1ABDEC386A27292EF883B0BE /* Pods-RestKitFramework.release.xcconfig */, + 0B096CE4874E766ECE78D229 /* Pods-ios.debug.xcconfig */, + A339C3AFD7C094BEAFE92A93 /* Pods-ios.release.xcconfig */, + A920AEDAEC3C6599433D2720 /* Pods-osx.debug.xcconfig */, + F6B428543BF5CF359F239FE1 /* Pods-osx.release.xcconfig */, ); name = Pods; sourceTree = ""; @@ -1101,7 +1007,7 @@ 25160E8D145652E40060A5C5 /* Vendor */, 25160D1814564E810060A5C5 /* Frameworks */, 25160D1714564E810060A5C5 /* Products */, - 15BB5BBD8E8B9B2C9C8B11BC /* Pods */, + 21C3ABBAD1E23EF5D671E158 /* Pods */, ); sourceTree = ""; }; @@ -1137,8 +1043,10 @@ 25160E63145651060060A5C5 /* Cocoa.framework */, 25EC1B0014F8078100C3CF3F /* CoreFoundation.framework */, 25160E65145651060060A5C5 /* Other Frameworks */, - E457EFC3D502479D8B4FCF2A /* libPods-ios.a */, - 86EC453810D648768BF62304 /* libPods-osx.a */, + 5EA1EF52129B3341280753E4 /* libPods-RestKit.a */, + 9B15BBB1F11B91C32F72DFBF /* libPods-RestKitFramework.a */, + DC09A8FD6016D24B797977A1 /* libPods-ios.a */, + DB867C56C81696C5E9366366 /* libPods-osx.a */, ); name = Frameworks; sourceTree = ""; @@ -1292,12 +1200,7 @@ 25160E8D145652E40060A5C5 /* Vendor */ = { isa = PBXGroup; children = ( - 252CCE6D17E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer */, - 252CCE5D17E08E2D00B7F0BF /* RKValueTransformers */, - 25C6C0A21716F6F800C98A73 /* TransitionKit */, - 25BCB31715ED57D500EE84DD /* AFNetworking */, 25160EA01456532C0060A5C5 /* LibComponentLogging */, - 25160EB71456532C0060A5C5 /* SOCKit */, ); path = Vendor; sourceTree = ""; @@ -1320,15 +1223,6 @@ path = Core; sourceTree = ""; }; - 25160EB71456532C0060A5C5 /* SOCKit */ = { - isa = PBXGroup; - children = ( - 25160EBD1456532C0060A5C5 /* SOCKit.h */, - 25160EBE1456532C0060A5C5 /* SOCKit.m */, - ); - path = SOCKit; - sourceTree = ""; - }; 25160FC51456F2330060A5C5 /* Tests */ = { isa = PBXGroup; children = ( @@ -1585,28 +1479,6 @@ path = Logic/Support; sourceTree = ""; }; - 252CCE5D17E08E2D00B7F0BF /* RKValueTransformers */ = { - isa = PBXGroup; - children = ( - 252CCE6017E08E2D00B7F0BF /* RKValueTransformers.h */, - 252CCE6117E08E2D00B7F0BF /* RKValueTransformers.m */, - ); - name = RKValueTransformers; - path = RKValueTransformers/Code; - sourceTree = ""; - }; - 252CCE6D17E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer */ = { - isa = PBXGroup; - children = ( - 252CCE6E17E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.h */, - 252CCE6F17E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.m */, - 252CCE7017E0CA2700B7F0BF /* RKISO8601DateFormatter.h */, - 252CCE7117E0CA2700B7F0BF /* RKISO8601DateFormatter.m */, - ); - name = ISO8601DateFormatterValueTransformer; - path = ISO8601DateFormatterValueTransformer/Code; - sourceTree = ""; - }; 252EFB1F14D9A8D4004863C8 /* Testing */ = { isa = PBXGroup; children = ( @@ -1640,49 +1512,6 @@ path = Logic/Testing; sourceTree = ""; }; - 25BCB31715ED57D500EE84DD /* AFNetworking */ = { - isa = PBXGroup; - children = ( - 259B96C21604CCCC0000C250 /* AFHTTPClient.h */, - 259B96C31604CCCC0000C250 /* AFHTTPClient.m */, - 259B96C41604CCCC0000C250 /* AFHTTPRequestOperation.h */, - 259B96C51604CCCC0000C250 /* AFHTTPRequestOperation.m */, - 259B96C61604CCCC0000C250 /* AFImageRequestOperation.h */, - 259B96C71604CCCC0000C250 /* AFImageRequestOperation.m */, - 259B96C81604CCCC0000C250 /* AFJSONRequestOperation.h */, - 259B96C91604CCCC0000C250 /* AFJSONRequestOperation.m */, - 259B96CA1604CCCC0000C250 /* AFNetworkActivityIndicatorManager.m */, - 259B96CB1604CCCC0000C250 /* AFPropertyListRequestOperation.h */, - 259B96CC1604CCCC0000C250 /* AFPropertyListRequestOperation.m */, - 259B96CD1604CCCC0000C250 /* AFURLConnectionOperation.h */, - 259B96CE1604CCCC0000C250 /* AFURLConnectionOperation.m */, - 259B96CF1604CCCC0000C250 /* AFXMLRequestOperation.h */, - 259B96D01604CCCC0000C250 /* AFXMLRequestOperation.m */, - 259B96D11604CCCC0000C250 /* UIImageView+AFNetworking.m */, - 259B96D21604CCCC0000C250 /* AFNetworkActivityIndicatorManager.h */, - 259B96D31604CCCC0000C250 /* UIImageView+AFNetworking.h */, - 259B96D41604CCCC0000C250 /* AFNetworking.h */, - ); - name = AFNetworking; - path = AFNetworking/AFNetworking; - sourceTree = ""; - }; - 25C6C0A21716F6F800C98A73 /* TransitionKit */ = { - isa = PBXGroup; - children = ( - 25DA356D1836741C001A56A0 /* TKTransition.h */, - 25DA356E1836741C001A56A0 /* TKTransition.m */, - 25C6C0A51716F6F800C98A73 /* TKEvent.h */, - 25C6C0A61716F6F800C98A73 /* TKEvent.m */, - 25C6C0A71716F6F800C98A73 /* TKState.h */, - 25C6C0A81716F6F800C98A73 /* TKState.m */, - 25C6C0A91716F6F800C98A73 /* TKStateMachine.h */, - 25C6C0AA1716F6F800C98A73 /* TKStateMachine.m */, - 25C6C0AC1716F6F800C98A73 /* TransitionKit.h */, - ); - path = TransitionKit; - sourceTree = ""; - }; 25EC1AD614F8022600C3CF3F /* Resources */ = { isa = PBXGroup; children = ( @@ -1802,7 +1631,6 @@ 25160DE5145650490060A5C5 /* RKPropertyInspector+CoreData.h in Headers */, 25160E09145650490060A5C5 /* RKDynamicMapping.h in Headers */, 25160E0B145650490060A5C5 /* RKErrorMessage.h in Headers */, - 252CCE7217E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.h in Headers */, 25160E0F145650490060A5C5 /* RKAttributeMapping.h in Headers */, 25160E16145650490060A5C5 /* RKMapperOperation.h in Headers */, DB1148441A0B26B100C8A00A /* RKLumberjackLogger.h in Headers */, @@ -1819,11 +1647,9 @@ 25160E44145650490060A5C5 /* RestKit-Prefix.pch in Headers */, 25160E47145650490060A5C5 /* RKDotNetDateFormatter.h in Headers */, 25160E4A145650490060A5C5 /* RKLog.h in Headers */, - 252CCE7617E0CA2700B7F0BF /* RKISO8601DateFormatter.h in Headers */, 25160E4C145650490060A5C5 /* RKMIMETypes.h in Headers */, 25160E4E145650490060A5C5 /* RKSerialization.h in Headers */, 25160EE21456532C0060A5C5 /* lcl_RK.h in Headers */, - 25160F081456532C0060A5C5 /* SOCKit.h in Headers */, 25160E2E145650490060A5C5 /* RestKit.h in Headers */, 25B408261491CDDC00F21111 /* RKPathUtilities.h in Headers */, 25B6E95514CF795D00B1E881 /* RKErrors.h in Headers */, @@ -1875,31 +1701,15 @@ 2502C8F715F79CF70060FD75 /* Testing.h in Headers */, 2534781815FFD4A6002C0E4E /* RKURLEncodedSerialization.h in Headers */, 253477F115FFBC61002C0E4E /* RKDictionaryUtilities.h in Headers */, - 259B96D51604CCCC0000C250 /* AFHTTPClient.h in Headers */, - 259B96D91604CCCC0000C250 /* AFHTTPRequestOperation.h in Headers */, - 259B96DD1604CCCC0000C250 /* AFImageRequestOperation.h in Headers */, - 259B96E11604CCCC0000C250 /* AFJSONRequestOperation.h in Headers */, - 259B96E71604CCCC0000C250 /* AFPropertyListRequestOperation.h in Headers */, - 259B96EB1604CCCC0000C250 /* AFURLConnectionOperation.h in Headers */, - 259B96EF1604CCCC0000C250 /* AFXMLRequestOperation.h in Headers */, - 259B96F51604CCCC0000C250 /* AFNetworkActivityIndicatorManager.h in Headers */, - 259B96F71604CCCC0000C250 /* UIImageView+AFNetworking.h in Headers */, - 259B96F91604CCCC0000C250 /* AFNetworking.h in Headers */, 25F53F391606269400A093BE /* RKObjectRequestOperationSubclass.h in Headers */, 25A226D61618A57500952D72 /* RKObjectUtilities.h in Headers */, C0F11CE3190883380054AEA0 /* RKPathMatcher.h in Headers */, - 252CCE6617E08E2D00B7F0BF /* RKValueTransformers.h in Headers */, 2507C327161BD5C700EA71FF /* RKTestHelpers.h in Headers */, C0F11CE81908C7E60054AEA0 /* RKCoreData.h in Headers */, 25E88C88165C5CC30042ABD0 /* RKConnectionDescription.h in Headers */, 25A8C2341673BD480014D9A6 /* RKConnectionTestExpectation.h in Headers */, 25A199D416ED035A00792629 /* RKBenchmark.h in Headers */, - 25C6C0BD1716F6F800C98A73 /* TKEvent.h in Headers */, - 25C6C0C11716F6F800C98A73 /* TKState.h in Headers */, - 25C6C0C51716F6F800C98A73 /* TKStateMachine.h in Headers */, - 25C6C0CB1716F6F800C98A73 /* TransitionKit.h in Headers */, 25C6C0E81716F79B00C98A73 /* RKOperationStateMachine.h in Headers */, - 25DA356F1836741D001A56A0 /* TKTransition.h in Headers */, 54CDB45B17B408B100FAC285 /* RKStringTokenizer.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; @@ -1909,11 +1719,9 @@ buildActionMask = 2147483647; files = ( 25160EE31456532C0060A5C5 /* lcl_RK.h in Headers */, - 25160F091456532C0060A5C5 /* SOCKit.h in Headers */, 25160F44145655C60060A5C5 /* RKDynamicMapping.h in Headers */, 25160F46145655C60060A5C5 /* RKErrorMessage.h in Headers */, 25160F4A145655C60060A5C5 /* RKAttributeMapping.h in Headers */, - 252CCE7317E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.h in Headers */, 25160F51145655C60060A5C5 /* RKMapperOperation.h in Headers */, 25160F53145655C60060A5C5 /* RKMapperOperation_Private.h in Headers */, DB1148451A0B26B100C8A00A /* RKLumberjackLogger.h in Headers */, @@ -1930,7 +1738,6 @@ 25160F85145657650060A5C5 /* lcl_config_components_RK.h in Headers */, 25160F86145657650060A5C5 /* lcl_config_extensions_RK.h in Headers */, 25160F87145657650060A5C5 /* lcl_config_logger_RK.h in Headers */, - 252CCE7717E0CA2700B7F0BF /* RKISO8601DateFormatter.h in Headers */, 25160F901456576C0060A5C5 /* RKDotNetDateFormatter.h in Headers */, 25160F931456576C0060A5C5 /* RKLog.h in Headers */, 25160F951456576C0060A5C5 /* RKMIMETypes.h in Headers */, @@ -1985,33 +1792,17 @@ 2502C8F815F79CF70060FD75 /* Testing.h in Headers */, 253477F215FFBC61002C0E4E /* RKDictionaryUtilities.h in Headers */, 2534781915FFD4A6002C0E4E /* RKURLEncodedSerialization.h in Headers */, - 259B96D61604CCCC0000C250 /* AFHTTPClient.h in Headers */, - 259B96DA1604CCCC0000C250 /* AFHTTPRequestOperation.h in Headers */, - 259B96DE1604CCCC0000C250 /* AFImageRequestOperation.h in Headers */, - 259B96E21604CCCC0000C250 /* AFJSONRequestOperation.h in Headers */, - 259B96E81604CCCC0000C250 /* AFPropertyListRequestOperation.h in Headers */, - 259B96EC1604CCCC0000C250 /* AFURLConnectionOperation.h in Headers */, - 259B96F01604CCCC0000C250 /* AFXMLRequestOperation.h in Headers */, - 259B96F61604CCCC0000C250 /* AFNetworkActivityIndicatorManager.h in Headers */, - 259B96F81604CCCC0000C250 /* UIImageView+AFNetworking.h in Headers */, - 259B96FA1604CCCC0000C250 /* AFNetworking.h in Headers */, 25F53F3A1606269400A093BE /* RKObjectRequestOperationSubclass.h in Headers */, 25A226D71618A57500952D72 /* RKObjectUtilities.h in Headers */, 2507C328161BD5C700EA71FF /* RKTestHelpers.h in Headers */, 25E88C89165C5CC30042ABD0 /* RKConnectionDescription.h in Headers */, - 252CCE6717E08E2D00B7F0BF /* RKValueTransformers.h in Headers */, C0F11CE5190883460054AEA0 /* RKPathMatcher.h in Headers */, 255893E3166BA6A20010C70B /* RKObjectParameterization.h in Headers */, 255893E4166BA7400010C70B /* RestKit-Prefix.pch in Headers */, 255893E5166BA7700010C70B /* RKTestFixture.h in Headers */, 25A8C2351673BD480014D9A6 /* RKConnectionTestExpectation.h in Headers */, 25A199D516ED035A00792629 /* RKBenchmark.h in Headers */, - 25C6C0BE1716F6F800C98A73 /* TKEvent.h in Headers */, - 25C6C0C21716F6F800C98A73 /* TKState.h in Headers */, - 25C6C0C61716F6F800C98A73 /* TKStateMachine.h in Headers */, - 25C6C0CC1716F6F800C98A73 /* TransitionKit.h in Headers */, 25C6C0E91716F79B00C98A73 /* RKOperationStateMachine.h in Headers */, - 25DA35701836741D001A56A0 /* TKTransition.h in Headers */, 54CDB45C17B408B100FAC285 /* RKStringTokenizer.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; @@ -2023,9 +1814,11 @@ isa = PBXNativeTarget; buildConfigurationList = 25160D3A14564E820060A5C5 /* Build configuration list for PBXNativeTarget "RestKit" */; buildPhases = ( + 1EC288EEF46DC7EC455B012C /* Check Pods Manifest.lock */, 25160D1214564E810060A5C5 /* Sources */, 25160D1314564E810060A5C5 /* Frameworks */, 25160D1414564E810060A5C5 /* Headers */, + F6534AD38F03B29013ACBE7E /* Copy Pods Resources */, ); buildRules = ( ); @@ -2040,11 +1833,12 @@ isa = PBXNativeTarget; buildConfigurationList = 25160D3D14564E820060A5C5 /* Build configuration list for PBXNativeTarget "RestKitTests" */; buildPhases = ( + 31E61254417653D2A601DDF8 /* Check Pods Manifest.lock */, 25160D2114564E820060A5C5 /* Sources */, 25160D2214564E820060A5C5 /* Frameworks */, 25160D2314564E820060A5C5 /* Resources */, - 212C92B936E847348494D6F7 /* Copy Pods Resources */, 25160D2414564E820060A5C5 /* ShellScript */, + D00A58B091EC84A57A1FB098 /* Copy Pods Resources */, ); buildRules = ( ); @@ -2060,10 +1854,12 @@ isa = PBXNativeTarget; buildConfigurationList = 25160E87145651060060A5C5 /* Build configuration list for PBXNativeTarget "RestKitFramework" */; buildPhases = ( + A7AA769D655643D4F1E58C8C /* Check Pods Manifest.lock */, 25160E5D145651060060A5C5 /* Sources */, 25160E5E145651060060A5C5 /* Frameworks */, 25160E5F145651060060A5C5 /* Headers */, 25160E60145651060060A5C5 /* Resources */, + 8F48B45166853D07B6229593 /* Copy Pods Resources */, ); buildRules = ( ); @@ -2078,12 +1874,13 @@ isa = PBXNativeTarget; buildConfigurationList = 25160E8A145651060060A5C5 /* Build configuration list for PBXNativeTarget "RestKitFrameworkTests" */; buildPhases = ( + 6A5C656B4979C48B2EE74B1A /* Check Pods Manifest.lock */, 25160E73145651060060A5C5 /* Sources */, 25160E74145651060060A5C5 /* Frameworks */, 25160E75145651060060A5C5 /* Resources */, 250CA67F147D8EEC0047D347 /* CopyFiles */, - 0779C6DD2283438BA5EAB1FB /* Copy Pods Resources */, 25160E76145651060060A5C5 /* ShellScript */, + D9DDA304517443E2F6FD2B2C /* Copy Pods Resources */, ); buildRules = ( ); @@ -2230,7 +2027,78 @@ /* End PBXResourcesBuildPhase section */ /* Begin PBXShellScriptBuildPhase section */ - 0779C6DD2283438BA5EAB1FB /* Copy Pods Resources */ = { + 1EC288EEF46DC7EC455B012C /* Check Pods Manifest.lock */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Check Pods Manifest.lock"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n"; + showEnvVarsInLog = 0; + }; + 25160D2414564E820060A5C5 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "# Run the unit tests in this test bundle.\n\"${SYSTEM_DEVELOPER_DIR}/Tools/RunUnitTests\""; + }; + 25160E76145651060060A5C5 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "# Run the unit tests in this test bundle.\n\"${SYSTEM_DEVELOPER_DIR}/Tools/RunUnitTests\"\n"; + }; + 31E61254417653D2A601DDF8 /* Check Pods Manifest.lock */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Check Pods Manifest.lock"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n"; + showEnvVarsInLog = 0; + }; + 6A5C656B4979C48B2EE74B1A /* Check Pods Manifest.lock */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Check Pods Manifest.lock"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n"; + showEnvVarsInLog = 0; + }; + 8F48B45166853D07B6229593 /* Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( @@ -2242,9 +2110,25 @@ ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-osx/Pods-osx-resources.sh\"\n"; + shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-RestKitFramework/Pods-RestKitFramework-resources.sh\"\n"; + showEnvVarsInLog = 0; }; - 212C92B936E847348494D6F7 /* Copy Pods Resources */ = { + A7AA769D655643D4F1E58C8C /* Check Pods Manifest.lock */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Check Pods Manifest.lock"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n"; + showEnvVarsInLog = 0; + }; + D00A58B091EC84A57A1FB098 /* Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( @@ -2257,32 +2141,37 @@ runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-ios/Pods-ios-resources.sh\"\n"; + showEnvVarsInLog = 0; }; - 25160D2414564E820060A5C5 /* ShellScript */ = { + D9DDA304517443E2F6FD2B2C /* Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputPaths = ( ); + name = "Copy Pods Resources"; outputPaths = ( ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "# Run the unit tests in this test bundle.\n\"${SYSTEM_DEVELOPER_DIR}/Tools/RunUnitTests\""; + shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-osx/Pods-osx-resources.sh\"\n"; + showEnvVarsInLog = 0; }; - 25160E76145651060060A5C5 /* ShellScript */ = { + F6534AD38F03B29013ACBE7E /* Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputPaths = ( ); + name = "Copy Pods Resources"; outputPaths = ( ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "# Run the unit tests in this test bundle.\n\"${SYSTEM_DEVELOPER_DIR}/Tools/RunUnitTests\"\n"; + shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-RestKit/Pods-RestKit-resources.sh\"\n"; + showEnvVarsInLog = 0; }; /* End PBXShellScriptBuildPhase section */ @@ -2299,21 +2188,17 @@ 25160E0A145650490060A5C5 /* RKDynamicMapping.m in Sources */, DB1148461A0B26B100C8A00A /* RKLumberjackLogger.m in Sources */, 25160E0C145650490060A5C5 /* RKErrorMessage.m in Sources */, - 25DA35711836741D001A56A0 /* TKTransition.m in Sources */, 25160E10145650490060A5C5 /* RKAttributeMapping.m in Sources */, 25160E17145650490060A5C5 /* RKMapperOperation.m in Sources */, 25160E1B145650490060A5C5 /* RKObjectMapping.m in Sources */, 25160E1E145650490060A5C5 /* RKMappingOperation.m in Sources */, 25160E22145650490060A5C5 /* RKMappingResult.m in Sources */, - 252CCE7817E0CA2700B7F0BF /* RKISO8601DateFormatter.m in Sources */, 25160E24145650490060A5C5 /* RKPropertyInspector.m in Sources */, 25160E26145650490060A5C5 /* RKRelationshipMapping.m in Sources */, - 252CCE7417E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.m in Sources */, 25160E48145650490060A5C5 /* RKDotNetDateFormatter.m in Sources */, 25160E4B145650490060A5C5 /* RKLog.m in Sources */, 25160E4D145650490060A5C5 /* RKMIMETypes.m in Sources */, 25160EE41456532C0060A5C5 /* lcl_RK.m in Sources */, - 25160F0A1456532C0060A5C5 /* SOCKit.m in Sources */, 25B408281491CDDC00F21111 /* RKPathUtilities.m in Sources */, 25B6E95814CF7A1C00B1E881 /* RKErrors.m in Sources */, 25FABED114E3796400E609E7 /* RKTestNotificationObserver.m in Sources */, @@ -2353,27 +2238,14 @@ 254372D815F54CE3006E8424 /* RKManagedObjectRequestOperation.m in Sources */, 2595B47115F670530087A59B /* RKMIMETypeSerialization.m in Sources */, 2595B47515F670530087A59B /* RKNSJSONSerialization.m in Sources */, - 252CCE6817E08E2D00B7F0BF /* RKValueTransformers.m in Sources */, 253477F315FFBC61002C0E4E /* RKDictionaryUtilities.m in Sources */, 2534781615FFD4A6002C0E4E /* RKURLEncodedSerialization.m in Sources */, - 259B96D71604CCCC0000C250 /* AFHTTPClient.m in Sources */, - 259B96DB1604CCCC0000C250 /* AFHTTPRequestOperation.m in Sources */, - 259B96DF1604CCCC0000C250 /* AFImageRequestOperation.m in Sources */, - 259B96E31604CCCC0000C250 /* AFJSONRequestOperation.m in Sources */, - 259B96E51604CCCC0000C250 /* AFNetworkActivityIndicatorManager.m in Sources */, - 259B96E91604CCCC0000C250 /* AFPropertyListRequestOperation.m in Sources */, - 259B96ED1604CCCC0000C250 /* AFURLConnectionOperation.m in Sources */, - 259B96F11604CCCC0000C250 /* AFXMLRequestOperation.m in Sources */, - 259B96F31604CCCC0000C250 /* UIImageView+AFNetworking.m in Sources */, 25A226D81618A57500952D72 /* RKObjectUtilities.m in Sources */, 2507C329161BD5C700EA71FF /* RKTestHelpers.m in Sources */, 25E88C8A165C5CC30042ABD0 /* RKConnectionDescription.m in Sources */, 25A8C2361673BD480014D9A6 /* RKConnectionTestExpectation.m in Sources */, 258BEA02168D058300C74C8C /* RKObjectMappingMatcher.m in Sources */, 25A199D616ED035A00792629 /* RKBenchmark.m in Sources */, - 25C6C0BF1716F6F800C98A73 /* TKEvent.m in Sources */, - 25C6C0C31716F6F800C98A73 /* TKState.m in Sources */, - 25C6C0C71716F6F800C98A73 /* TKStateMachine.m in Sources */, 25C6C0EA1716F79B00C98A73 /* RKOperationStateMachine.m in Sources */, 54CDB45D17B408B100FAC285 /* RKStringTokenizer.m in Sources */, ); @@ -2454,22 +2326,18 @@ buildActionMask = 2147483647; files = ( 25160EE51456532C0060A5C5 /* lcl_RK.m in Sources */, - 25160F0B1456532C0060A5C5 /* SOCKit.m in Sources */, 25160F45145655C60060A5C5 /* RKDynamicMapping.m in Sources */, 25160F47145655C60060A5C5 /* RKErrorMessage.m in Sources */, 25160F4B145655C60060A5C5 /* RKAttributeMapping.m in Sources */, DB1148471A0B26B100C8A00A /* RKLumberjackLogger.m in Sources */, 25160F52145655C60060A5C5 /* RKMapperOperation.m in Sources */, - 25DA35721836741D001A56A0 /* TKTransition.m in Sources */, 25160F56145655C60060A5C5 /* RKObjectMapping.m in Sources */, 25160F59145655C60060A5C5 /* RKMappingOperation.m in Sources */, 25160F5D145655C60060A5C5 /* RKMappingResult.m in Sources */, 25160F5F145655C60060A5C5 /* RKPropertyInspector.m in Sources */, 25160F61145655C60060A5C5 /* RKRelationshipMapping.m in Sources */, - 252CCE7917E0CA2700B7F0BF /* RKISO8601DateFormatter.m in Sources */, 25160F70145655D10060A5C5 /* RKEntityMapping.m in Sources */, 25160F74145655D10060A5C5 /* RKManagedObjectImporter.m in Sources */, - 252CCE7517E0CA2700B7F0BF /* ISO8601DateFormatterValueTransformer.m in Sources */, 25160F76145655D10060A5C5 /* RKManagedObjectStore.m in Sources */, 25160F7A145655D10060A5C5 /* RKPropertyInspector+CoreData.m in Sources */, 25160F911456576C0060A5C5 /* RKDotNetDateFormatter.m in Sources */, @@ -2515,17 +2383,7 @@ 2595B47215F670530087A59B /* RKMIMETypeSerialization.m in Sources */, 2595B47615F670530087A59B /* RKNSJSONSerialization.m in Sources */, 253477F415FFBC61002C0E4E /* RKDictionaryUtilities.m in Sources */, - 252CCE6917E08E2D00B7F0BF /* RKValueTransformers.m in Sources */, 2534781715FFD4A6002C0E4E /* RKURLEncodedSerialization.m in Sources */, - 259B96D81604CCCC0000C250 /* AFHTTPClient.m in Sources */, - 259B96DC1604CCCC0000C250 /* AFHTTPRequestOperation.m in Sources */, - 259B96E01604CCCC0000C250 /* AFImageRequestOperation.m in Sources */, - 259B96E41604CCCC0000C250 /* AFJSONRequestOperation.m in Sources */, - 259B96E61604CCCC0000C250 /* AFNetworkActivityIndicatorManager.m in Sources */, - 259B96EA1604CCCC0000C250 /* AFPropertyListRequestOperation.m in Sources */, - 259B96EE1604CCCC0000C250 /* AFURLConnectionOperation.m in Sources */, - 259B96F21604CCCC0000C250 /* AFXMLRequestOperation.m in Sources */, - 259B96F41604CCCC0000C250 /* UIImageView+AFNetworking.m in Sources */, 25E9C8F1161290D500647F84 /* RKObjectParameterization.m in Sources */, 25A226D91618A57500952D72 /* RKObjectUtilities.m in Sources */, 2507C32A161BD5C700EA71FF /* RKTestHelpers.m in Sources */, @@ -2533,9 +2391,6 @@ 25A8C2371673BD480014D9A6 /* RKConnectionTestExpectation.m in Sources */, 258BEA03168D058300C74C8C /* RKObjectMappingMatcher.m in Sources */, 25A199D716ED035A00792629 /* RKBenchmark.m in Sources */, - 25C6C0C01716F6F800C98A73 /* TKEvent.m in Sources */, - 25C6C0C41716F6F800C98A73 /* TKState.m in Sources */, - 25C6C0C81716F6F800C98A73 /* TKStateMachine.m in Sources */, 25C6C0EB1716F79B00C98A73 /* RKOperationStateMachine.m in Sources */, 54CDB45E17B408B100FAC285 /* RKStringTokenizer.m in Sources */, ); @@ -2699,6 +2554,7 @@ }; 25160D3B14564E820060A5C5 /* Debug */ = { isa = XCBuildConfiguration; + baseConfigurationReference = AD2DD8D9C9EA769B53865C88 /* Pods-RestKit.debug.xcconfig */; buildSettings = { CLANG_ENABLE_OBJC_ARC = YES; GCC_PRECOMPILE_PREFIX_HEADER = YES; @@ -2706,7 +2562,6 @@ GCC_WARN_ABOUT_MISSING_NEWLINE = YES; INSTALL_PATH = "@rpath"; OBJROOT = "$(SRCROOT)/Build"; - OTHER_LDFLAGS = "-ObjC"; PRIVATE_HEADERS_FOLDER_PATH = "$(PUBLIC_HEADERS_FOLDER_PATH)/Private"; PRODUCT_NAME = "$(TARGET_NAME)"; PUBLIC_HEADERS_FOLDER_PATH = ../../Headers/RestKit; @@ -2717,6 +2572,7 @@ }; 25160D3C14564E820060A5C5 /* Release */ = { isa = XCBuildConfiguration; + baseConfigurationReference = AD144E244684975F290D70ED /* Pods-RestKit.release.xcconfig */; buildSettings = { CLANG_ENABLE_OBJC_ARC = YES; GCC_PRECOMPILE_PREFIX_HEADER = YES; @@ -2724,7 +2580,6 @@ GCC_WARN_ABOUT_MISSING_NEWLINE = YES; INSTALL_PATH = "@rpath"; OBJROOT = "$(SRCROOT)/Build"; - OTHER_LDFLAGS = "-ObjC"; PRIVATE_HEADERS_FOLDER_PATH = "$(PUBLIC_HEADERS_FOLDER_PATH)/Private"; PRODUCT_NAME = "$(TARGET_NAME)"; PUBLIC_HEADERS_FOLDER_PATH = ../../Headers/RestKit; @@ -2735,7 +2590,7 @@ }; 25160D3E14564E820060A5C5 /* Debug */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 147F950728350A64F103F55D /* Pods-ios.debug.xcconfig */; + baseConfigurationReference = 0B096CE4874E766ECE78D229 /* Pods-ios.debug.xcconfig */; buildSettings = { CLANG_ENABLE_OBJC_ARC = YES; FRAMEWORK_SEARCH_PATHS = ( @@ -2747,7 +2602,6 @@ GCC_PREFIX_HEADER = "Code/Support/RestKit-Prefix.pch"; INFOPLIST_FILE = "Resources/PLISTs/RestKitTests-Info.plist"; OBJROOT = "$(SRCROOT)/Build"; - OTHER_LDFLAGS = "$(inherited)"; PRODUCT_NAME = "$(TARGET_NAME)"; SYMROOT = "$(SRCROOT)/Build/Products"; }; @@ -2755,7 +2609,7 @@ }; 25160D3F14564E820060A5C5 /* Release */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 061E3E4524CE8EF78257C26C /* Pods-ios.release.xcconfig */; + baseConfigurationReference = A339C3AFD7C094BEAFE92A93 /* Pods-ios.release.xcconfig */; buildSettings = { CLANG_ENABLE_OBJC_ARC = YES; FRAMEWORK_SEARCH_PATHS = ( @@ -2767,7 +2621,6 @@ GCC_PREFIX_HEADER = "Code/Support/RestKit-Prefix.pch"; INFOPLIST_FILE = "Resources/PLISTs/RestKitTests-Info.plist"; OBJROOT = "$(SRCROOT)/Build"; - OTHER_LDFLAGS = "$(inherited)"; PRODUCT_NAME = "$(TARGET_NAME)"; SYMROOT = "$(SRCROOT)/Build/Products"; }; @@ -2775,6 +2628,7 @@ }; 25160E88145651060060A5C5 /* Debug */ = { isa = XCBuildConfiguration; + baseConfigurationReference = C5608EB544CBB19BBACC13BA /* Pods-RestKitFramework.debug.xcconfig */; buildSettings = { CLANG_ENABLE_OBJC_ARC = YES; COMBINE_HIDPI_IMAGES = YES; @@ -2803,6 +2657,7 @@ }; 25160E89145651060060A5C5 /* Release */ = { isa = XCBuildConfiguration; + baseConfigurationReference = 1ABDEC386A27292EF883B0BE /* Pods-RestKitFramework.release.xcconfig */; buildSettings = { CLANG_ENABLE_OBJC_ARC = YES; COMBINE_HIDPI_IMAGES = YES; @@ -2831,7 +2686,7 @@ }; 25160E8B145651060060A5C5 /* Debug */ = { isa = XCBuildConfiguration; - baseConfigurationReference = D8EFCBE1978F7946E0081FAD /* Pods-osx.debug.xcconfig */; + baseConfigurationReference = A920AEDAEC3C6599433D2720 /* Pods-osx.debug.xcconfig */; buildSettings = { CLANG_ENABLE_OBJC_ARC = YES; COMBINE_HIDPI_IMAGES = YES; @@ -2850,7 +2705,7 @@ }; 25160E8C145651060060A5C5 /* Release */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 04D69B4B2A54475834B333CF /* Pods-osx.release.xcconfig */; + baseConfigurationReference = F6B428543BF5CF359F239FE1 /* Pods-osx.release.xcconfig */; buildSettings = { CLANG_ENABLE_OBJC_ARC = YES; COMBINE_HIDPI_IMAGES = YES; diff --git a/RestKit.xcworkspace/xcshareddata/xcschemes/Build All Examples.xcscheme b/RestKit.xcworkspace/xcshareddata/xcschemes/Build All Examples.xcscheme index 19e901e01e..7a400e7cf1 100644 --- a/RestKit.xcworkspace/xcshareddata/xcschemes/Build All Examples.xcscheme +++ b/RestKit.xcworkspace/xcshareddata/xcschemes/Build All Examples.xcscheme @@ -1,6 +1,6 @@ + + Date: Sat, 13 Jun 2015 19:07:10 -0700 Subject: [PATCH 21/94] Make the framework imports sane --- Code/Network/RKHTTPRequestOperation.h | 9 ++------- Code/Network/RKObjectManager.h | 6 +----- Code/ObjectMapping.h | 8 ++------ Code/ObjectMapping/RKObjectMapping.h | 6 +----- 4 files changed, 6 insertions(+), 23 deletions(-) diff --git a/Code/Network/RKHTTPRequestOperation.h b/Code/Network/RKHTTPRequestOperation.h index 39f8a10c79..5f41c3f011 100644 --- a/Code/Network/RKHTTPRequestOperation.h +++ b/Code/Network/RKHTTPRequestOperation.h @@ -18,13 +18,8 @@ // limitations under the License. // -#if __has_include() -# import -# import -#else -# import "AFHTTPClient.h" -# import "AFHTTPRequestOperation.h" -#endif +#import +#import // Expose the default headers from AFNetworking's AFHTTPClient @interface AFHTTPClient () diff --git a/Code/Network/RKObjectManager.h b/Code/Network/RKObjectManager.h index e351bf544c..7b107b67d5 100644 --- a/Code/Network/RKObjectManager.h +++ b/Code/Network/RKObjectManager.h @@ -22,11 +22,7 @@ #import "RKPaginator.h" #import "RKMacros.h" -#if __has_include() -# import -#else -# import "AFNetworking.h" -#endif +#import #ifdef _COREDATADEFINES_H # if __has_include("RKCoreData.h") diff --git a/Code/ObjectMapping.h b/Code/ObjectMapping.h index 152fcb1571..1ad0b8ceee 100644 --- a/Code/ObjectMapping.h +++ b/Code/ObjectMapping.h @@ -18,6 +18,8 @@ // limitations under the License. // +#import + #import "RKObjectMapping.h" #import "RKAttributeMapping.h" #import "RKRelationshipMapping.h" @@ -25,9 +27,3 @@ #import "RKMapperOperation.h" #import "RKDynamicMapping.h" #import "RKErrorMessage.h" - -#if __has_include() -# import -#else -# import "RKValueTransformers.h" -#endif diff --git a/Code/ObjectMapping/RKObjectMapping.h b/Code/ObjectMapping/RKObjectMapping.h index afd388b738..ff15c62004 100644 --- a/Code/ObjectMapping/RKObjectMapping.h +++ b/Code/ObjectMapping/RKObjectMapping.h @@ -21,11 +21,7 @@ #import "RKMacros.h" #import "RKMapping.h" -#if __has_include() -# import -#else -# import "RKValueTransformers.h" -#endif +#import @class RKPropertyMapping, RKAttributeMapping, RKRelationshipMapping; @protocol RKValueTransforming; From 42248565486e31ab46fbe5460df116111d79d6cf Mon Sep 17 00:00:00 2001 From: "Samuel E. Giddins" Date: Sat, 13 Jun 2015 19:08:08 -0700 Subject: [PATCH 22/94] Also lint on CI as a static lib --- Rakefile | 1 + 1 file changed, 1 insertion(+) diff --git a/Rakefile b/Rakefile index 4ceb190796..8e354dfe21 100644 --- a/Rakefile +++ b/Rakefile @@ -165,6 +165,7 @@ end task :lint do title 'Linting pod' run('bundle exec pod lib lint') + run('bundle exec pod lib lint --use-libraries') end desc 'Runs the CI suite' From ec1d47081fde70b8ec27a4d7faa6af09026f0192 Mon Sep 17 00:00:00 2001 From: "Samuel E. Giddins" Date: Sat, 13 Jun 2015 19:10:05 -0700 Subject: [PATCH 23/94] Remove vestigial submodules --- .gitmodules | 9 --------- 1 file changed, 9 deletions(-) diff --git a/.gitmodules b/.gitmodules index 946ac987de..e69de29bb2 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,9 +0,0 @@ -[submodule "Vendor/AFNetworking"] - path = Vendor/AFNetworking - url = https://github.com/AFNetworking/AFNetworking.git -[submodule "Vendor/ISO8601DateFormatterValueTransformer"] - path = Vendor/ISO8601DateFormatterValueTransformer - url = https://github.com/blakewatters/ISO8601DateFormatterValueTransformer.git -[submodule "Vendor/SOCKit"] - path = Vendor/SOCKit - url = https://github.com/NimbusKit/sockit.git From 22dc46d640b87b395060cec2f989de31b2cfa3f5 Mon Sep 17 00:00:00 2001 From: Adolfo Martinelli Date: Sun, 26 Jul 2015 23:41:04 -0700 Subject: [PATCH 24/94] Update example projects to use CocoaPods --- Examples/RKMacOSX/Podfile | 4 + .../RKMacOSX.xcodeproj/project.pbxproj | 169 +++------- .../RKMacOSX/RKMacOSX/RKMacOSX-Info.plist | 2 +- Examples/RKSearchExample/Podfile | 7 + .../RKSearchExample.xcodeproj/project.pbxproj | 179 ++++------ .../RKSearchExample-Info.plist | 2 +- Examples/RKTwitter/Podfile | 9 +- .../RKTwitter.xcodeproj/project.pbxproj | 309 +++--------------- .../contents.xcworkspacedata | 1 - .../xcschemes/RKTwitterCocoaPods.xcscheme | 86 ----- .../RKTwitter/Resources/RKTwitter-Info.plist | 2 +- Examples/RKTwitterCoreData/Podfile | 9 + .../project.pbxproj | 173 +++------- .../Resources/RKTwitter-Info.plist | 2 +- Podfile.lock | 6 +- .../PLISTs/RestKitFrameworkTests-Info.plist | 2 +- Resources/PLISTs/RestKitTests-Info.plist | 2 +- RestKit.xcodeproj/project.pbxproj | 9 +- 18 files changed, 254 insertions(+), 719 deletions(-) create mode 100644 Examples/RKMacOSX/Podfile create mode 100644 Examples/RKSearchExample/Podfile delete mode 100644 Examples/RKTwitter/RKTwitter.xcworkspace/contents.xcworkspacedata delete mode 100644 Examples/RKTwitter/RKTwitter.xcworkspace/xcshareddata/xcschemes/RKTwitterCocoaPods.xcscheme create mode 100644 Examples/RKTwitterCoreData/Podfile diff --git a/Examples/RKMacOSX/Podfile b/Examples/RKMacOSX/Podfile new file mode 100644 index 0000000000..573ff403c9 --- /dev/null +++ b/Examples/RKMacOSX/Podfile @@ -0,0 +1,4 @@ +# Install via CocoaPods pointing at current local codebase +pod 'RestKit/Network', :path => '../../' +pod 'RestKit/ObjectMapping', :path => '../../' +pod 'RestKit/CoreData', :path => '../../' diff --git a/Examples/RKMacOSX/RKMacOSX.xcodeproj/project.pbxproj b/Examples/RKMacOSX/RKMacOSX.xcodeproj/project.pbxproj index 5f9f7175d0..edc74bccd4 100644 --- a/Examples/RKMacOSX/RKMacOSX.xcodeproj/project.pbxproj +++ b/Examples/RKMacOSX/RKMacOSX.xcodeproj/project.pbxproj @@ -7,7 +7,7 @@ objects = { /* Begin PBXBuildFile section */ - 250DF24F14C67F560001DEFA /* RestKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 250DF24B14C67E9A0001DEFA /* RestKit.framework */; }; + 1CE1DD3E5F2FE7DA177F56EF /* libPods.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A28BE5513E3B77C342497A9E /* libPods.a */; }; 25D63919135184CE000879B1 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 25D63918135184CE000879B1 /* Cocoa.framework */; }; 25D63923135184CE000879B1 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 25D63921135184CE000879B1 /* InfoPlist.strings */; }; 25D63926135184CE000879B1 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 25D63925135184CE000879B1 /* main.m */; }; @@ -19,44 +19,6 @@ 25D63983135185B6000879B1 /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 25D63982135185B6000879B1 /* SystemConfiguration.framework */; }; /* End PBXBuildFile section */ -/* Begin PBXContainerItemProxy section */ - 250DF24614C67E9A0001DEFA /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 25D63938135184F0000879B1 /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160D1614564E810060A5C5; - remoteInfo = RestKit; - }; - 250DF24814C67E9A0001DEFA /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 25D63938135184F0000879B1 /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160D2614564E820060A5C5; - remoteInfo = RestKitTests; - }; - 250DF24A14C67E9A0001DEFA /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 25D63938135184F0000879B1 /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160E62145651060060A5C5; - remoteInfo = RestKitFramework; - }; - 250DF24C14C67E9A0001DEFA /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 25D63938135184F0000879B1 /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160E78145651060060A5C5; - remoteInfo = RestKitFrameworkTests; - }; - 250DF25014C67F630001DEFA /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 25D63938135184F0000879B1 /* RestKit.xcodeproj */; - proxyType = 1; - remoteGlobalIDString = 25160E61145651060060A5C5; - remoteInfo = RestKitFramework; - }; -/* End PBXContainerItemProxy section */ - /* Begin PBXFileReference section */ 25D63914135184CE000879B1 /* RKMacOSX.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = RKMacOSX.app; sourceTree = BUILT_PRODUCTS_DIR; }; 25D63918135184CE000879B1 /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = System/Library/Frameworks/Cocoa.framework; sourceTree = SDKROOT; }; @@ -71,10 +33,12 @@ 25D6392A135184CE000879B1 /* RKMacOSXAppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RKMacOSXAppDelegate.h; sourceTree = ""; }; 25D6392B135184CE000879B1 /* RKMacOSXAppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RKMacOSXAppDelegate.m; sourceTree = ""; }; 25D6392E135184CF000879B1 /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = en.lproj/MainMenu.xib; sourceTree = ""; }; - 25D63938135184F0000879B1 /* RestKit.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RestKit.xcodeproj; path = ../../RestKit.xcodeproj; sourceTree = ""; }; 25D6397E13518574000879B1 /* CoreData.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreData.framework; path = System/Library/Frameworks/CoreData.framework; sourceTree = SDKROOT; }; 25D639801351858A000879B1 /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = System/Library/Frameworks/AppKit.framework; sourceTree = SDKROOT; }; 25D63982135185B6000879B1 /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = System/Library/Frameworks/SystemConfiguration.framework; sourceTree = SDKROOT; }; + 663395048EDD9B445E77BF72 /* Pods.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.debug.xcconfig; path = "Pods/Target Support Files/Pods/Pods.debug.xcconfig"; sourceTree = ""; }; + A28BE5513E3B77C342497A9E /* libPods.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libPods.a; sourceTree = BUILT_PRODUCTS_DIR; }; + CDF0146ADF834F0317B19719 /* Pods.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.release.xcconfig; path = "Pods/Target Support Files/Pods/Pods.release.xcconfig"; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -82,11 +46,11 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - 250DF24F14C67F560001DEFA /* RestKit.framework in Frameworks */, 25D63983135185B6000879B1 /* SystemConfiguration.framework in Frameworks */, 25D639811351858A000879B1 /* AppKit.framework in Frameworks */, 25D6397F13518574000879B1 /* CoreData.framework in Frameworks */, 25D63919135184CE000879B1 /* Cocoa.framework in Frameworks */, + 1CE1DD3E5F2FE7DA177F56EF /* libPods.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -97,9 +61,9 @@ isa = PBXGroup; children = ( 25D6391E135184CE000879B1 /* RKMacOSX */, - 25D639841351868E000879B1 /* RestKit */, 25D63917135184CE000879B1 /* Frameworks */, 25D63915135184CE000879B1 /* Products */, + F73078E151260A102FEB82F9 /* Pods */, ); sourceTree = ""; }; @@ -119,6 +83,7 @@ 25D6397E13518574000879B1 /* CoreData.framework */, 25D63918135184CE000879B1 /* Cocoa.framework */, 25D6391A135184CE000879B1 /* Other Frameworks */, + A28BE5513E3B77C342497A9E /* libPods.a */, ); name = Frameworks; sourceTree = ""; @@ -156,23 +121,13 @@ name = "Supporting Files"; sourceTree = ""; }; - 25D63939135184F0000879B1 /* Products */ = { + F73078E151260A102FEB82F9 /* Pods */ = { isa = PBXGroup; children = ( - 250DF24714C67E9A0001DEFA /* libRestKit.a */, - 250DF24914C67E9A0001DEFA /* RestKitTests.xctest */, - 250DF24B14C67E9A0001DEFA /* RestKit.framework */, - 250DF24D14C67E9A0001DEFA /* RestKitFrameworkTests.xctest */, + 663395048EDD9B445E77BF72 /* Pods.debug.xcconfig */, + CDF0146ADF834F0317B19719 /* Pods.release.xcconfig */, ); - name = Products; - sourceTree = ""; - }; - 25D639841351868E000879B1 /* RestKit */ = { - isa = PBXGroup; - children = ( - 25D63938135184F0000879B1 /* RestKit.xcodeproj */, - ); - name = RestKit; + name = Pods; sourceTree = ""; }; /* End PBXGroup section */ @@ -182,14 +137,15 @@ isa = PBXNativeTarget; buildConfigurationList = 25D63935135184CF000879B1 /* Build configuration list for PBXNativeTarget "RKMacOSX" */; buildPhases = ( + 0E7867D148FBAD64B7DE1EB6 /* Check Pods Manifest.lock */, 25D63910135184CE000879B1 /* Sources */, 25D63911135184CE000879B1 /* Frameworks */, 25D63912135184CE000879B1 /* Resources */, + E02916F51F1155DFDAB83400 /* Copy Pods Resources */, ); buildRules = ( ); dependencies = ( - 250DF25114C67F630001DEFA /* PBXTargetDependency */, ); name = RKMacOSX; productName = RKMacOSX; @@ -202,7 +158,7 @@ 25D6390B135184CE000879B1 /* Project object */ = { isa = PBXProject; attributes = { - LastUpgradeCheck = 0620; + LastUpgradeCheck = 0700; }; buildConfigurationList = 25D6390E135184CE000879B1 /* Build configuration list for PBXProject "RKMacOSX" */; compatibilityVersion = "Xcode 3.2"; @@ -214,12 +170,6 @@ mainGroup = 25D63909135184CE000879B1; productRefGroup = 25D63915135184CE000879B1 /* Products */; projectDirPath = ""; - projectReferences = ( - { - ProductGroup = 25D63939135184F0000879B1 /* Products */; - ProjectRef = 25D63938135184F0000879B1 /* RestKit.xcodeproj */; - }, - ); projectRoot = ""; targets = ( 25D63913135184CE000879B1 /* RKMacOSX */, @@ -227,37 +177,6 @@ }; /* End PBXProject section */ -/* Begin PBXReferenceProxy section */ - 250DF24714C67E9A0001DEFA /* libRestKit.a */ = { - isa = PBXReferenceProxy; - fileType = archive.ar; - path = libRestKit.a; - remoteRef = 250DF24614C67E9A0001DEFA /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; - 250DF24914C67E9A0001DEFA /* RestKitTests.xctest */ = { - isa = PBXReferenceProxy; - fileType = wrapper.cfbundle; - path = RestKitTests.xctest; - remoteRef = 250DF24814C67E9A0001DEFA /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; - 250DF24B14C67E9A0001DEFA /* RestKit.framework */ = { - isa = PBXReferenceProxy; - fileType = wrapper.framework; - path = RestKit.framework; - remoteRef = 250DF24A14C67E9A0001DEFA /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; - 250DF24D14C67E9A0001DEFA /* RestKitFrameworkTests.xctest */ = { - isa = PBXReferenceProxy; - fileType = wrapper.cfbundle; - path = RestKitFrameworkTests.xctest; - remoteRef = 250DF24C14C67E9A0001DEFA /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; -/* End PBXReferenceProxy section */ - /* Begin PBXResourcesBuildPhase section */ 25D63912135184CE000879B1 /* Resources */ = { isa = PBXResourcesBuildPhase; @@ -271,6 +190,39 @@ }; /* End PBXResourcesBuildPhase section */ +/* Begin PBXShellScriptBuildPhase section */ + 0E7867D148FBAD64B7DE1EB6 /* Check Pods Manifest.lock */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Check Pods Manifest.lock"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n"; + showEnvVarsInLog = 0; + }; + E02916F51F1155DFDAB83400 /* Copy Pods Resources */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Copy Pods Resources"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods/Pods-resources.sh\"\n"; + showEnvVarsInLog = 0; + }; +/* End PBXShellScriptBuildPhase section */ + /* Begin PBXSourcesBuildPhase section */ 25D63910135184CE000879B1 /* Sources */ = { isa = PBXSourcesBuildPhase; @@ -283,14 +235,6 @@ }; /* End PBXSourcesBuildPhase section */ -/* Begin PBXTargetDependency section */ - 250DF25114C67F630001DEFA /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - name = RestKitFramework; - targetProxy = 250DF25014C67F630001DEFA /* PBXContainerItemProxy */; - }; -/* End PBXTargetDependency section */ - /* Begin PBXVariantGroup section */ 25D63921135184CE000879B1 /* InfoPlist.strings */ = { isa = PBXVariantGroup; @@ -330,7 +274,9 @@ CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; GCC_OPTIMIZATION_LEVEL = 0; GCC_PREPROCESSOR_DEFINITIONS = DEBUG; GCC_SYMBOLS_PRIVATE_EXTERN = NO; @@ -360,6 +306,7 @@ CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_ABOUT_RETURN_TYPE = YES; @@ -375,6 +322,7 @@ }; 25D63936135184CF000879B1 /* Debug */ = { isa = XCBuildConfiguration; + baseConfigurationReference = 663395048EDD9B445E77BF72 /* Pods.debug.xcconfig */; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; CLANG_ENABLE_OBJC_ARC = YES; @@ -384,14 +332,9 @@ GCC_ENABLE_OBJC_EXCEPTIONS = YES; GCC_PRECOMPILE_PREFIX_HEADER = YES; GCC_PREFIX_HEADER = "RKMacOSX/RKMacOSX-Prefix.pch"; - HEADER_SEARCH_PATHS = "\"$(BUILT_PRODUCTS_DIR)/../../Headers\""; INFOPLIST_FILE = "RKMacOSX/RKMacOSX-Info.plist"; - LIBRARY_SEARCH_PATHS = ( - "$(inherited)", - "\"$(SRCROOT)\"", - ); MACOSX_DEPLOYMENT_TARGET = 10.7; - OTHER_LDFLAGS = "-ObjC"; + PRODUCT_BUNDLE_IDENTIFIER = "com.twotoasters.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = "$(TARGET_NAME)"; WRAPPER_EXTENSION = app; }; @@ -399,6 +342,7 @@ }; 25D63937135184CF000879B1 /* Release */ = { isa = XCBuildConfiguration; + baseConfigurationReference = CDF0146ADF834F0317B19719 /* Pods.release.xcconfig */; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; CLANG_ENABLE_OBJC_ARC = YES; @@ -408,14 +352,9 @@ GCC_ENABLE_OBJC_EXCEPTIONS = YES; GCC_PRECOMPILE_PREFIX_HEADER = YES; GCC_PREFIX_HEADER = "RKMacOSX/RKMacOSX-Prefix.pch"; - HEADER_SEARCH_PATHS = "\"$(BUILT_PRODUCTS_DIR)/../../Headers\""; INFOPLIST_FILE = "RKMacOSX/RKMacOSX-Info.plist"; - LIBRARY_SEARCH_PATHS = ( - "$(inherited)", - "\"$(SRCROOT)\"", - ); MACOSX_DEPLOYMENT_TARGET = 10.7; - OTHER_LDFLAGS = "-ObjC"; + PRODUCT_BUNDLE_IDENTIFIER = "com.twotoasters.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = "$(TARGET_NAME)"; WRAPPER_EXTENSION = app; }; diff --git a/Examples/RKMacOSX/RKMacOSX/RKMacOSX-Info.plist b/Examples/RKMacOSX/RKMacOSX/RKMacOSX-Info.plist index 6884487220..ba0e84af5c 100644 --- a/Examples/RKMacOSX/RKMacOSX/RKMacOSX-Info.plist +++ b/Examples/RKMacOSX/RKMacOSX/RKMacOSX-Info.plist @@ -9,7 +9,7 @@ CFBundleIconFile CFBundleIdentifier - com.twotoasters.${PRODUCT_NAME:rfc1034identifier} + $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundleName diff --git a/Examples/RKSearchExample/Podfile b/Examples/RKSearchExample/Podfile new file mode 100644 index 0000000000..8deb679bf0 --- /dev/null +++ b/Examples/RKSearchExample/Podfile @@ -0,0 +1,7 @@ +platform :ios, '8.0' +use_frameworks! + +# Install via CocoaPods pointing at current local codebase +pod 'RestKit/Network', :path => '../../' +pod 'RestKit/ObjectMapping', :path => '../../' +pod 'RestKit/Search', :path => '../../' diff --git a/Examples/RKSearchExample/RKSearchExample.xcodeproj/project.pbxproj b/Examples/RKSearchExample/RKSearchExample.xcodeproj/project.pbxproj index f9ed76f09d..bfed36b67e 100644 --- a/Examples/RKSearchExample/RKSearchExample.xcodeproj/project.pbxproj +++ b/Examples/RKSearchExample/RKSearchExample.xcodeproj/project.pbxproj @@ -16,7 +16,6 @@ 259C800B15D20B5600F447D2 /* RKSAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 259C800A15D20B5600F447D2 /* RKSAppDelegate.m */; }; 259C800E15D20B5600F447D2 /* MainStoryboard.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 259C800C15D20B5600F447D2 /* MainStoryboard.storyboard */; }; 259C801115D20B5600F447D2 /* RKSViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 259C801015D20B5600F447D2 /* RKSViewController.m */; }; - 259C802E15D20BAA00F447D2 /* libRestKit.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 259C802315D20B7100F447D2 /* libRestKit.a */; }; 259C803415D20BAA00F447D2 /* CFNetwork.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 259C802F15D20BAA00F447D2 /* CFNetwork.framework */; }; 259C803515D20BAA00F447D2 /* CoreData.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 259C803015D20BAA00F447D2 /* CoreData.framework */; }; 259C803615D20BAA00F447D2 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 259C803115D20BAA00F447D2 /* QuartzCore.framework */; }; @@ -26,46 +25,9 @@ 259C803C15D20C4000F447D2 /* libxml2.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 259C803B15D20C4000F447D2 /* libxml2.dylib */; }; 25AA7D1415D4C3A700A1B4E7 /* RKSearchExampleModel.xcdatamodeld in Sources */ = {isa = PBXBuildFile; fileRef = 25AA7D1215D4C3A700A1B4E7 /* RKSearchExampleModel.xcdatamodeld */; }; 25AABCF017B69B590061DC5B /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 25AABCEF17B69B590061DC5B /* Default-568h@2x.png */; }; + 45F73EB9D2311FFAF6C1338B /* Pods.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 5F88520F4AEA4E5CA9B38E99 /* Pods.framework */; settings = {ATTRIBUTES = (Weak, ); }; }; /* End PBXBuildFile section */ -/* Begin PBXContainerItemProxy section */ - 259C802215D20B7100F447D2 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 259C801715D20B7100F447D2 /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160D1614564E810060A5C5; - remoteInfo = RestKit; - }; - 259C802415D20B7100F447D2 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 259C801715D20B7100F447D2 /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160D2614564E820060A5C5; - remoteInfo = RestKitTests; - }; - 259C802615D20B7100F447D2 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 259C801715D20B7100F447D2 /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160E62145651060060A5C5; - remoteInfo = RestKitFramework; - }; - 259C802815D20B7100F447D2 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 259C801715D20B7100F447D2 /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160E78145651060060A5C5; - remoteInfo = RestKitFrameworkTests; - }; - 259C802C15D20B7B00F447D2 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 259C801715D20B7100F447D2 /* RestKit.xcodeproj */; - proxyType = 1; - remoteGlobalIDString = 25160D1514564E810060A5C5; - remoteInfo = RestKit; - }; -/* End PBXContainerItemProxy section */ - /* Begin PBXFileReference section */ 2583C49B15D96D4000E05CAE /* contacts.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = contacts.json; sourceTree = ""; }; 259C7FF615D20B5600F447D2 /* RKSearchExample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = RKSearchExample.app; sourceTree = BUILT_PRODUCTS_DIR; }; @@ -81,7 +43,6 @@ 259C800D15D20B5600F447D2 /* en */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = en; path = en.lproj/MainStoryboard.storyboard; sourceTree = ""; }; 259C800F15D20B5600F447D2 /* RKSViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RKSViewController.h; sourceTree = ""; }; 259C801015D20B5600F447D2 /* RKSViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RKSViewController.m; sourceTree = ""; }; - 259C801715D20B7100F447D2 /* RestKit.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RestKit.xcodeproj; path = ../../RestKit.xcodeproj; sourceTree = ""; }; 259C802F15D20BAA00F447D2 /* CFNetwork.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CFNetwork.framework; path = System/Library/Frameworks/CFNetwork.framework; sourceTree = SDKROOT; }; 259C803015D20BAA00F447D2 /* CoreData.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreData.framework; path = System/Library/Frameworks/CoreData.framework; sourceTree = SDKROOT; }; 259C803115D20BAA00F447D2 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; @@ -91,6 +52,9 @@ 259C803B15D20C4000F447D2 /* libxml2.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libxml2.dylib; path = usr/lib/libxml2.dylib; sourceTree = SDKROOT; }; 25AA7D1315D4C3A700A1B4E7 /* RKSearchExampleModel.xcdatamodel */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcdatamodel; path = RKSearchExampleModel.xcdatamodel; sourceTree = ""; }; 25AABCEF17B69B590061DC5B /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = ""; }; + 4839D63C1F0B427271E84C9B /* Pods.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.release.xcconfig; path = "Pods/Target Support Files/Pods/Pods.release.xcconfig"; sourceTree = ""; }; + 5F88520F4AEA4E5CA9B38E99 /* Pods.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + 97374605117FDAA6FDA05691 /* Pods.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.debug.xcconfig; path = "Pods/Target Support Files/Pods/Pods.debug.xcconfig"; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -105,10 +69,10 @@ 259C803615D20BAA00F447D2 /* QuartzCore.framework in Frameworks */, 259C803715D20BAA00F447D2 /* Security.framework in Frameworks */, 259C803815D20BAA00F447D2 /* SystemConfiguration.framework in Frameworks */, - 259C802E15D20BAA00F447D2 /* libRestKit.a in Frameworks */, 259C7FFF15D20B5600F447D2 /* CoreGraphics.framework in Frameworks */, 259C7FFB15D20B5600F447D2 /* UIKit.framework in Frameworks */, 259C7FFD15D20B5600F447D2 /* Foundation.framework in Frameworks */, + 45F73EB9D2311FFAF6C1338B /* Pods.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -122,7 +86,7 @@ 259C800015D20B5600F447D2 /* RKSearchExample */, 259C7FF915D20B5600F447D2 /* Frameworks */, 259C7FF715D20B5600F447D2 /* Products */, - 259C801715D20B7100F447D2 /* RestKit.xcodeproj */, + 8045C6A1DC1A7B372A75E95F /* Pods */, ); sourceTree = ""; }; @@ -147,6 +111,7 @@ 259C7FFA15D20B5600F447D2 /* UIKit.framework */, 259C7FFC15D20B5600F447D2 /* Foundation.framework */, 259C7FFE15D20B5600F447D2 /* CoreGraphics.framework */, + 5F88520F4AEA4E5CA9B38E99 /* Pods.framework */, ); name = Frameworks; sourceTree = ""; @@ -177,15 +142,13 @@ name = "Supporting Files"; sourceTree = ""; }; - 259C801815D20B7100F447D2 /* Products */ = { + 8045C6A1DC1A7B372A75E95F /* Pods */ = { isa = PBXGroup; children = ( - 259C802315D20B7100F447D2 /* libRestKit.a */, - 259C802515D20B7100F447D2 /* RestKitTests.octest */, - 259C802715D20B7100F447D2 /* RestKit.framework */, - 259C802915D20B7100F447D2 /* RestKitFrameworkTests.octest */, + 97374605117FDAA6FDA05691 /* Pods.debug.xcconfig */, + 4839D63C1F0B427271E84C9B /* Pods.release.xcconfig */, ); - name = Products; + name = Pods; sourceTree = ""; }; /* End PBXGroup section */ @@ -195,14 +158,16 @@ isa = PBXNativeTarget; buildConfigurationList = 259C801415D20B5600F447D2 /* Build configuration list for PBXNativeTarget "RKSearchExample" */; buildPhases = ( + 647A518E7D82E5FBFCACA0DF /* Check Pods Manifest.lock */, 259C7FF215D20B5600F447D2 /* Sources */, 259C7FF315D20B5600F447D2 /* Frameworks */, 259C7FF415D20B5600F447D2 /* Resources */, + 64884B0BE0AA32A1480DCC81 /* Embed Pods Frameworks */, + 750345EDEDC2028EA5111217 /* Copy Pods Resources */, ); buildRules = ( ); dependencies = ( - 259C802D15D20B7B00F447D2 /* PBXTargetDependency */, ); name = RKSearchExample; productName = RKSearchExample; @@ -216,7 +181,7 @@ isa = PBXProject; attributes = { CLASSPREFIX = RKS; - LastUpgradeCheck = 0500; + LastUpgradeCheck = 0700; ORGANIZATIONNAME = "Blake Watters"; }; buildConfigurationList = 259C7FF015D20B5600F447D2 /* Build configuration list for PBXProject "RKSearchExample" */; @@ -229,12 +194,6 @@ mainGroup = 259C7FEB15D20B5600F447D2; productRefGroup = 259C7FF715D20B5600F447D2 /* Products */; projectDirPath = ""; - projectReferences = ( - { - ProductGroup = 259C801815D20B7100F447D2 /* Products */; - ProjectRef = 259C801715D20B7100F447D2 /* RestKit.xcodeproj */; - }, - ); projectRoot = ""; targets = ( 259C7FF515D20B5600F447D2 /* RKSearchExample */, @@ -242,37 +201,6 @@ }; /* End PBXProject section */ -/* Begin PBXReferenceProxy section */ - 259C802315D20B7100F447D2 /* libRestKit.a */ = { - isa = PBXReferenceProxy; - fileType = archive.ar; - path = libRestKit.a; - remoteRef = 259C802215D20B7100F447D2 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; - 259C802515D20B7100F447D2 /* RestKitTests.octest */ = { - isa = PBXReferenceProxy; - fileType = wrapper.cfbundle; - path = RestKitTests.octest; - remoteRef = 259C802415D20B7100F447D2 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; - 259C802715D20B7100F447D2 /* RestKit.framework */ = { - isa = PBXReferenceProxy; - fileType = wrapper.framework; - path = RestKit.framework; - remoteRef = 259C802615D20B7100F447D2 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; - 259C802915D20B7100F447D2 /* RestKitFrameworkTests.octest */ = { - isa = PBXReferenceProxy; - fileType = wrapper.cfbundle; - path = RestKitFrameworkTests.octest; - remoteRef = 259C802815D20B7100F447D2 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; -/* End PBXReferenceProxy section */ - /* Begin PBXResourcesBuildPhase section */ 259C7FF415D20B5600F447D2 /* Resources */ = { isa = PBXResourcesBuildPhase; @@ -287,6 +215,54 @@ }; /* End PBXResourcesBuildPhase section */ +/* Begin PBXShellScriptBuildPhase section */ + 647A518E7D82E5FBFCACA0DF /* Check Pods Manifest.lock */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Check Pods Manifest.lock"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n"; + showEnvVarsInLog = 0; + }; + 64884B0BE0AA32A1480DCC81 /* Embed Pods Frameworks */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Embed Pods Frameworks"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods/Pods-frameworks.sh\"\n"; + showEnvVarsInLog = 0; + }; + 750345EDEDC2028EA5111217 /* Copy Pods Resources */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Copy Pods Resources"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods/Pods-resources.sh\"\n"; + showEnvVarsInLog = 0; + }; +/* End PBXShellScriptBuildPhase section */ + /* Begin PBXSourcesBuildPhase section */ 259C7FF215D20B5600F447D2 /* Sources */ = { isa = PBXSourcesBuildPhase; @@ -301,14 +277,6 @@ }; /* End PBXSourcesBuildPhase section */ -/* Begin PBXTargetDependency section */ - 259C802D15D20B7B00F447D2 /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - name = RestKit; - targetProxy = 259C802C15D20B7B00F447D2 /* PBXContainerItemProxy */; - }; -/* End PBXTargetDependency section */ - /* Begin PBXVariantGroup section */ 259C800315D20B5600F447D2 /* InfoPlist.strings */ = { isa = PBXVariantGroup; @@ -332,13 +300,13 @@ 259C801215D20B5600F447D2 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_OBJC_ARC = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; COPY_PHASE_STRIP = NO; + ENABLE_TESTABILITY = YES; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_DYNAMIC_NO_PIC = NO; GCC_OPTIMIZATION_LEVEL = 0; @@ -359,7 +327,6 @@ 259C801315D20B5600F447D2 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_OBJC_ARC = YES; @@ -379,16 +346,13 @@ }; 259C801515D20B5600F447D2 /* Debug */ = { isa = XCBuildConfiguration; + baseConfigurationReference = 97374605117FDAA6FDA05691 /* Pods.debug.xcconfig */; buildSettings = { GCC_PRECOMPILE_PREFIX_HEADER = YES; GCC_PREFIX_HEADER = "RKSearchExample/RKSearchExample-Prefix.pch"; - HEADER_SEARCH_PATHS = "\"$(BUILT_PRODUCTS_DIR)/../../Headers\""; INFOPLIST_FILE = "RKSearchExample/RKSearchExample-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 6.0; - OTHER_LDFLAGS = ( - "-ObjC", - "-all_load", - ); + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + PRODUCT_BUNDLE_IDENTIFIER = "org.restkit.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = "$(TARGET_NAME)"; WRAPPER_EXTENSION = app; }; @@ -396,16 +360,13 @@ }; 259C801615D20B5600F447D2 /* Release */ = { isa = XCBuildConfiguration; + baseConfigurationReference = 4839D63C1F0B427271E84C9B /* Pods.release.xcconfig */; buildSettings = { GCC_PRECOMPILE_PREFIX_HEADER = YES; GCC_PREFIX_HEADER = "RKSearchExample/RKSearchExample-Prefix.pch"; - HEADER_SEARCH_PATHS = "\"$(BUILT_PRODUCTS_DIR)/../../Headers\""; INFOPLIST_FILE = "RKSearchExample/RKSearchExample-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 6.0; - OTHER_LDFLAGS = ( - "-ObjC", - "-all_load", - ); + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + PRODUCT_BUNDLE_IDENTIFIER = "org.restkit.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = "$(TARGET_NAME)"; WRAPPER_EXTENSION = app; }; diff --git a/Examples/RKSearchExample/RKSearchExample/RKSearchExample-Info.plist b/Examples/RKSearchExample/RKSearchExample/RKSearchExample-Info.plist index e6d3e99f87..8a34c1e729 100644 --- a/Examples/RKSearchExample/RKSearchExample/RKSearchExample-Info.plist +++ b/Examples/RKSearchExample/RKSearchExample/RKSearchExample-Info.plist @@ -9,7 +9,7 @@ CFBundleExecutable ${EXECUTABLE_NAME} CFBundleIdentifier - org.restkit.${PRODUCT_NAME:rfc1034identifier} + $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundleName diff --git a/Examples/RKTwitter/Podfile b/Examples/RKTwitter/Podfile index ff8da2784e..d48f0d84d2 100644 --- a/Examples/RKTwitter/Podfile +++ b/Examples/RKTwitter/Podfile @@ -1,7 +1,6 @@ -platform :ios, '6.0' +platform :ios, '8.0' +use_frameworks! # Install via CocoaPods pointing at current local codebase -target 'RKTwitterCocoaPods' do - pod 'RestKit/Network', :path => '../../' - pod 'RestKit/ObjectMapping', :path => '../../' -end +pod 'RestKit/Network', :path => '../../' +pod 'RestKit/ObjectMapping', :path => '../../' diff --git a/Examples/RKTwitter/RKTwitter.xcodeproj/project.pbxproj b/Examples/RKTwitter/RKTwitter.xcodeproj/project.pbxproj index 18dbabeb9e..544005ba79 100755 --- a/Examples/RKTwitter/RKTwitter.xcodeproj/project.pbxproj +++ b/Examples/RKTwitter/RKTwitter.xcodeproj/project.pbxproj @@ -7,18 +7,6 @@ objects = { /* Begin PBXBuildFile section */ - 001D8303A88B451D830741B8 /* libPods-RKTwitterCocoaPods.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7666CC5642F94148AF23256A /* libPods-RKTwitterCocoaPods.a */; }; - 1D3623260D0F684500981E51 /* RKTwitterAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 1D3623250D0F684500981E51 /* RKTwitterAppDelegate.m */; }; - 1D60589B0D05DD56006BFB54 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 29B97316FDCFA39411CA2CEA /* main.m */; }; - 1D60589F0D05DD5A006BFB54 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1D30AB110D05D00D00671497 /* Foundation.framework */; }; - 1DF5F4E00D08C38300B7A737 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1DF5F4DF0D08C38300B7A737 /* UIKit.framework */; }; - 25063C9116021B16007CAC2B /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 25063C9016021B16007CAC2B /* Default-568h@2x.png */; }; - 250CA69A147D8FCC0047D347 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 250CA699147D8FCC0047D347 /* Security.framework */; }; - 250CA69B147D8FD30047D347 /* libRestKit.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 25160FB31456E8A30060A5C5 /* libRestKit.a */; }; - 250CA69C147D8FFD0047D347 /* CoreData.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2538E864123424F000ACB5D7 /* CoreData.framework */; }; - 2538E811123419CA00ACB5D7 /* RKTUser.m in Sources */ = {isa = PBXBuildFile; fileRef = 2538E810123419CA00ACB5D7 /* RKTUser.m */; }; - 2538E814123419EC00ACB5D7 /* RKTweet.m in Sources */ = {isa = PBXBuildFile; fileRef = 2538E813123419EC00ACB5D7 /* RKTweet.m */; }; - 2538E8671234250100ACB5D7 /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2538E8661234250100ACB5D7 /* SystemConfiguration.framework */; }; 25AABCF817B69CC50061DC5B /* listbg.png in Resources */ = {isa = PBXBuildFile; fileRef = 3F3CE3FA125B9A6E0083FDCB /* listbg.png */; }; 25AABCF917B69CC50061DC5B /* listbg@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 3F3CE3FB125B9A6E0083FDCB /* listbg@2x.png */; }; 25AABCFA17B69CC50061DC5B /* BG.png in Resources */ = {isa = PBXBuildFile; fileRef = 3F3CE40A125B9B450083FDCB /* BG.png */; }; @@ -35,74 +23,15 @@ 25AABD0B17B69CC50061DC5B /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1D30AB110D05D00D00671497 /* Foundation.framework */; }; 25AABD0C17B69CC50061DC5B /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1DF5F4DF0D08C38300B7A737 /* UIKit.framework */; }; 25AABD0D17B69CC50061DC5B /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 288765A40DF7441C002DB57D /* CoreGraphics.framework */; }; - 25BE936614F96729008BC1C0 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 25BE936514F96729008BC1C0 /* QuartzCore.framework */; }; - 288765A50DF7441C002DB57D /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 288765A40DF7441C002DB57D /* CoreGraphics.framework */; }; - 28D7ACF80DDB3853001CB0EB /* RKTwitterViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 28D7ACF70DDB3853001CB0EB /* RKTwitterViewController.m */; }; - 3F02F592131D683A004E1F54 /* libxml2.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 3F02F591131D683A004E1F54 /* libxml2.dylib */; }; - 3F3CE3FC125B9A6E0083FDCB /* listbg.png in Resources */ = {isa = PBXBuildFile; fileRef = 3F3CE3FA125B9A6E0083FDCB /* listbg.png */; }; - 3F3CE3FD125B9A6E0083FDCB /* listbg@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 3F3CE3FB125B9A6E0083FDCB /* listbg@2x.png */; }; - 3F3CE40E125B9B450083FDCB /* BG.png in Resources */ = {isa = PBXBuildFile; fileRef = 3F3CE40A125B9B450083FDCB /* BG.png */; }; - 3F3CE40F125B9B450083FDCB /* BG@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 3F3CE40B125B9B450083FDCB /* BG@2x.png */; }; - 3F3CE410125B9B450083FDCB /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 3F3CE40C125B9B450083FDCB /* Default.png */; }; - 3F3CE411125B9B450083FDCB /* Default@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 3F3CE40D125B9B450083FDCB /* Default@2x.png */; }; - 84F524C212824D5000C370EA /* CFNetwork.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 84F524C112824D5000C370EA /* CFNetwork.framework */; }; - 84F524C612824D5B00C370EA /* MobileCoreServices.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 84F524C512824D5B00C370EA /* MobileCoreServices.framework */; }; + 73D990C2D2D5A068521FACEF /* Pods.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F0C5817426474EE329BB79E2 /* Pods.framework */; settings = {ATTRIBUTES = (Weak, ); }; }; /* End PBXBuildFile section */ -/* Begin PBXContainerItemProxy section */ - 250AC4BA1358C7A8006F084F /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 250AC48A1358C79C006F084F /* RestKit.xcodeproj */; - proxyType = 1; - remoteGlobalIDString = 25160D1514564E810060A5C5; - remoteInfo = RestKit; - }; - 25160FB21456E8A30060A5C5 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 250AC48A1358C79C006F084F /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160D1614564E810060A5C5; - remoteInfo = RestKit; - }; - 25160FB41456E8A30060A5C5 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 250AC48A1358C79C006F084F /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160D2614564E820060A5C5; - remoteInfo = RestKitTests; - }; - 25160FB61456E8A30060A5C5 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 250AC48A1358C79C006F084F /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160E62145651060060A5C5; - remoteInfo = RestKitFramework; - }; - 25160FB81456E8A30060A5C5 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 250AC48A1358C79C006F084F /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160E78145651060060A5C5; - remoteInfo = RestKitFrameworkTests; - }; - 25AABCF617B69CC50061DC5B /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 250AC48A1358C79C006F084F /* RestKit.xcodeproj */; - proxyType = 1; - remoteGlobalIDString = 25160D1514564E810060A5C5; - remoteInfo = RestKit; - }; -/* End PBXContainerItemProxy section */ - /* Begin PBXFileReference section */ - 1BBF770CA495AD12361E6DA5 /* Pods-RKTwitterCocoaPods.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RKTwitterCocoaPods.debug.xcconfig"; path = "Pods/Target Support Files/Pods-RKTwitterCocoaPods/Pods-RKTwitterCocoaPods.debug.xcconfig"; sourceTree = ""; }; 1D30AB110D05D00D00671497 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; 1D3623240D0F684500981E51 /* RKTwitterAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKTwitterAppDelegate.h; sourceTree = ""; }; 1D3623250D0F684500981E51 /* RKTwitterAppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKTwitterAppDelegate.m; sourceTree = ""; }; - 1D6058910D05DD3D006BFB54 /* RKTwitter.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = RKTwitter.app; sourceTree = BUILT_PRODUCTS_DIR; }; 1DF5F4DF0D08C38300B7A737 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; }; 25063C9016021B16007CAC2B /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = ""; }; - 250AC48A1358C79C006F084F /* RestKit.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RestKit.xcodeproj; path = ../../RestKit.xcodeproj; sourceTree = ""; }; 250CA699147D8FCC0047D347 /* Security.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Security.framework; path = System/Library/Frameworks/Security.framework; sourceTree = SDKROOT; }; 2538E80F123419CA00ACB5D7 /* RKTUser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKTUser.h; sourceTree = ""; }; 2538E810123419CA00ACB5D7 /* RKTUser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKTUser.m; sourceTree = ""; }; @@ -110,12 +39,13 @@ 2538E813123419EC00ACB5D7 /* RKTweet.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKTweet.m; sourceTree = ""; }; 2538E864123424F000ACB5D7 /* CoreData.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreData.framework; path = System/Library/Frameworks/CoreData.framework; sourceTree = SDKROOT; }; 2538E8661234250100ACB5D7 /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = System/Library/Frameworks/SystemConfiguration.framework; sourceTree = SDKROOT; }; - 25AABD1417B69CC50061DC5B /* RKTwitter copy.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "RKTwitter copy.app"; sourceTree = BUILT_PRODUCTS_DIR; }; + 25AABD1417B69CC50061DC5B /* RKTwitter.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = RKTwitter.app; sourceTree = BUILT_PRODUCTS_DIR; }; 25BE936514F96729008BC1C0 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; 288765A40DF7441C002DB57D /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; }; 28D7ACF60DDB3853001CB0EB /* RKTwitterViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKTwitterViewController.h; sourceTree = ""; }; 28D7ACF70DDB3853001CB0EB /* RKTwitterViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKTwitterViewController.m; sourceTree = ""; }; 29B97316FDCFA39411CA2CEA /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; + 2C4E0FC1267B5DE1E5594342 /* Pods.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.release.xcconfig; path = "Pods/Target Support Files/Pods/Pods.release.xcconfig"; sourceTree = ""; }; 32CA4F630368D1EE00C91783 /* RKTwitter_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKTwitter_Prefix.pch; sourceTree = ""; }; 3F02F591131D683A004E1F54 /* libxml2.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libxml2.dylib; path = usr/lib/libxml2.dylib; sourceTree = SDKROOT; }; 3F3CE3FA125B9A6E0083FDCB /* listbg.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = listbg.png; sourceTree = ""; }; @@ -124,32 +54,14 @@ 3F3CE40B125B9B450083FDCB /* BG@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "BG@2x.png"; sourceTree = ""; }; 3F3CE40C125B9B450083FDCB /* Default.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Default.png; sourceTree = ""; }; 3F3CE40D125B9B450083FDCB /* Default@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default@2x.png"; sourceTree = ""; }; - 7666CC5642F94148AF23256A /* libPods-RKTwitterCocoaPods.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-RKTwitterCocoaPods.a"; sourceTree = BUILT_PRODUCTS_DIR; }; 84F524C112824D5000C370EA /* CFNetwork.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CFNetwork.framework; path = System/Library/Frameworks/CFNetwork.framework; sourceTree = SDKROOT; }; 84F524C512824D5B00C370EA /* MobileCoreServices.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MobileCoreServices.framework; path = System/Library/Frameworks/MobileCoreServices.framework; sourceTree = SDKROOT; }; 8D1107310486CEB800E47090 /* RKTwitter-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "RKTwitter-Info.plist"; plistStructureDefinitionIdentifier = "com.apple.xcode.plist.structure-definition.iphone.info-plist"; sourceTree = ""; }; - EC32B4B0491C719850D46F92 /* Pods-RKTwitterCocoaPods.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RKTwitterCocoaPods.release.xcconfig"; path = "Pods/Target Support Files/Pods-RKTwitterCocoaPods/Pods-RKTwitterCocoaPods.release.xcconfig"; sourceTree = ""; }; + 9459B171A0B89699CB1F7ECC /* Pods.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.debug.xcconfig; path = "Pods/Target Support Files/Pods/Pods.debug.xcconfig"; sourceTree = ""; }; + F0C5817426474EE329BB79E2 /* Pods.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods.framework; sourceTree = BUILT_PRODUCTS_DIR; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ - 1D60588F0D05DD3D006BFB54 /* Frameworks */ = { - isa = PBXFrameworksBuildPhase; - buildActionMask = 2147483647; - files = ( - 25BE936614F96729008BC1C0 /* QuartzCore.framework in Frameworks */, - 250CA69C147D8FFD0047D347 /* CoreData.framework in Frameworks */, - 250CA69B147D8FD30047D347 /* libRestKit.a in Frameworks */, - 250CA69A147D8FCC0047D347 /* Security.framework in Frameworks */, - 3F02F592131D683A004E1F54 /* libxml2.dylib in Frameworks */, - 1D60589F0D05DD5A006BFB54 /* Foundation.framework in Frameworks */, - 1DF5F4E00D08C38300B7A737 /* UIKit.framework in Frameworks */, - 288765A50DF7441C002DB57D /* CoreGraphics.framework in Frameworks */, - 2538E8671234250100ACB5D7 /* SystemConfiguration.framework in Frameworks */, - 84F524C212824D5000C370EA /* CFNetwork.framework in Frameworks */, - 84F524C612824D5B00C370EA /* MobileCoreServices.framework in Frameworks */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; 25AABD0517B69CC50061DC5B /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; @@ -158,7 +70,7 @@ 25AABD0B17B69CC50061DC5B /* Foundation.framework in Frameworks */, 25AABD0C17B69CC50061DC5B /* UIKit.framework in Frameworks */, 25AABD0D17B69CC50061DC5B /* CoreGraphics.framework in Frameworks */, - 001D8303A88B451D830741B8 /* libPods-RKTwitterCocoaPods.a in Frameworks */, + 73D990C2D2D5A068521FACEF /* Pods.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -183,19 +95,7 @@ 19C28FACFE9D520D11CA2CBB /* Products */ = { isa = PBXGroup; children = ( - 1D6058910D05DD3D006BFB54 /* RKTwitter.app */, - 25AABD1417B69CC50061DC5B /* RKTwitter copy.app */, - ); - name = Products; - sourceTree = ""; - }; - 250AC48B1358C79C006F084F /* Products */ = { - isa = PBXGroup; - children = ( - 25160FB31456E8A30060A5C5 /* libRestKit.a */, - 25160FB51456E8A30060A5C5 /* RestKitTests.octest */, - 25160FB71456E8A30060A5C5 /* RestKit.framework */, - 25160FB91456E8A30060A5C5 /* RestKitFrameworkTests.octest */, + 25AABD1417B69CC50061DC5B /* RKTwitter.app */, ); name = Products; sourceTree = ""; @@ -204,7 +104,6 @@ isa = PBXGroup; children = ( 25063C9016021B16007CAC2B /* Default-568h@2x.png */, - 250AC48A1358C79C006F084F /* RestKit.xcodeproj */, 080E96DDFE201D6D7F000001 /* Classes */, 29B97315FDCFA39411CA2CEA /* Other Sources */, 29B97317FDCFA39411CA2CEA /* Resources */, @@ -251,7 +150,7 @@ 2538E8661234250100ACB5D7 /* SystemConfiguration.framework */, 84F524C112824D5000C370EA /* CFNetwork.framework */, 84F524C512824D5B00C370EA /* MobileCoreServices.framework */, - 7666CC5642F94148AF23256A /* libPods-RKTwitterCocoaPods.a */, + F0C5817426474EE329BB79E2 /* Pods.framework */, ); name = Frameworks; sourceTree = ""; @@ -259,8 +158,8 @@ A54F9C18924391E57B4EFF4D /* Pods */ = { isa = PBXGroup; children = ( - 1BBF770CA495AD12361E6DA5 /* Pods-RKTwitterCocoaPods.debug.xcconfig */, - EC32B4B0491C719850D46F92 /* Pods-RKTwitterCocoaPods.release.xcconfig */, + 9459B171A0B89699CB1F7ECC /* Pods.debug.xcconfig */, + 2C4E0FC1267B5DE1E5594342 /* Pods.release.xcconfig */, ); name = Pods; sourceTree = ""; @@ -268,42 +167,24 @@ /* End PBXGroup section */ /* Begin PBXNativeTarget section */ - 1D6058900D05DD3D006BFB54 /* RKTwitter */ = { - isa = PBXNativeTarget; - buildConfigurationList = 1D6058960D05DD3E006BFB54 /* Build configuration list for PBXNativeTarget "RKTwitter" */; - buildPhases = ( - 1D60588D0D05DD3D006BFB54 /* Resources */, - 1D60588E0D05DD3D006BFB54 /* Sources */, - 1D60588F0D05DD3D006BFB54 /* Frameworks */, - ); - buildRules = ( - ); - dependencies = ( - 250AC4BB1358C7A8006F084F /* PBXTargetDependency */, - ); - name = RKTwitter; - productName = RKTwitter; - productReference = 1D6058910D05DD3D006BFB54 /* RKTwitter.app */; - productType = "com.apple.product-type.application"; - }; - 25AABCF417B69CC50061DC5B /* RKTwitterCocoaPods */ = { + 25AABCF417B69CC50061DC5B /* RKTwitter */ = { isa = PBXNativeTarget; - buildConfigurationList = 25AABD1117B69CC50061DC5B /* Build configuration list for PBXNativeTarget "RKTwitterCocoaPods" */; + buildConfigurationList = 25AABD1117B69CC50061DC5B /* Build configuration list for PBXNativeTarget "RKTwitter" */; buildPhases = ( B2D422E3401D465BACF8687A /* Check Pods Manifest.lock */, 25AABCF717B69CC50061DC5B /* Resources */, 25AABCFF17B69CC50061DC5B /* Sources */, 25AABD0517B69CC50061DC5B /* Frameworks */, BA14B331096F49758212B549 /* Copy Pods Resources */, + B73887517504A74F7323976B /* Embed Pods Frameworks */, ); buildRules = ( ); dependencies = ( - 25AABCF517B69CC50061DC5B /* PBXTargetDependency */, ); - name = RKTwitterCocoaPods; + name = RKTwitter; productName = RKTwitter; - productReference = 25AABD1417B69CC50061DC5B /* RKTwitter copy.app */; + productReference = 25AABD1417B69CC50061DC5B /* RKTwitter.app */; productType = "com.apple.product-type.application"; }; /* End PBXNativeTarget section */ @@ -312,7 +193,7 @@ 29B97313FDCFA39411CA2CEA /* Project object */ = { isa = PBXProject; attributes = { - LastUpgradeCheck = 0500; + LastUpgradeCheck = 0700; }; buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "RKTwitter" */; compatibilityVersion = "Xcode 3.2"; @@ -326,66 +207,14 @@ ); mainGroup = 29B97314FDCFA39411CA2CEA /* CustomTemplate */; projectDirPath = ""; - projectReferences = ( - { - ProductGroup = 250AC48B1358C79C006F084F /* Products */; - ProjectRef = 250AC48A1358C79C006F084F /* RestKit.xcodeproj */; - }, - ); projectRoot = ""; targets = ( - 1D6058900D05DD3D006BFB54 /* RKTwitter */, - 25AABCF417B69CC50061DC5B /* RKTwitterCocoaPods */, + 25AABCF417B69CC50061DC5B /* RKTwitter */, ); }; /* End PBXProject section */ -/* Begin PBXReferenceProxy section */ - 25160FB31456E8A30060A5C5 /* libRestKit.a */ = { - isa = PBXReferenceProxy; - fileType = archive.ar; - path = libRestKit.a; - remoteRef = 25160FB21456E8A30060A5C5 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; - 25160FB51456E8A30060A5C5 /* RestKitTests.octest */ = { - isa = PBXReferenceProxy; - fileType = wrapper.cfbundle; - path = RestKitTests.xctest; - remoteRef = 25160FB41456E8A30060A5C5 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; - 25160FB71456E8A30060A5C5 /* RestKit.framework */ = { - isa = PBXReferenceProxy; - fileType = wrapper.framework; - path = RestKit.framework; - remoteRef = 25160FB61456E8A30060A5C5 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; - 25160FB91456E8A30060A5C5 /* RestKitFrameworkTests.octest */ = { - isa = PBXReferenceProxy; - fileType = wrapper.cfbundle; - path = RestKitFrameworkTests.xctest; - remoteRef = 25160FB81456E8A30060A5C5 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; -/* End PBXReferenceProxy section */ - /* Begin PBXResourcesBuildPhase section */ - 1D60588D0D05DD3D006BFB54 /* Resources */ = { - isa = PBXResourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 3F3CE3FC125B9A6E0083FDCB /* listbg.png in Resources */, - 3F3CE3FD125B9A6E0083FDCB /* listbg@2x.png in Resources */, - 3F3CE40E125B9B450083FDCB /* BG.png in Resources */, - 3F3CE40F125B9B450083FDCB /* BG@2x.png in Resources */, - 3F3CE410125B9B450083FDCB /* Default.png in Resources */, - 3F3CE411125B9B450083FDCB /* Default@2x.png in Resources */, - 25063C9116021B16007CAC2B /* Default-568h@2x.png in Resources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; 25AABCF717B69CC50061DC5B /* Resources */ = { isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; @@ -418,36 +247,39 @@ shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n"; showEnvVarsInLog = 0; }; - BA14B331096F49758212B549 /* Copy Pods Resources */ = { + B73887517504A74F7323976B /* Embed Pods Frameworks */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputPaths = ( ); - name = "Copy Pods Resources"; + name = "Embed Pods Frameworks"; outputPaths = ( ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-RKTwitterCocoaPods/Pods-RKTwitterCocoaPods-resources.sh\"\n"; + shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods/Pods-frameworks.sh\"\n"; showEnvVarsInLog = 0; }; -/* End PBXShellScriptBuildPhase section */ - -/* Begin PBXSourcesBuildPhase section */ - 1D60588E0D05DD3D006BFB54 /* Sources */ = { - isa = PBXSourcesBuildPhase; + BA14B331096F49758212B549 /* Copy Pods Resources */ = { + isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( - 1D60589B0D05DD56006BFB54 /* main.m in Sources */, - 1D3623260D0F684500981E51 /* RKTwitterAppDelegate.m in Sources */, - 28D7ACF80DDB3853001CB0EB /* RKTwitterViewController.m in Sources */, - 2538E811123419CA00ACB5D7 /* RKTUser.m in Sources */, - 2538E814123419EC00ACB5D7 /* RKTweet.m in Sources */, + ); + inputPaths = ( + ); + name = "Copy Pods Resources"; + outputPaths = ( ); runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods/Pods-resources.sh\"\n"; + showEnvVarsInLog = 0; }; +/* End PBXShellScriptBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ 25AABCFF17B69CC50061DC5B /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; @@ -462,59 +294,10 @@ }; /* End PBXSourcesBuildPhase section */ -/* Begin PBXTargetDependency section */ - 250AC4BB1358C7A8006F084F /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - name = RestKit; - targetProxy = 250AC4BA1358C7A8006F084F /* PBXContainerItemProxy */; - }; - 25AABCF517B69CC50061DC5B /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - name = RestKit; - targetProxy = 25AABCF617B69CC50061DC5B /* PBXContainerItemProxy */; - }; -/* End PBXTargetDependency section */ - /* Begin XCBuildConfiguration section */ - 1D6058940D05DD3E006BFB54 /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - BUILD_STYLE = Debug; - CLANG_ENABLE_OBJC_ARC = YES; - COPY_PHASE_STRIP = NO; - GCC_DYNAMIC_NO_PIC = NO; - GCC_OPTIMIZATION_LEVEL = 0; - GCC_PRECOMPILE_PREFIX_HEADER = YES; - GCC_PREFIX_HEADER = RKTwitter_Prefix.pch; - HEADER_SEARCH_PATHS = "\"$(BUILT_PRODUCTS_DIR)/../../Headers\""; - INFOPLIST_FILE = "Resources/RKTwitter-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 5.0; - ONLY_ACTIVE_ARCH = YES; - OTHER_LDFLAGS = "-ObjC"; - PRODUCT_NAME = RKTwitter; - }; - name = Debug; - }; - 1D6058950D05DD3E006BFB54 /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - BUILD_STYLE = Release; - CLANG_ENABLE_OBJC_ARC = YES; - COPY_PHASE_STRIP = YES; - GCC_PRECOMPILE_PREFIX_HEADER = YES; - GCC_PREFIX_HEADER = RKTwitter_Prefix.pch; - HEADER_SEARCH_PATHS = "\"$(BUILT_PRODUCTS_DIR)/../../Headers\""; - INFOPLIST_FILE = "Resources/RKTwitter-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 5.0; - OTHER_LDFLAGS = "-ObjC"; - PRODUCT_NAME = RKTwitter; - VALIDATE_PRODUCT = YES; - }; - name = Release; - }; 25AABD1217B69CC50061DC5B /* Debug */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 1BBF770CA495AD12361E6DA5 /* Pods-RKTwitterCocoaPods.debug.xcconfig */; + baseConfigurationReference = 9459B171A0B89699CB1F7ECC /* Pods.debug.xcconfig */; buildSettings = { BUILD_STYLE = Debug; CLANG_ENABLE_OBJC_ARC = YES; @@ -524,15 +307,16 @@ GCC_PRECOMPILE_PREFIX_HEADER = YES; GCC_PREFIX_HEADER = RKTwitter_Prefix.pch; INFOPLIST_FILE = "Resources/RKTwitter-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 5.0; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; ONLY_ACTIVE_ARCH = YES; - PRODUCT_NAME = "RKTwitter copy"; + PRODUCT_BUNDLE_IDENTIFIER = com.yourcompany.RKTwitter; + PRODUCT_NAME = RKTwitter; }; name = Debug; }; 25AABD1317B69CC50061DC5B /* Release */ = { isa = XCBuildConfiguration; - baseConfigurationReference = EC32B4B0491C719850D46F92 /* Pods-RKTwitterCocoaPods.release.xcconfig */; + baseConfigurationReference = 2C4E0FC1267B5DE1E5594342 /* Pods.release.xcconfig */; buildSettings = { BUILD_STYLE = Release; CLANG_ENABLE_OBJC_ARC = YES; @@ -540,8 +324,9 @@ GCC_PRECOMPILE_PREFIX_HEADER = YES; GCC_PREFIX_HEADER = RKTwitter_Prefix.pch; INFOPLIST_FILE = "Resources/RKTwitter-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 5.0; - PRODUCT_NAME = "RKTwitter copy"; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + PRODUCT_BUNDLE_IDENTIFIER = com.yourcompany.RKTwitter; + PRODUCT_NAME = RKTwitter; VALIDATE_PRODUCT = YES; }; name = Release; @@ -551,6 +336,7 @@ buildSettings = { BUILD_STYLE = Debug; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + ENABLE_TESTABILITY = YES; GCC_WARN_ABOUT_RETURN_TYPE = YES; GCC_WARN_UNUSED_VARIABLE = YES; ONLY_ACTIVE_ARCH = YES; @@ -573,16 +359,7 @@ /* End XCBuildConfiguration section */ /* Begin XCConfigurationList section */ - 1D6058960D05DD3E006BFB54 /* Build configuration list for PBXNativeTarget "RKTwitter" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 1D6058940D05DD3E006BFB54 /* Debug */, - 1D6058950D05DD3E006BFB54 /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; - 25AABD1117B69CC50061DC5B /* Build configuration list for PBXNativeTarget "RKTwitterCocoaPods" */ = { + 25AABD1117B69CC50061DC5B /* Build configuration list for PBXNativeTarget "RKTwitter" */ = { isa = XCConfigurationList; buildConfigurations = ( 25AABD1217B69CC50061DC5B /* Debug */, diff --git a/Examples/RKTwitter/RKTwitter.xcworkspace/contents.xcworkspacedata b/Examples/RKTwitter/RKTwitter.xcworkspace/contents.xcworkspacedata deleted file mode 100644 index 1ed22467a5..0000000000 --- a/Examples/RKTwitter/RKTwitter.xcworkspace/contents.xcworkspacedata +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/Examples/RKTwitter/RKTwitter.xcworkspace/xcshareddata/xcschemes/RKTwitterCocoaPods.xcscheme b/Examples/RKTwitter/RKTwitter.xcworkspace/xcshareddata/xcschemes/RKTwitterCocoaPods.xcscheme deleted file mode 100644 index 0efc43b842..0000000000 --- a/Examples/RKTwitter/RKTwitter.xcworkspace/xcshareddata/xcschemes/RKTwitterCocoaPods.xcscheme +++ /dev/null @@ -1,86 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Examples/RKTwitter/Resources/RKTwitter-Info.plist b/Examples/RKTwitter/Resources/RKTwitter-Info.plist index 15665856b0..8cd6b8ca0c 100644 --- a/Examples/RKTwitter/Resources/RKTwitter-Info.plist +++ b/Examples/RKTwitter/Resources/RKTwitter-Info.plist @@ -11,7 +11,7 @@ CFBundleIconFile CFBundleIdentifier - com.yourcompany.${PRODUCT_NAME:rfc1034identifier} + $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundleName diff --git a/Examples/RKTwitterCoreData/Podfile b/Examples/RKTwitterCoreData/Podfile new file mode 100644 index 0000000000..ed20a7af61 --- /dev/null +++ b/Examples/RKTwitterCoreData/Podfile @@ -0,0 +1,9 @@ +platform :ios, '8.0' +use_frameworks! + +link_with 'RKTwitterCoreData', 'Generate Seed Database' + +# Install via CocoaPods pointing at current local codebase +pod 'RestKit/Network', :path => '../../' +pod 'RestKit/ObjectMapping', :path => '../../' +pod 'RestKit/CoreData', :path => '../../' diff --git a/Examples/RKTwitterCoreData/RKTwitterCoreData.xcodeproj/project.pbxproj b/Examples/RKTwitterCoreData/RKTwitterCoreData.xcodeproj/project.pbxproj index 94d6420875..06e7d32318 100755 --- a/Examples/RKTwitterCoreData/RKTwitterCoreData.xcodeproj/project.pbxproj +++ b/Examples/RKTwitterCoreData/RKTwitterCoreData.xcodeproj/project.pbxproj @@ -12,9 +12,7 @@ 1D60589F0D05DD5A006BFB54 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1D30AB110D05D00D00671497 /* Foundation.framework */; }; 1DF5F4E00D08C38300B7A737 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1DF5F4DF0D08C38300B7A737 /* UIKit.framework */; }; 25014071153706FD004E0466 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 250CA6CF147D90C50047D347 /* Security.framework */; }; - 25014085153707CB004E0466 /* libRestKit.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 250CA6C6147D90A50047D347 /* libRestKit.a */; }; 25014086153707E2004E0466 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = CD39C14D14EEED8700E84874 /* QuartzCore.framework */; }; - 250CA6CE147D90BA0047D347 /* libRestKit.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 250CA6C6147D90A50047D347 /* libRestKit.a */; }; 250CA6D0147D90C50047D347 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 250CA6CF147D90C50047D347 /* Security.framework */; }; 252E157D16397DCA000B729E /* MainStoryboard.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 2536AF3B16397A0200AD803D /* MainStoryboard.storyboard */; }; 2536AF3C16397A0200AD803D /* MainStoryboard.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 2536AF3B16397A0200AD803D /* MainStoryboard.storyboard */; }; @@ -55,54 +53,13 @@ 3FB46641131D78A400E37C51 /* libxml2.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 3FB46640131D78A400E37C51 /* libxml2.dylib */; }; 8452D3F9128244D90069F4A9 /* CFNetwork.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8452D3F8128244D90069F4A9 /* CFNetwork.framework */; }; 8452D3FD128244E60069F4A9 /* MobileCoreServices.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8452D3FC128244E60069F4A9 /* MobileCoreServices.framework */; }; + 91E489421B66047A004B5AB5 /* Pods.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A0702A131DA8B31559EADB35 /* Pods.framework */; }; + 91E489431B6604A9004B5AB5 /* libxml2.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 3FB46640131D78A400E37C51 /* libxml2.dylib */; }; + 91E489461B660547004B5AB5 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 259D0FC318076E40007C66D6 /* Default-568h@2x.png */; }; + A4AAAC70510CB014ED4378BD /* Pods.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A0702A131DA8B31559EADB35 /* Pods.framework */; settings = {ATTRIBUTES = (Weak, ); }; }; CD39C14E14EEED8700E84874 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = CD39C14D14EEED8700E84874 /* QuartzCore.framework */; }; /* End PBXBuildFile section */ -/* Begin PBXContainerItemProxy section */ - 250CA6C5147D90A50047D347 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 2538E7FF123417E500ACB5D7 /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160D1614564E810060A5C5; - remoteInfo = RestKit; - }; - 250CA6C7147D90A50047D347 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 2538E7FF123417E500ACB5D7 /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160D2614564E820060A5C5; - remoteInfo = RestKitTests; - }; - 250CA6C9147D90A50047D347 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 2538E7FF123417E500ACB5D7 /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160E62145651060060A5C5; - remoteInfo = RestKitFramework; - }; - 250CA6CB147D90A50047D347 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 2538E7FF123417E500ACB5D7 /* RestKit.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 25160E78145651060060A5C5; - remoteInfo = RestKitFrameworkTests; - }; - 25F2A1771322D59400A33DE4 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 2538E7FF123417E500ACB5D7 /* RestKit.xcodeproj */; - proxyType = 1; - remoteGlobalIDString = 25160D1514564E810060A5C5; - remoteInfo = RestKit; - }; - 3F3CE2E3125B93EB0083FDCB /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 2538E7FF123417E500ACB5D7 /* RestKit.xcodeproj */; - proxyType = 1; - remoteGlobalIDString = 25160D1514564E810060A5C5; - remoteInfo = RestKit; - }; -/* End PBXContainerItemProxy section */ - /* Begin PBXFileReference section */ 1D30AB110D05D00D00671497 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; 1D3623240D0F684500981E51 /* RKTwitterAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKTwitterAppDelegate.h; sourceTree = ""; }; @@ -111,12 +68,11 @@ 1DF5F4DF0D08C38300B7A737 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; }; 250CA6CF147D90C50047D347 /* Security.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Security.framework; path = System/Library/Frameworks/Security.framework; sourceTree = SDKROOT; }; 2536AF3B16397A0200AD803D /* MainStoryboard.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = MainStoryboard.storyboard; sourceTree = ""; }; - 2538E7FF123417E500ACB5D7 /* RestKit.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RestKit.xcodeproj; path = ../../RestKit.xcodeproj; sourceTree = SOURCE_ROOT; }; 2538E812123419EC00ACB5D7 /* RKTweet.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKTweet.h; sourceTree = ""; }; 2538E813123419EC00ACB5D7 /* RKTweet.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKTweet.m; sourceTree = ""; }; 2538E864123424F000ACB5D7 /* CoreData.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreData.framework; path = System/Library/Frameworks/CoreData.framework; sourceTree = SDKROOT; }; 2538E8661234250100ACB5D7 /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = System/Library/Frameworks/SystemConfiguration.framework; sourceTree = SDKROOT; }; - 259D0FC318076E40007C66D6 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = ""; }; + 259D0FC318076E40007C66D6 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = "Default-568h@2x.png"; path = "../Default-568h@2x.png"; sourceTree = ""; }; 25F2A1961322D59400A33DE4 /* Generate Seed Database.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Generate Seed Database.app"; sourceTree = BUILT_PRODUCTS_DIR; }; 25F2A1981322D93500A33DE4 /* restkit.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = restkit.json; sourceTree = SOURCE_ROOT; }; 25F2A19A1322DCDC00A33DE4 /* users.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = users.json; path = ../users.json; sourceTree = ""; }; @@ -134,9 +90,12 @@ 3F3CE40D125B9B450083FDCB /* Default@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default@2x.png"; sourceTree = ""; }; 3F94E0C6125BA8C0001E8585 /* RKTwitterCoreData.xcdatamodel */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = wrapper.xcdatamodel; path = RKTwitterCoreData.xcdatamodel; sourceTree = ""; }; 3FB46640131D78A400E37C51 /* libxml2.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libxml2.dylib; path = usr/lib/libxml2.dylib; sourceTree = SDKROOT; }; + 4C54AB4C3537B4FFC4CDAA11 /* Pods.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.debug.xcconfig; path = "Pods/Target Support Files/Pods/Pods.debug.xcconfig"; sourceTree = ""; }; + 76894C65C72E67BEB1D13573 /* Pods.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.release.xcconfig; path = "Pods/Target Support Files/Pods/Pods.release.xcconfig"; sourceTree = ""; }; 8452D3F8128244D90069F4A9 /* CFNetwork.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CFNetwork.framework; path = System/Library/Frameworks/CFNetwork.framework; sourceTree = SDKROOT; }; 8452D3FC128244E60069F4A9 /* MobileCoreServices.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MobileCoreServices.framework; path = System/Library/Frameworks/MobileCoreServices.framework; sourceTree = SDKROOT; }; 8D1107310486CEB800E47090 /* RKTwitter-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "RKTwitter-Info.plist"; plistStructureDefinitionIdentifier = "com.apple.xcode.plist.structure-definition.iphone.info-plist"; sourceTree = ""; }; + A0702A131DA8B31559EADB35 /* Pods.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods.framework; sourceTree = BUILT_PRODUCTS_DIR; }; CD39C14D14EEED8700E84874 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; /* End PBXFileReference section */ @@ -147,7 +106,6 @@ files = ( CD39C14E14EEED8700E84874 /* QuartzCore.framework in Frameworks */, 250CA6D0147D90C50047D347 /* Security.framework in Frameworks */, - 250CA6CE147D90BA0047D347 /* libRestKit.a in Frameworks */, 3FB46641131D78A400E37C51 /* libxml2.dylib in Frameworks */, 1D60589F0D05DD5A006BFB54 /* Foundation.framework in Frameworks */, 1DF5F4E00D08C38300B7A737 /* UIKit.framework in Frameworks */, @@ -156,6 +114,7 @@ 2538E8671234250100ACB5D7 /* SystemConfiguration.framework in Frameworks */, 8452D3F9128244D90069F4A9 /* CFNetwork.framework in Frameworks */, 8452D3FD128244E60069F4A9 /* MobileCoreServices.framework in Frameworks */, + A4AAAC70510CB014ED4378BD /* Pods.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -164,8 +123,8 @@ buildActionMask = 2147483647; files = ( 25014086153707E2004E0466 /* QuartzCore.framework in Frameworks */, - 25014085153707CB004E0466 /* libRestKit.a in Frameworks */, 25014071153706FD004E0466 /* Security.framework in Frameworks */, + 91E489431B6604A9004B5AB5 /* libxml2.dylib in Frameworks */, 25F2A1871322D59400A33DE4 /* Foundation.framework in Frameworks */, 25F2A1881322D59400A33DE4 /* UIKit.framework in Frameworks */, 25F2A1891322D59400A33DE4 /* CoreGraphics.framework in Frameworks */, @@ -173,6 +132,7 @@ 25F2A18B1322D59400A33DE4 /* SystemConfiguration.framework in Frameworks */, 25F2A1911322D59400A33DE4 /* CFNetwork.framework in Frameworks */, 25F2A1921322D59400A33DE4 /* MobileCoreServices.framework in Frameworks */, + 91E489421B66047A004B5AB5 /* Pods.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -201,27 +161,15 @@ name = Products; sourceTree = ""; }; - 2538E800123417E500ACB5D7 /* Products */ = { - isa = PBXGroup; - children = ( - 250CA6C6147D90A50047D347 /* libRestKit.a */, - 250CA6C8147D90A50047D347 /* RestKitTests.octest */, - 250CA6CA147D90A50047D347 /* RestKit.framework */, - 250CA6CC147D90A50047D347 /* RestKitFrameworkTests.octest */, - ); - name = Products; - sourceTree = ""; - }; 29B97314FDCFA39411CA2CEA /* CustomTemplate */ = { isa = PBXGroup; children = ( - 259D0FC318076E40007C66D6 /* Default-568h@2x.png */, - 2538E7FF123417E500ACB5D7 /* RestKit.xcodeproj */, 080E96DDFE201D6D7F000001 /* Classes */, 29B97315FDCFA39411CA2CEA /* Other Sources */, 29B97317FDCFA39411CA2CEA /* Resources */, 29B97323FDCFA39411CA2CEA /* Frameworks */, 19C28FACFE9D520D11CA2CBB /* Products */, + 753DD8BB8B8DB90C68C1122C /* Pods */, ); name = CustomTemplate; sourceTree = ""; @@ -238,6 +186,7 @@ 29B97317FDCFA39411CA2CEA /* Resources */ = { isa = PBXGroup; children = ( + 259D0FC318076E40007C66D6 /* Default-568h@2x.png */, 25F2A2D813240CEC00A33DE4 /* RKSeedDatabase.sqlite */, 25F2A19A1322DCDC00A33DE4 /* users.json */, 25F2A1981322D93500A33DE4 /* restkit.json */, @@ -267,10 +216,20 @@ 8452D3F8128244D90069F4A9 /* CFNetwork.framework */, 8452D3FC128244E60069F4A9 /* MobileCoreServices.framework */, 3FB46640131D78A400E37C51 /* libxml2.dylib */, + A0702A131DA8B31559EADB35 /* Pods.framework */, ); name = Frameworks; sourceTree = ""; }; + 753DD8BB8B8DB90C68C1122C /* Pods */ = { + isa = PBXGroup; + children = ( + 4C54AB4C3537B4FFC4CDAA11 /* Pods.debug.xcconfig */, + 76894C65C72E67BEB1D13573 /* Pods.release.xcconfig */, + ); + name = Pods; + sourceTree = ""; + }; /* End PBXGroup section */ /* Begin PBXNativeTarget section */ @@ -285,7 +244,6 @@ buildRules = ( ); dependencies = ( - 3F3CE2E4125B93EB0083FDCB /* PBXTargetDependency */, ); name = RKTwitterCoreData; productName = RKTwitter; @@ -303,7 +261,6 @@ buildRules = ( ); dependencies = ( - 25F2A1761322D59400A33DE4 /* PBXTargetDependency */, ); name = "Generate Seed Database"; productName = RKTwitter; @@ -316,7 +273,7 @@ 29B97313FDCFA39411CA2CEA /* Project object */ = { isa = PBXProject; attributes = { - LastUpgradeCheck = 0500; + LastUpgradeCheck = 0700; }; buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "RKTwitterCoreData" */; compatibilityVersion = "Xcode 3.2"; @@ -330,12 +287,6 @@ ); mainGroup = 29B97314FDCFA39411CA2CEA /* CustomTemplate */; projectDirPath = ""; - projectReferences = ( - { - ProductGroup = 2538E800123417E500ACB5D7 /* Products */; - ProjectRef = 2538E7FF123417E500ACB5D7 /* RestKit.xcodeproj */; - }, - ); projectRoot = ""; targets = ( 1D6058900D05DD3D006BFB54 /* RKTwitterCoreData */, @@ -344,37 +295,6 @@ }; /* End PBXProject section */ -/* Begin PBXReferenceProxy section */ - 250CA6C6147D90A50047D347 /* libRestKit.a */ = { - isa = PBXReferenceProxy; - fileType = archive.ar; - path = libRestKit.a; - remoteRef = 250CA6C5147D90A50047D347 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; - 250CA6C8147D90A50047D347 /* RestKitTests.octest */ = { - isa = PBXReferenceProxy; - fileType = wrapper.cfbundle; - path = RestKitTests.octest; - remoteRef = 250CA6C7147D90A50047D347 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; - 250CA6CA147D90A50047D347 /* RestKit.framework */ = { - isa = PBXReferenceProxy; - fileType = wrapper.framework; - path = RestKit.framework; - remoteRef = 250CA6C9147D90A50047D347 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; - 250CA6CC147D90A50047D347 /* RestKitFrameworkTests.octest */ = { - isa = PBXReferenceProxy; - fileType = wrapper.cfbundle; - path = RestKitFrameworkTests.octest; - remoteRef = 250CA6CB147D90A50047D347 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; -/* End PBXReferenceProxy section */ - /* Begin PBXResourcesBuildPhase section */ 1D60588D0D05DD3D006BFB54 /* Resources */ = { isa = PBXResourcesBuildPhase; @@ -399,6 +319,7 @@ 25F2A19C1322DD1800A33DE4 /* users.json in Resources */, 25F2A1791322D59400A33DE4 /* listbg.png in Resources */, 25F2A17A1322D59400A33DE4 /* listbg@2x.png in Resources */, + 91E489461B660547004B5AB5 /* Default-568h@2x.png in Resources */, 25F2A17B1322D59400A33DE4 /* BG.png in Resources */, 25F2A17C1322D59400A33DE4 /* BG@2x.png in Resources */, 25F2A17D1322D59400A33DE4 /* Default.png in Resources */, @@ -437,22 +358,10 @@ }; /* End PBXSourcesBuildPhase section */ -/* Begin PBXTargetDependency section */ - 25F2A1761322D59400A33DE4 /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - name = RestKit; - targetProxy = 25F2A1771322D59400A33DE4 /* PBXContainerItemProxy */; - }; - 3F3CE2E4125B93EB0083FDCB /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - name = RestKit; - targetProxy = 3F3CE2E3125B93EB0083FDCB /* PBXContainerItemProxy */; - }; -/* End PBXTargetDependency section */ - /* Begin XCBuildConfiguration section */ 1D6058940D05DD3E006BFB54 /* Debug */ = { isa = XCBuildConfiguration; + baseConfigurationReference = 4C54AB4C3537B4FFC4CDAA11 /* Pods.debug.xcconfig */; buildSettings = { BUILD_STYLE = Debug; CLANG_ENABLE_OBJC_ARC = YES; @@ -463,14 +372,15 @@ GCC_PREFIX_HEADER = RKTwitter_Prefix.pch; HEADER_SEARCH_PATHS = "\"$(BUILT_PRODUCTS_DIR)/../../Headers\""; INFOPLIST_FILE = "Resources/RKTwitter-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 6.0; - OTHER_LDFLAGS = "-ObjC"; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + PRODUCT_BUNDLE_IDENTIFIER = "com.yourcompany.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = RKTwitterCoreData; }; name = Debug; }; 1D6058950D05DD3E006BFB54 /* Release */ = { isa = XCBuildConfiguration; + baseConfigurationReference = 76894C65C72E67BEB1D13573 /* Pods.release.xcconfig */; buildSettings = { BUILD_STYLE = Release; CLANG_ENABLE_OBJC_ARC = YES; @@ -479,8 +389,8 @@ GCC_PREFIX_HEADER = RKTwitter_Prefix.pch; HEADER_SEARCH_PATHS = "${TARGET_BUILD_DIR}/../../Headers"; INFOPLIST_FILE = "Resources/RKTwitter-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 6.0; - OTHER_LDFLAGS = "-ObjC"; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + PRODUCT_BUNDLE_IDENTIFIER = "com.yourcompany.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = RKTwitterCoreData; VALIDATE_PRODUCT = YES; }; @@ -488,6 +398,7 @@ }; 25F2A1941322D59400A33DE4 /* Debug */ = { isa = XCBuildConfiguration; + baseConfigurationReference = 4C54AB4C3537B4FFC4CDAA11 /* Pods.debug.xcconfig */; buildSettings = { BUILD_STYLE = Debug; CLANG_ENABLE_OBJC_ARC = YES; @@ -496,28 +407,35 @@ GCC_OPTIMIZATION_LEVEL = 0; GCC_PRECOMPILE_PREFIX_HEADER = YES; GCC_PREFIX_HEADER = RKTwitter_Prefix.pch; - GCC_PREPROCESSOR_DEFINITIONS = RESTKIT_GENERATE_SEED_DB; + GCC_PREPROCESSOR_DEFINITIONS = ( + RESTKIT_GENERATE_SEED_DB, + "$(inherited)", + ); HEADER_SEARCH_PATHS = "\"$(BUILT_PRODUCTS_DIR)/../../Headers\""; INFOPLIST_FILE = "Resources/RKTwitter-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 6.0; - OTHER_LDFLAGS = "-ObjC"; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + PRODUCT_BUNDLE_IDENTIFIER = "com.yourcompany.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = "Generate Seed Database"; }; name = Debug; }; 25F2A1951322D59400A33DE4 /* Release */ = { isa = XCBuildConfiguration; + baseConfigurationReference = 76894C65C72E67BEB1D13573 /* Pods.release.xcconfig */; buildSettings = { BUILD_STYLE = Release; CLANG_ENABLE_OBJC_ARC = YES; COPY_PHASE_STRIP = YES; GCC_PRECOMPILE_PREFIX_HEADER = YES; GCC_PREFIX_HEADER = RKTwitter_Prefix.pch; - GCC_PREPROCESSOR_DEFINITIONS = RESTKIT_GENERATE_SEED_DB; + GCC_PREPROCESSOR_DEFINITIONS = ( + RESTKIT_GENERATE_SEED_DB, + "$(inherited)", + ); HEADER_SEARCH_PATHS = "\"$(BUILT_PRODUCTS_DIR)/../../Headers\""; INFOPLIST_FILE = "Resources/RKTwitter-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 6.0; - OTHER_LDFLAGS = "-ObjC"; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + PRODUCT_BUNDLE_IDENTIFIER = "com.yourcompany.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = "Generate Seed Database"; VALIDATE_PRODUCT = YES; }; @@ -528,6 +446,7 @@ buildSettings = { BUILD_STYLE = Debug; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + ENABLE_TESTABILITY = YES; GCC_C_LANGUAGE_STANDARD = c99; GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES; GCC_WARN_ABOUT_RETURN_TYPE = YES; diff --git a/Examples/RKTwitterCoreData/Resources/RKTwitter-Info.plist b/Examples/RKTwitterCoreData/Resources/RKTwitter-Info.plist index f1ef695d34..07799f3e43 100644 --- a/Examples/RKTwitterCoreData/Resources/RKTwitter-Info.plist +++ b/Examples/RKTwitterCoreData/Resources/RKTwitter-Info.plist @@ -11,7 +11,7 @@ CFBundleIconFile CFBundleIdentifier - com.yourcompany.${PRODUCT_NAME:rfc1034identifier} + $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundleName diff --git a/Podfile.lock b/Podfile.lock index 4efa442371..9a43ea61ac 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -52,7 +52,7 @@ DEPENDENCIES: EXTERNAL SOURCES: RestKit: - :path: "." + :path: . SPEC CHECKSUMS: AFNetworking: cf8e418e16f0c9c7e5c3150d019a3c679d015018 @@ -60,9 +60,9 @@ SPEC CHECKSUMS: ISO8601DateFormatterValueTransformer: 3ac3a721381697cab4e792d8049ce2f2e9ad3036 OCHamcrest: e19857683e4eefab64b878668eac04c2f4567118 OCMock: a6a7dc0e3997fb9f35d99f72528698ebf60d64f2 - RestKit: 1987b5efef289c6b27bd980714d6ca48d3871b78 + RestKit: ff2e08e9e07a646e086af3f5ef3cd186c52646c6 RKCLLocationValueTransformer: 2cf0ea0fb7cd4bc70c56834fb92abc717c66f982 - RKValueTransformers: d016f1967ae67997e492520fd0f9c512ccf168ae + RKValueTransformers: 66ac5e4f077fdbe3496e792d89eeff4c3eb67701 SOCKit: c7376ac262bea9115b8f749358f762522a47d392 Specta: 15a276a6343867b426d5ed135d5aa4d04123a573 TransitionKit: 3a14b6acc7cf2d1dd3e454e24dbad1cfab9a1ef1 diff --git a/Resources/PLISTs/RestKitFrameworkTests-Info.plist b/Resources/PLISTs/RestKitFrameworkTests-Info.plist index 883b278e89..169b6f710e 100644 --- a/Resources/PLISTs/RestKitFrameworkTests-Info.plist +++ b/Resources/PLISTs/RestKitFrameworkTests-Info.plist @@ -7,7 +7,7 @@ CFBundleExecutable ${EXECUTABLE_NAME} CFBundleIdentifier - org.restkit.tests + $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundlePackageType diff --git a/Resources/PLISTs/RestKitTests-Info.plist b/Resources/PLISTs/RestKitTests-Info.plist index 883b278e89..169b6f710e 100644 --- a/Resources/PLISTs/RestKitTests-Info.plist +++ b/Resources/PLISTs/RestKitTests-Info.plist @@ -7,7 +7,7 @@ CFBundleExecutable ${EXECUTABLE_NAME} CFBundleIdentifier - org.restkit.tests + $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundlePackageType diff --git a/RestKit.xcodeproj/project.pbxproj b/RestKit.xcodeproj/project.pbxproj index 7d4dc6d4d8..af99d7f9b5 100644 --- a/RestKit.xcodeproj/project.pbxproj +++ b/RestKit.xcodeproj/project.pbxproj @@ -1899,7 +1899,7 @@ isa = PBXProject; attributes = { LastTestingUpgradeCheck = 0510; - LastUpgradeCheck = 0600; + LastUpgradeCheck = 0700; ORGANIZATIONNAME = RestKit; }; buildConfigurationList = 25160D1014564E810060A5C5 /* Build configuration list for PBXProject "RestKit" */; @@ -2497,8 +2497,10 @@ CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; COPY_PHASE_STRIP = NO; ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; GCC_OPTIMIZATION_LEVEL = 0; GCC_PREPROCESSOR_DEFINITIONS = ( "DEBUG=1", @@ -2536,6 +2538,7 @@ COPY_PHASE_STRIP = NO; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES; @@ -2602,6 +2605,7 @@ GCC_PREFIX_HEADER = "Code/Support/RestKit-Prefix.pch"; INFOPLIST_FILE = "Resources/PLISTs/RestKitTests-Info.plist"; OBJROOT = "$(SRCROOT)/Build"; + PRODUCT_BUNDLE_IDENTIFIER = org.restkit.tests; PRODUCT_NAME = "$(TARGET_NAME)"; SYMROOT = "$(SRCROOT)/Build/Products"; }; @@ -2621,6 +2625,7 @@ GCC_PREFIX_HEADER = "Code/Support/RestKit-Prefix.pch"; INFOPLIST_FILE = "Resources/PLISTs/RestKitTests-Info.plist"; OBJROOT = "$(SRCROOT)/Build"; + PRODUCT_BUNDLE_IDENTIFIER = org.restkit.tests; PRODUCT_NAME = "$(TARGET_NAME)"; SYMROOT = "$(SRCROOT)/Build/Products"; }; @@ -2698,6 +2703,7 @@ INFOPLIST_FILE = "Resources/PLISTs/RestKitFrameworkTests-Info.plist"; MACOSX_DEPLOYMENT_TARGET = 10.7; ONLY_ACTIVE_ARCH = YES; + PRODUCT_BUNDLE_IDENTIFIER = org.restkit.tests; PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = macosx; }; @@ -2717,6 +2723,7 @@ GCC_WARN_64_TO_32_BIT_CONVERSION = YES; INFOPLIST_FILE = "Resources/PLISTs/RestKitFrameworkTests-Info.plist"; MACOSX_DEPLOYMENT_TARGET = 10.7; + PRODUCT_BUNDLE_IDENTIFIER = org.restkit.tests; PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = macosx; }; From 948ae92a425552ccfd2a9e5cc9266b17f33f4473 Mon Sep 17 00:00:00 2001 From: Adolfo Martinelli Date: Mon, 27 Jul 2015 00:44:48 -0700 Subject: [PATCH 25/94] Update CI test with updated build scheme name --- Rakefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Rakefile b/Rakefile index 8e354dfe21..82a4530c73 100644 --- a/Rakefile +++ b/Rakefile @@ -34,7 +34,7 @@ namespace :test do task :building_without_core_data do title 'Testing without Core Data' run("cd Examples/RKTwitter && pod install") - run("xctool -workspace Examples/RKTwitter/RKTwitter.xcworkspace -scheme RKTwitterCocoaPods -sdk iphonesimulator clean build ONLY_ACTIVE_ARCH=NO") + run("xctool -workspace Examples/RKTwitter/RKTwitter.xcworkspace -scheme RKTwitter -sdk iphonesimulator clean build ONLY_ACTIVE_ARCH=NO") end end From 323bf8883b5d0f1f2f550fd8a1be17293ca148d9 Mon Sep 17 00:00:00 2001 From: Adolfo Martinelli Date: Mon, 27 Jul 2015 01:07:01 -0700 Subject: [PATCH 26/94] Save RKTwitter build scheme for CI --- .../xcshareddata/xcschemes/RKTwitter.xcscheme | 91 +++++++++++++++++++ 1 file changed, 91 insertions(+) create mode 100644 Examples/RKTwitter/RKTwitter.xcodeproj/xcshareddata/xcschemes/RKTwitter.xcscheme diff --git a/Examples/RKTwitter/RKTwitter.xcodeproj/xcshareddata/xcschemes/RKTwitter.xcscheme b/Examples/RKTwitter/RKTwitter.xcodeproj/xcshareddata/xcschemes/RKTwitter.xcscheme new file mode 100644 index 0000000000..2480cf7a25 --- /dev/null +++ b/Examples/RKTwitter/RKTwitter.xcodeproj/xcshareddata/xcschemes/RKTwitter.xcscheme @@ -0,0 +1,91 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 3c43765acbc24dc4f2d4e13725109b0f551c1852 Mon Sep 17 00:00:00 2001 From: "Samuel E. Giddins" Date: Thu, 6 Aug 2015 23:05:12 -0700 Subject: [PATCH 27/94] [Podspec] Bumpe ISO8601 dependency --- Gemfile.lock | 18 +++++++++--------- Podfile.lock | 14 +++++++------- RestKit.podspec | 2 +- 3 files changed, 17 insertions(+), 17 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 1332e29096..d14a9b2ba5 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -9,10 +9,10 @@ GEM tzinfo (~> 1.1) backports (3.6.5) claide (0.9.1) - cocoapods (0.38.0) + cocoapods (0.38.2) activesupport (>= 3.2.15) claide (~> 0.9.1) - cocoapods-core (= 0.38.0) + cocoapods-core (= 0.38.2) cocoapods-downloader (~> 0.9.1) cocoapods-plugins (~> 0.4.2) cocoapods-stats (~> 0.5.3) @@ -20,10 +20,10 @@ GEM cocoapods-try (~> 0.4.5) colored (~> 1.2) escape (~> 0.0.4) - molinillo (~> 0.3.0) + molinillo (~> 0.3.1) nap (~> 0.8) - xcodeproj (~> 0.26.2) - cocoapods-core (0.38.0) + xcodeproj (~> 0.26.3) + cocoapods-core (0.38.2) activesupport (>= 3.2.15) fuzzy_match (~> 2.0.4) nap (~> 0.8.0) @@ -44,8 +44,8 @@ GEM i18n (0.7.0) json (1.8.3) mini_portile (0.6.2) - minitest (5.7.0) - molinillo (0.3.0) + minitest (5.8.0) + molinillo (0.3.1) multi_json (1.11.2) nap (0.8.0) netrc (0.7.8) @@ -79,7 +79,7 @@ GEM tilt (2.0.1) tzinfo (1.2.2) thread_safe (~> 0.1) - xcodeproj (0.26.2) + xcodeproj (0.26.3) activesupport (>= 3) claide (~> 0.9.1) colored (~> 1.2) @@ -101,4 +101,4 @@ DEPENDENCIES xctasks (~> 0.5.0) BUNDLED WITH - 1.10.5 + 1.10.6 diff --git a/Podfile.lock b/Podfile.lock index 9a43ea61ac..de1373e6ad 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -1,7 +1,7 @@ PODS: - AFNetworking (1.3.4) - Expecta (0.3.1) - - ISO8601DateFormatterValueTransformer (0.6.0): + - ISO8601DateFormatterValueTransformer (0.6.1): - RKValueTransformers (~> 1.1.0) - OCHamcrest (3.0.1) - OCMock (2.2.4) @@ -19,7 +19,7 @@ PODS: - RestKit/Support - SOCKit - RestKit/ObjectMapping (0.24.1): - - ISO8601DateFormatterValueTransformer (~> 0.6.0) + - ISO8601DateFormatterValueTransformer (~> 0.6.1) - RestKit/Support - RKValueTransformers (~> 1.1.0) - RestKit/Search (0.24.1): @@ -38,7 +38,7 @@ PODS: DEPENDENCIES: - AFNetworking (~> 1.3.0) - Expecta (= 0.3.1) - - ISO8601DateFormatterValueTransformer (~> 0.6.0) + - ISO8601DateFormatterValueTransformer (~> 0.6.1) - OCHamcrest (= 3.0.1) - OCMock (= 2.2.4) - RestKit (from `.`) @@ -52,19 +52,19 @@ DEPENDENCIES: EXTERNAL SOURCES: RestKit: - :path: . + :path: "." SPEC CHECKSUMS: AFNetworking: cf8e418e16f0c9c7e5c3150d019a3c679d015018 Expecta: a354d4633409dd9fe8c4f5ff5130426adbe31628 - ISO8601DateFormatterValueTransformer: 3ac3a721381697cab4e792d8049ce2f2e9ad3036 + ISO8601DateFormatterValueTransformer: 52da467d6ec899d6aedda8e48280ac92e8ee97e6 OCHamcrest: e19857683e4eefab64b878668eac04c2f4567118 OCMock: a6a7dc0e3997fb9f35d99f72528698ebf60d64f2 - RestKit: ff2e08e9e07a646e086af3f5ef3cd186c52646c6 + RestKit: 33136570f562b33da16c65dc322a82872bc18160 RKCLLocationValueTransformer: 2cf0ea0fb7cd4bc70c56834fb92abc717c66f982 RKValueTransformers: 66ac5e4f077fdbe3496e792d89eeff4c3eb67701 SOCKit: c7376ac262bea9115b8f749358f762522a47d392 Specta: 15a276a6343867b426d5ed135d5aa4d04123a573 TransitionKit: 3a14b6acc7cf2d1dd3e454e24dbad1cfab9a1ef1 -COCOAPODS: 0.37.2 +COCOAPODS: 0.38.2 diff --git a/RestKit.podspec b/RestKit.podspec index b1e668f012..40cf059c40 100644 --- a/RestKit.podspec +++ b/RestKit.podspec @@ -38,7 +38,7 @@ EOS os.source_files = 'Code/ObjectMapping.h', 'Code/ObjectMapping' os.dependency 'RestKit/Support' os.dependency 'RKValueTransformers', '~> 1.1.0' - os.dependency 'ISO8601DateFormatterValueTransformer', '~> 0.6.0' + os.dependency 'ISO8601DateFormatterValueTransformer', '~> 0.6.1' end s.subspec 'Network' do |ns| From fecde9da46b60ee34ab617ce4774d45b1414e464 Mon Sep 17 00:00:00 2001 From: "Samuel E. Giddins" Date: Thu, 6 Aug 2015 23:11:04 -0700 Subject: [PATCH 28/94] Release v0.25.0 --- Podfile.lock | 20 ++++++++++---------- RestKit.podspec | 2 +- VERSION | 2 +- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/Podfile.lock b/Podfile.lock index de1373e6ad..be721f31d4 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -5,28 +5,28 @@ PODS: - RKValueTransformers (~> 1.1.0) - OCHamcrest (3.0.1) - OCMock (2.2.4) - - RestKit (0.24.1): - - RestKit/Core (= 0.24.1) - - RestKit/Core (0.24.1): + - RestKit (0.25.0): + - RestKit/Core (= 0.25.0) + - RestKit/Core (0.25.0): - RestKit/CoreData - RestKit/Network - RestKit/ObjectMapping - - RestKit/CoreData (0.24.1): + - RestKit/CoreData (0.25.0): - RestKit/ObjectMapping - - RestKit/Network (0.24.1): + - RestKit/Network (0.25.0): - AFNetworking (~> 1.3.0) - RestKit/ObjectMapping - RestKit/Support - SOCKit - - RestKit/ObjectMapping (0.24.1): + - RestKit/ObjectMapping (0.25.0): - ISO8601DateFormatterValueTransformer (~> 0.6.1) - RestKit/Support - RKValueTransformers (~> 1.1.0) - - RestKit/Search (0.24.1): + - RestKit/Search (0.25.0): - RestKit/CoreData - - RestKit/Support (0.24.1): + - RestKit/Support (0.25.0): - TransitionKit (~> 2.1.0) - - RestKit/Testing (0.24.1): + - RestKit/Testing (0.25.0): - RestKit/Network - RKCLLocationValueTransformer (1.1.0): - RKValueTransformers (~> 1.1.0) @@ -60,7 +60,7 @@ SPEC CHECKSUMS: ISO8601DateFormatterValueTransformer: 52da467d6ec899d6aedda8e48280ac92e8ee97e6 OCHamcrest: e19857683e4eefab64b878668eac04c2f4567118 OCMock: a6a7dc0e3997fb9f35d99f72528698ebf60d64f2 - RestKit: 33136570f562b33da16c65dc322a82872bc18160 + RestKit: a4fcaf3d4bb2c204679856a46d596160bf208095 RKCLLocationValueTransformer: 2cf0ea0fb7cd4bc70c56834fb92abc717c66f982 RKValueTransformers: 66ac5e4f077fdbe3496e792d89eeff4c3eb67701 SOCKit: c7376ac262bea9115b8f749358f762522a47d392 diff --git a/RestKit.podspec b/RestKit.podspec index 40cf059c40..75990c83ec 100644 --- a/RestKit.podspec +++ b/RestKit.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'RestKit' - s.version = '0.24.1' + s.version = '0.25.0' s.summary = 'RestKit is a framework for consuming and modeling RESTful web resources on iOS and OS X.' s.homepage = 'https://github.com/RestKit/RestKit' s.social_media_url = 'https://twitter.com/RestKit' diff --git a/VERSION b/VERSION index 48b91fd89c..d21d277be5 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.24.1 +0.25.0 From 8fd542415248857305781de7afd1817b4aac8c7f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roger=20Jo=CC=88nsson?= Date: Thu, 13 Aug 2015 16:36:53 +0200 Subject: [PATCH 29/94] Assign used properties of NSDateComponents object to zero before use. They default to NSUndefinedDateComponent (NSIntegerMax), which caused string conversions to NSDate to fail when using the latest SDKs. The changed method (_parseHTTPDate) is used by RKDateFromHTTPDateString and indirectly by RKHTTPCacheExpirationDateFromHeadersWithStatusCode. --- Code/ObjectMapping/RKHTTPUtilities.m | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Code/ObjectMapping/RKHTTPUtilities.m b/Code/ObjectMapping/RKHTTPUtilities.m index 1b4aafe657..d659b9bfd1 100644 --- a/Code/ObjectMapping/RKHTTPUtilities.m +++ b/Code/ObjectMapping/RKHTTPUtilities.m @@ -350,6 +350,12 @@ RKRequestMethod RKRequestMethodFromString(NSString *methodName) memset(&gdate, 0, sizeof(CFGregorianDate)); #else NSDateComponents *gdate = [[NSDateComponents alloc] init]; + gdate.year = 0; + gdate.month = 0; + gdate.day = 0; + gdate.hour = 0; + gdate.minute = 0; + gdate.second = 0; #endif { From e1cbf49dbea51eb4d622c561ff57b12544c3bde0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roger=20Jo=CC=88nsson?= Date: Fri, 14 Aug 2015 09:39:11 +0200 Subject: [PATCH 30/94] Test failing with RestKit v0.25.0, if this define is true at compile time (which it is for later SDKs): #if (defined(__IPHONE_OS_VERSION_MAX_ALLOWED) && (__IPHONE_OS_VERSION_MAX_ALLOWED < 70000)) || \ (defined(MAC_OS_X_VERSION_MAX_ALLOWED) && (MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_9)) The code was broken by commit 36955d4d3c85bd02aa9c32eb71c04634ce0f8f34 on Jul 21, 2015. A fix of a warning introduced an error. --- Tests/Logic/Support/RKHTTPUtilitiesTest.m | 34 +++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/Tests/Logic/Support/RKHTTPUtilitiesTest.m b/Tests/Logic/Support/RKHTTPUtilitiesTest.m index 5c2905a37e..c2476d2271 100644 --- a/Tests/Logic/Support/RKHTTPUtilitiesTest.m +++ b/Tests/Logic/Support/RKHTTPUtilitiesTest.m @@ -137,4 +137,38 @@ - (void)testRequestMethodStringForCompoundValueReturnsNil expect(RKStringFromRequestMethod(RKRequestMethodGET|RKRequestMethodDELETE)).to.beNil(); } +- (void)testRKDateFromHTTPDateString +{ + void (^testBlock)(NSDateComponents *) = ^void(NSDateComponents *dateComponents) { + NSDateFormatter * const dateFormatter = [[NSDateFormatter alloc] init]; + dateFormatter.locale = [[NSLocale alloc] initWithLocaleIdentifier:@"en_US"]; + dateFormatter.timeZone = [NSTimeZone timeZoneWithAbbreviation:@"GMT"]; + dateFormatter.dateFormat = @"EEE',' dd MMM yyyy HH':'mm':'ss z"; + + NSCalendar * const calendar = [[NSCalendar alloc] initWithCalendarIdentifier:NSCalendarIdentifierGregorian]; + calendar.timeZone = [NSTimeZone timeZoneForSecondsFromGMT:0]; + + NSDate * const sourceDate = [calendar dateFromComponents:dateComponents]; + NSString * const sourceString = [dateFormatter stringFromDate:sourceDate]; + NSDate * const destdate = RKDateFromHTTPDateString(sourceString); + expect(destdate).to.equal(sourceDate); + }; + + NSDateComponents * const dateComponents = [[NSDateComponents alloc] init]; + dateComponents.hour = 0; dateComponents.minute = 0; dateComponents.second = 0; + + // epoch + dateComponents.year = 1970; dateComponents.month = 1; dateComponents.day = 1; + testBlock(dateComponents); + + // pre epoc + dateComponents.year = 1969; dateComponents.month = 1; dateComponents.day = 27; + testBlock(dateComponents); + + // release of U2's Achtung Baby album + dateComponents.year = 1991; dateComponents.month = 11; dateComponents.day = 18; + dateComponents.hour = 12; dateComponents.minute = 34; dateComponents.second = 56; + testBlock(dateComponents); +} + @end From 2afb3c75cd942e1e00b4fcaa21e45abad69919c1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roger=20Jo=CC=88nsson?= Date: Sun, 16 Aug 2015 13:37:35 +0200 Subject: [PATCH 31/94] Indent with spaces. --- Code/ObjectMapping/RKHTTPUtilities.m | 12 ++--- Tests/Logic/Support/RKHTTPUtilitiesTest.m | 60 +++++++++++------------ 2 files changed, 36 insertions(+), 36 deletions(-) diff --git a/Code/ObjectMapping/RKHTTPUtilities.m b/Code/ObjectMapping/RKHTTPUtilities.m index d659b9bfd1..046a3edb99 100644 --- a/Code/ObjectMapping/RKHTTPUtilities.m +++ b/Code/ObjectMapping/RKHTTPUtilities.m @@ -350,12 +350,12 @@ RKRequestMethod RKRequestMethodFromString(NSString *methodName) memset(&gdate, 0, sizeof(CFGregorianDate)); #else NSDateComponents *gdate = [[NSDateComponents alloc] init]; - gdate.year = 0; - gdate.month = 0; - gdate.day = 0; - gdate.hour = 0; - gdate.minute = 0; - gdate.second = 0; + gdate.year = 0; + gdate.month = 0; + gdate.day = 0; + gdate.hour = 0; + gdate.minute = 0; + gdate.second = 0; #endif { diff --git a/Tests/Logic/Support/RKHTTPUtilitiesTest.m b/Tests/Logic/Support/RKHTTPUtilitiesTest.m index c2476d2271..1493272979 100644 --- a/Tests/Logic/Support/RKHTTPUtilitiesTest.m +++ b/Tests/Logic/Support/RKHTTPUtilitiesTest.m @@ -139,36 +139,36 @@ - (void)testRequestMethodStringForCompoundValueReturnsNil - (void)testRKDateFromHTTPDateString { - void (^testBlock)(NSDateComponents *) = ^void(NSDateComponents *dateComponents) { - NSDateFormatter * const dateFormatter = [[NSDateFormatter alloc] init]; - dateFormatter.locale = [[NSLocale alloc] initWithLocaleIdentifier:@"en_US"]; - dateFormatter.timeZone = [NSTimeZone timeZoneWithAbbreviation:@"GMT"]; - dateFormatter.dateFormat = @"EEE',' dd MMM yyyy HH':'mm':'ss z"; - - NSCalendar * const calendar = [[NSCalendar alloc] initWithCalendarIdentifier:NSCalendarIdentifierGregorian]; - calendar.timeZone = [NSTimeZone timeZoneForSecondsFromGMT:0]; - - NSDate * const sourceDate = [calendar dateFromComponents:dateComponents]; - NSString * const sourceString = [dateFormatter stringFromDate:sourceDate]; - NSDate * const destdate = RKDateFromHTTPDateString(sourceString); - expect(destdate).to.equal(sourceDate); - }; - - NSDateComponents * const dateComponents = [[NSDateComponents alloc] init]; - dateComponents.hour = 0; dateComponents.minute = 0; dateComponents.second = 0; - - // epoch - dateComponents.year = 1970; dateComponents.month = 1; dateComponents.day = 1; - testBlock(dateComponents); - - // pre epoc - dateComponents.year = 1969; dateComponents.month = 1; dateComponents.day = 27; - testBlock(dateComponents); - - // release of U2's Achtung Baby album - dateComponents.year = 1991; dateComponents.month = 11; dateComponents.day = 18; - dateComponents.hour = 12; dateComponents.minute = 34; dateComponents.second = 56; - testBlock(dateComponents); + void (^testBlock)(NSDateComponents *) = ^void(NSDateComponents *dateComponents) { + NSDateFormatter * const dateFormatter = [[NSDateFormatter alloc] init]; + dateFormatter.locale = [[NSLocale alloc] initWithLocaleIdentifier:@"en_US"]; + dateFormatter.timeZone = [NSTimeZone timeZoneWithAbbreviation:@"GMT"]; + dateFormatter.dateFormat = @"EEE',' dd MMM yyyy HH':'mm':'ss z"; + + NSCalendar * const calendar = [[NSCalendar alloc] initWithCalendarIdentifier:NSCalendarIdentifierGregorian]; + calendar.timeZone = [NSTimeZone timeZoneForSecondsFromGMT:0]; + + NSDate * const sourceDate = [calendar dateFromComponents:dateComponents]; + NSString * const sourceString = [dateFormatter stringFromDate:sourceDate]; + NSDate * const destdate = RKDateFromHTTPDateString(sourceString); + expect(destdate).to.equal(sourceDate); + }; + + NSDateComponents * const dateComponents = [[NSDateComponents alloc] init]; + dateComponents.hour = 0; dateComponents.minute = 0; dateComponents.second = 0; + + // epoch + dateComponents.year = 1970; dateComponents.month = 1; dateComponents.day = 1; + testBlock(dateComponents); + + // pre epoc + dateComponents.year = 1969; dateComponents.month = 1; dateComponents.day = 27; + testBlock(dateComponents); + + // release of U2's Achtung Baby album + dateComponents.year = 1991; dateComponents.month = 11; dateComponents.day = 18; + dateComponents.hour = 12; dateComponents.minute = 34; dateComponents.second = 56; + testBlock(dateComponents); } @end From 8637490eac76afd7f828bcb39e4bba9902bc3f1a Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Tue, 25 Aug 2015 13:20:01 -0600 Subject: [PATCH 32/94] Log core data save errors on the context's queue to avoid multithreading violation --- Code/Network/RKManagedObjectRequestOperation.m | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/Code/Network/RKManagedObjectRequestOperation.m b/Code/Network/RKManagedObjectRequestOperation.m index df3ff6c748..8dc584b58a 100644 --- a/Code/Network/RKManagedObjectRequestOperation.m +++ b/Code/Network/RKManagedObjectRequestOperation.m @@ -827,9 +827,13 @@ - (BOOL)saveContext:(NSManagedObjectContext *)context error:(NSError **)error }]; } } else { - if (error) *error = localError; - RKLogError(@"Failed saving managed object context %@ %@: %@", (self.savesToPersistentStore ? @"to the persistent store" : @""), context, localError); - RKLogCoreDataError(localError); + if (error) *error = localError; + // Logging the error requires calling -[NSManagedObject description] which + // can only be done on the context's queue + [self.managedObjectContext performBlock:^{ + RKLogError(@"Failed saving managed object context %@ %@: %@", (self.savesToPersistentStore ? @"to the persistent store" : @""), context, localError); + RKLogCoreDataError(localError); + }]; } return success; From 098a8fa7f1401cd5f14360ef368dc7c20eb252f2 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Tue, 25 Aug 2015 13:22:30 -0600 Subject: [PATCH 33/94] Fix indentation --- Code/Network/RKManagedObjectRequestOperation.m | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/Code/Network/RKManagedObjectRequestOperation.m b/Code/Network/RKManagedObjectRequestOperation.m index 8dc584b58a..cead16ae4f 100644 --- a/Code/Network/RKManagedObjectRequestOperation.m +++ b/Code/Network/RKManagedObjectRequestOperation.m @@ -827,13 +827,13 @@ - (BOOL)saveContext:(NSManagedObjectContext *)context error:(NSError **)error }]; } } else { - if (error) *error = localError; - // Logging the error requires calling -[NSManagedObject description] which - // can only be done on the context's queue - [self.managedObjectContext performBlock:^{ - RKLogError(@"Failed saving managed object context %@ %@: %@", (self.savesToPersistentStore ? @"to the persistent store" : @""), context, localError); - RKLogCoreDataError(localError); - }]; + if (error) *error = localError; + // Logging the error requires calling -[NSManagedObject description] which + // can only be done on the context's queue + [self.managedObjectContext performBlock:^{ + RKLogError(@"Failed saving managed object context %@ %@: %@", (self.savesToPersistentStore ? @"to the persistent store" : @""), context, localError); + RKLogCoreDataError(localError); + }]; } return success; From bb5889de293b2b199fcfda2f91736283faaa556f Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Tue, 25 Aug 2015 13:26:23 -0600 Subject: [PATCH 34/94] Update project settings to use spaces not tabs --- Examples/RKMacOSX/RKMacOSX.xcodeproj/project.pbxproj | 1 + .../RKSearchExample/RKSearchExample.xcodeproj/project.pbxproj | 1 + Examples/RKTwitter/RKTwitter.xcodeproj/project.pbxproj | 1 + .../RKTwitterCoreData.xcodeproj/project.pbxproj | 1 + RestKit.xcodeproj/project.pbxproj | 3 ++- 5 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Examples/RKMacOSX/RKMacOSX.xcodeproj/project.pbxproj b/Examples/RKMacOSX/RKMacOSX.xcodeproj/project.pbxproj index edc74bccd4..1207602835 100644 --- a/Examples/RKMacOSX/RKMacOSX.xcodeproj/project.pbxproj +++ b/Examples/RKMacOSX/RKMacOSX.xcodeproj/project.pbxproj @@ -66,6 +66,7 @@ F73078E151260A102FEB82F9 /* Pods */, ); sourceTree = ""; + usesTabs = 0; }; 25D63915135184CE000879B1 /* Products */ = { isa = PBXGroup; diff --git a/Examples/RKSearchExample/RKSearchExample.xcodeproj/project.pbxproj b/Examples/RKSearchExample/RKSearchExample.xcodeproj/project.pbxproj index bfed36b67e..c5fe0c7f67 100644 --- a/Examples/RKSearchExample/RKSearchExample.xcodeproj/project.pbxproj +++ b/Examples/RKSearchExample/RKSearchExample.xcodeproj/project.pbxproj @@ -89,6 +89,7 @@ 8045C6A1DC1A7B372A75E95F /* Pods */, ); sourceTree = ""; + usesTabs = 0; }; 259C7FF715D20B5600F447D2 /* Products */ = { isa = PBXGroup; diff --git a/Examples/RKTwitter/RKTwitter.xcodeproj/project.pbxproj b/Examples/RKTwitter/RKTwitter.xcodeproj/project.pbxproj index 544005ba79..5a0ec789fc 100755 --- a/Examples/RKTwitter/RKTwitter.xcodeproj/project.pbxproj +++ b/Examples/RKTwitter/RKTwitter.xcodeproj/project.pbxproj @@ -113,6 +113,7 @@ ); name = CustomTemplate; sourceTree = ""; + usesTabs = 0; }; 29B97315FDCFA39411CA2CEA /* Other Sources */ = { isa = PBXGroup; diff --git a/Examples/RKTwitterCoreData/RKTwitterCoreData.xcodeproj/project.pbxproj b/Examples/RKTwitterCoreData/RKTwitterCoreData.xcodeproj/project.pbxproj index 06e7d32318..4798afb517 100755 --- a/Examples/RKTwitterCoreData/RKTwitterCoreData.xcodeproj/project.pbxproj +++ b/Examples/RKTwitterCoreData/RKTwitterCoreData.xcodeproj/project.pbxproj @@ -173,6 +173,7 @@ ); name = CustomTemplate; sourceTree = ""; + usesTabs = 0; }; 29B97315FDCFA39411CA2CEA /* Other Sources */ = { isa = PBXGroup; diff --git a/RestKit.xcodeproj/project.pbxproj b/RestKit.xcodeproj/project.pbxproj index af99d7f9b5..e8f4aea04d 100644 --- a/RestKit.xcodeproj/project.pbxproj +++ b/RestKit.xcodeproj/project.pbxproj @@ -883,12 +883,12 @@ 73D3907114CA19F90093E3D6 /* parent.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = parent.json; sourceTree = ""; }; 73D3907314CA1A4A0093E3D6 /* child.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = child.json; sourceTree = ""; }; 73D3907814CA1D710093E3D6 /* channels.xml */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = channels.xml; sourceTree = ""; }; + 8AB68F0A1AE5B3B300DD655A /* RKFetchedResultsControllerUpdateTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKFetchedResultsControllerUpdateTest.m; sourceTree = ""; }; 9B15BBB1F11B91C32F72DFBF /* libPods-RestKitFramework.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-RestKitFramework.a"; sourceTree = BUILT_PRODUCTS_DIR; }; A339C3AFD7C094BEAFE92A93 /* Pods-ios.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ios.release.xcconfig"; path = "Pods/Target Support Files/Pods-ios/Pods-ios.release.xcconfig"; sourceTree = ""; }; A920AEDAEC3C6599433D2720 /* Pods-osx.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-osx.debug.xcconfig"; path = "Pods/Target Support Files/Pods-osx/Pods-osx.debug.xcconfig"; sourceTree = ""; }; AD144E244684975F290D70ED /* Pods-RestKit.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RestKit.release.xcconfig"; path = "Pods/Target Support Files/Pods-RestKit/Pods-RestKit.release.xcconfig"; sourceTree = ""; }; AD2DD8D9C9EA769B53865C88 /* Pods-RestKit.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RestKit.debug.xcconfig"; path = "Pods/Target Support Files/Pods-RestKit/Pods-RestKit.debug.xcconfig"; sourceTree = ""; }; - 8AB68F0A1AE5B3B300DD655A /* RKFetchedResultsControllerUpdateTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKFetchedResultsControllerUpdateTest.m; sourceTree = ""; }; BE05BDCF1782109F00F7C9C9 /* RKRouteTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKRouteTest.m; sourceTree = ""; }; C0F11CE1190883380054AEA0 /* RKPathMatcher.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKPathMatcher.h; sourceTree = ""; }; C0F11CE2190883380054AEA0 /* RKPathMatcher.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKPathMatcher.m; sourceTree = ""; }; @@ -1010,6 +1010,7 @@ 21C3ABBAD1E23EF5D671E158 /* Pods */, ); sourceTree = ""; + usesTabs = 0; }; 25160D1714564E810060A5C5 /* Products */ = { isa = PBXGroup; From edc0d66b97fd1320b045e5a450ec733c753491b4 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Tue, 25 Aug 2015 13:28:24 -0600 Subject: [PATCH 35/94] Discard irrelevant change --- RestKit.xcodeproj/project.pbxproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/RestKit.xcodeproj/project.pbxproj b/RestKit.xcodeproj/project.pbxproj index e8f4aea04d..ee6bd30e8c 100644 --- a/RestKit.xcodeproj/project.pbxproj +++ b/RestKit.xcodeproj/project.pbxproj @@ -883,12 +883,12 @@ 73D3907114CA19F90093E3D6 /* parent.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = parent.json; sourceTree = ""; }; 73D3907314CA1A4A0093E3D6 /* child.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = child.json; sourceTree = ""; }; 73D3907814CA1D710093E3D6 /* channels.xml */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = channels.xml; sourceTree = ""; }; - 8AB68F0A1AE5B3B300DD655A /* RKFetchedResultsControllerUpdateTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKFetchedResultsControllerUpdateTest.m; sourceTree = ""; }; 9B15BBB1F11B91C32F72DFBF /* libPods-RestKitFramework.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-RestKitFramework.a"; sourceTree = BUILT_PRODUCTS_DIR; }; A339C3AFD7C094BEAFE92A93 /* Pods-ios.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ios.release.xcconfig"; path = "Pods/Target Support Files/Pods-ios/Pods-ios.release.xcconfig"; sourceTree = ""; }; A920AEDAEC3C6599433D2720 /* Pods-osx.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-osx.debug.xcconfig"; path = "Pods/Target Support Files/Pods-osx/Pods-osx.debug.xcconfig"; sourceTree = ""; }; AD144E244684975F290D70ED /* Pods-RestKit.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RestKit.release.xcconfig"; path = "Pods/Target Support Files/Pods-RestKit/Pods-RestKit.release.xcconfig"; sourceTree = ""; }; AD2DD8D9C9EA769B53865C88 /* Pods-RestKit.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RestKit.debug.xcconfig"; path = "Pods/Target Support Files/Pods-RestKit/Pods-RestKit.debug.xcconfig"; sourceTree = ""; }; + 8AB68F0A1AE5B3B300DD655A /* RKFetchedResultsControllerUpdateTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKFetchedResultsControllerUpdateTest.m; sourceTree = ""; }; BE05BDCF1782109F00F7C9C9 /* RKRouteTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKRouteTest.m; sourceTree = ""; }; C0F11CE1190883380054AEA0 /* RKPathMatcher.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKPathMatcher.h; sourceTree = ""; }; C0F11CE2190883380054AEA0 /* RKPathMatcher.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKPathMatcher.m; sourceTree = ""; }; From 8c93e303b8ded0563d50d8d28facc3d427960834 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Tue, 25 Aug 2015 13:33:40 -0600 Subject: [PATCH 36/94] Document how to enable RestKit in a Swift project --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index a963eac306..3b95a8fe74 100644 --- a/README.md +++ b/README.md @@ -615,6 +615,10 @@ Please note that if your installation fails, it may be because you are installin Detailed installation instructions are available in the [Visual Install Guide](https://github.com/RestKit/RestKit/wiki/Installing-RestKit-v0.20.x-as-a-Git-Submodule) on the Wiki. +## Using RestKit in a Swift Project + +Install RestKit using one of the above methods, then add `#import ` into the bridging header for your Swift project. To enable the Core Data functionality in RestKit, add `@import CoreData;` into your bridging header _before_ you import `RestKit.h`. + ## License RestKit is licensed under the terms of the [Apache License, version 2.0](http://www.apache.org/licenses/LICENSE-2.0.html). Please see the [LICENSE](LICENSE) file for full details. From c00a49a23163be1d441ed72cb1d4b1992ff99fb6 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Tue, 25 Aug 2015 13:41:52 -0600 Subject: [PATCH 37/94] Use the right context --- Code/Network/RKManagedObjectRequestOperation.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Network/RKManagedObjectRequestOperation.m b/Code/Network/RKManagedObjectRequestOperation.m index cead16ae4f..55fde3a92e 100644 --- a/Code/Network/RKManagedObjectRequestOperation.m +++ b/Code/Network/RKManagedObjectRequestOperation.m @@ -830,7 +830,7 @@ - (BOOL)saveContext:(NSManagedObjectContext *)context error:(NSError **)error if (error) *error = localError; // Logging the error requires calling -[NSManagedObject description] which // can only be done on the context's queue - [self.managedObjectContext performBlock:^{ + [context performBlock:^{ RKLogError(@"Failed saving managed object context %@ %@: %@", (self.savesToPersistentStore ? @"to the persistent store" : @""), context, localError); RKLogCoreDataError(localError); }]; From cd5c77abe463a19d9d154e48da226b5345385491 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Tue, 25 Aug 2015 13:56:27 -0600 Subject: [PATCH 38/94] Log core data save errors in the queue for the context where the error occurred --- Code/Network/RKManagedObjectRequestOperation.m | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/Code/Network/RKManagedObjectRequestOperation.m b/Code/Network/RKManagedObjectRequestOperation.m index 55fde3a92e..61b7b9a61a 100644 --- a/Code/Network/RKManagedObjectRequestOperation.m +++ b/Code/Network/RKManagedObjectRequestOperation.m @@ -778,7 +778,7 @@ - (BOOL)deleteLocalObjectsMissingFromMappingResult:(RKMappingResult *)mappingRes /** NOTE: This is more or less a direct port of the functionality provided by `[NSManagedObjectContext saveToPersistentStore:]` in the `RKAdditions` category. We have duplicated the logic here to add in support for checking if the operation has been cancelled since we began cascading up the MOC chain. Because each `performBlockAndWait:` invocation essentially jumps threads and is subject to the availability of the context, it is very possible for the operation to be cancelled during this part of the operation's lifecycle. */ -- (BOOL)saveContextToPersistentStore:(NSManagedObjectContext *)contextToSave error:(NSError **)error +- (BOOL)saveContextToPersistentStore:(NSManagedObjectContext *)contextToSave failedContext:(NSManagedObjectContext **)failedContext error:(NSError **)error { __block NSError *localError = nil; while (contextToSave) { @@ -795,11 +795,13 @@ - (BOOL)saveContextToPersistentStore:(NSManagedObjectContext *)contextToSave err if (! success) { if (error) *error = localError; + *failedContext = contextToSave; return NO; } if (! contextToSave.parentContext && contextToSave.persistentStoreCoordinator == nil) { RKLogWarning(@"Reached the end of the chain of nested managed object contexts without encountering a persistent store coordinator. Objects are not fully persisted."); + *failedContext = contextToSave; return NO; } contextToSave = contextToSave.parentContext; @@ -812,11 +814,15 @@ - (BOOL)saveContext:(NSManagedObjectContext *)context error:(NSError **)error { __block BOOL success = YES; __block NSError *localError = nil; + __block NSManagedObjectContext *failedContext = nil; if (self.savesToPersistentStore) { - success = [self saveContextToPersistentStore:context error:&localError]; + success = [self saveContextToPersistentStore:context failedContext:&failedContext error:&localError]; } else { [context performBlockAndWait:^{ success = ([self isCancelled]) ? NO : [context save:&localError]; + if (!success) { + failedContext = context; + } }]; } if (success) { @@ -830,7 +836,7 @@ - (BOOL)saveContext:(NSManagedObjectContext *)context error:(NSError **)error if (error) *error = localError; // Logging the error requires calling -[NSManagedObject description] which // can only be done on the context's queue - [context performBlock:^{ + [failedContext performBlock:^{ RKLogError(@"Failed saving managed object context %@ %@: %@", (self.savesToPersistentStore ? @"to the persistent store" : @""), context, localError); RKLogCoreDataError(localError); }]; From 00bfae2703e18282823c69a6a3911c4a6ff3891c Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Tue, 25 Aug 2015 14:34:59 -0600 Subject: [PATCH 39/94] Update documentation to mention @import RestKit option --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 3b95a8fe74..e0324ee1eb 100644 --- a/README.md +++ b/README.md @@ -617,7 +617,7 @@ Detailed installation instructions are available in the [Visual Install Guide](h ## Using RestKit in a Swift Project -Install RestKit using one of the above methods, then add `#import ` into the bridging header for your Swift project. To enable the Core Data functionality in RestKit, add `@import CoreData;` into your bridging header _before_ you import `RestKit.h`. +Install RestKit using one of the above methods. Then add `@import RestKit;` (if RestKit is built as a dynamic framework) or `#import ` (if RestKit is built as a static library) into the bridging header for your Swift project. To enable the Core Data functionality in RestKit, add `@import CoreData;` into your bridging header _before_ you import RestKit. ## License From c6b5d159c20f81de1df1a699fd6cb850b99cd3d9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ce=CC=81dric=20Luthi?= Date: Fri, 21 Aug 2015 11:14:22 +0200 Subject: [PATCH 40/94] Remove AFNetworking logs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It it not RestKit’s business to log AFNetworking operations. This is problematic if your application uses AFNetworking outside of RestKit, for example if it uses UIImageView+AFNetworking. --- Code/Network/RKObjectRequestOperation.m | 49 ++++--------------------- 1 file changed, 7 insertions(+), 42 deletions(-) diff --git a/Code/Network/RKObjectRequestOperation.m b/Code/Network/RKObjectRequestOperation.m index 8fbeda8320..2c3b64ca47 100644 --- a/Code/Network/RKObjectRequestOperation.m +++ b/Code/Network/RKObjectRequestOperation.m @@ -128,16 +128,9 @@ - (void)objectRequestOperationDidStart:(NSNotification *)notification { // Weakly tag the HTTP operation with its parent object request operation RKObjectRequestOperation *objectRequestOperation = [notification object]; + RKHTTPRequestOperation *operation = objectRequestOperation.HTTPRequestOperation; objc_setAssociatedObject(objectRequestOperation, RKOperationStartDate, [NSDate date], OBJC_ASSOCIATION_RETAIN_NONATOMIC); objc_setAssociatedObject(objectRequestOperation.HTTPRequestOperation, RKParentObjectRequestOperation, objectRequestOperation, OBJC_ASSOCIATION_RETAIN_NONATOMIC); -} - -- (void)HTTPOperationDidStart:(NSNotification *)notification -{ - RKHTTPRequestOperation *operation = [notification object]; - if (![operation isKindOfClass:[AFHTTPRequestOperation class]]) return; - - objc_setAssociatedObject(operation, RKOperationStartDate, [NSDate date], OBJC_ASSOCIATION_RETAIN_NONATOMIC); if ((_RKlcl_component_level[(__RKlcl_log_symbol(RKlcl_cRestKitNetwork))]) >= (__RKlcl_log_symbol(RKlcl_vTrace))) { NSString *body = nil; @@ -151,42 +144,14 @@ - (void)HTTPOperationDidStart:(NSNotification *)notification } } +- (void)HTTPOperationDidStart:(NSNotification *)notification +{ + objc_setAssociatedObject(notification.object, RKOperationStartDate, [NSDate date], OBJC_ASSOCIATION_RETAIN_NONATOMIC); +} + - (void)HTTPOperationDidFinish:(NSNotification *)notification { - RKHTTPRequestOperation *operation = [notification object]; - if (![operation isKindOfClass:[AFHTTPRequestOperation class]]) return; - - // NOTE: if we have a parent object request operation, we'll wait it to finish to emit the logging info - RKObjectRequestOperation *parentOperation = objc_getAssociatedObject(operation, RKParentObjectRequestOperation); - objc_setAssociatedObject(operation, RKParentObjectRequestOperation, nil, OBJC_ASSOCIATION_RETAIN_NONATOMIC); - if (parentOperation) { - objc_setAssociatedObject(operation, RKOperationFinishDate, [NSDate date], OBJC_ASSOCIATION_RETAIN_NONATOMIC); - return; - } - - NSTimeInterval elapsedTime = [[NSDate date] timeIntervalSinceDate:objc_getAssociatedObject(operation, RKOperationStartDate)]; - - NSString *statusCodeString = RKStringFromStatusCode([operation.response statusCode]); - NSString *elapsedTimeString = [NSString stringWithFormat:@"[%.04f s]", elapsedTime]; - NSString *statusCodeAndElapsedTime = statusCodeString ? [NSString stringWithFormat:@"(%ld %@) %@", (long)[operation.response statusCode], statusCodeString, elapsedTimeString] : [NSString stringWithFormat:@"(%ld) %@", (long)[operation.response statusCode], elapsedTimeString]; - if (operation.error) { - if ((_RKlcl_component_level[(__RKlcl_log_symbol(RKlcl_cRestKitNetwork))]) >= (__RKlcl_log_symbol(RKlcl_vTrace))) { - RKLogError(@"%@ '%@' %@:\nerror=%@", [operation.request HTTPMethod], [[operation.request URL] absoluteString], statusCodeAndElapsedTime, operation.error); - RKLogDebug(@"response.body=%@", operation.responseString); - } else { - if (operation.error.code == NSURLErrorCancelled) { - RKLogError(@"%@ '%@' %@: Cancelled", [operation.request HTTPMethod], [[operation.request URL] absoluteString], statusCodeAndElapsedTime); - } else { - RKLogError(@"%@ '%@' %@: %@", [operation.request HTTPMethod], [[operation.request URL] absoluteString], statusCodeAndElapsedTime, operation.error); - } - } - } else { - if ((_RKlcl_component_level[(__RKlcl_log_symbol(RKlcl_cRestKitNetwork))]) >= (__RKlcl_log_symbol(RKlcl_vTrace))) { - RKLogTrace(@"%@ '%@' %@:\nresponse.headers=%@\nresponse.body=%@", [operation.request HTTPMethod], [[operation.request URL] absoluteString], statusCodeAndElapsedTime, [operation.response allHeaderFields], RKLogTruncateString(operation.responseString)); - } else { - RKLogInfo(@"%@ '%@' %@", [operation.request HTTPMethod], [[operation.request URL] absoluteString], statusCodeAndElapsedTime); - } - } + objc_setAssociatedObject(notification.object, RKOperationFinishDate, [NSDate date], OBJC_ASSOCIATION_RETAIN_NONATOMIC); } - (void)objectRequestOperationDidFinish:(NSNotification *)notification From a86b6c4ec3485cdf5a04311e303ddc9c0104769d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ce=CC=81dric=20Luthi?= Date: Fri, 21 Aug 2015 11:30:19 +0200 Subject: [PATCH 41/94] Refactor RKHTTPRequestOperation logs Do not repeat operation.request everywhere and use dot notation on properties. --- Code/Network/RKObjectRequestOperation.m | 26 +++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/Code/Network/RKObjectRequestOperation.m b/Code/Network/RKObjectRequestOperation.m index 2c3b64ca47..4db5a20b08 100644 --- a/Code/Network/RKObjectRequestOperation.m +++ b/Code/Network/RKObjectRequestOperation.m @@ -128,19 +128,19 @@ - (void)objectRequestOperationDidStart:(NSNotification *)notification { // Weakly tag the HTTP operation with its parent object request operation RKObjectRequestOperation *objectRequestOperation = [notification object]; - RKHTTPRequestOperation *operation = objectRequestOperation.HTTPRequestOperation; objc_setAssociatedObject(objectRequestOperation, RKOperationStartDate, [NSDate date], OBJC_ASSOCIATION_RETAIN_NONATOMIC); objc_setAssociatedObject(objectRequestOperation.HTTPRequestOperation, RKParentObjectRequestOperation, objectRequestOperation, OBJC_ASSOCIATION_RETAIN_NONATOMIC); + NSURLRequest *request = objectRequestOperation.HTTPRequestOperation.request; if ((_RKlcl_component_level[(__RKlcl_log_symbol(RKlcl_cRestKitNetwork))]) >= (__RKlcl_log_symbol(RKlcl_vTrace))) { NSString *body = nil; - if ([operation.request HTTPBody]) { - body = RKLogTruncateString([[NSString alloc] initWithData:[operation.request HTTPBody] encoding:NSUTF8StringEncoding]); + if (request.HTTPBody) { + body = RKLogTruncateString([[NSString alloc] initWithData:request.HTTPBody encoding:NSUTF8StringEncoding]); } - RKLogTrace(@"%@ '%@':\nrequest.headers=%@\nrequest.body=%@", [operation.request HTTPMethod], [[operation.request URL] absoluteString], [operation.request allHTTPHeaderFields], body); + RKLogTrace(@"%@ '%@':\nrequest.headers=%@\nrequest.body=%@", request.HTTPMethod, request.URL.absoluteString, request.allHTTPHeaderFields, body); } else { - RKLogInfo(@"%@ '%@'", [operation.request HTTPMethod], [[operation.request URL] absoluteString]); + RKLogInfo(@"%@ '%@'", request.HTTPMethod, request.URL.absoluteString); } } @@ -165,26 +165,28 @@ - (void)objectRequestOperationDidFinish:(NSNotification *)notification NSDate *mappingDidStartTime = (notification.userInfo)[RKObjectRequestOperationMappingDidFinishUserInfoKey]; NSTimeInterval mappingDuration = [mappingDidStartTime isEqual:[NSNull null]] ? 0.0 : [mappingDidStartTime timeIntervalSinceDate:(notification.userInfo)[RKObjectRequestOperationMappingDidStartUserInfoKey]]; - NSString *statusCodeString = RKStringFromStatusCode([HTTPRequestOperation.response statusCode]); + NSURLRequest *request = HTTPRequestOperation.request; + NSHTTPURLResponse *response = HTTPRequestOperation.response; + NSString *statusCodeString = RKStringFromStatusCode(response.statusCode); NSString *statusCodeDescription = statusCodeString ? [NSString stringWithFormat:@" %@ ", statusCodeString] : @" "; NSString *elapsedTimeString = [NSString stringWithFormat:@"[request=%.04fs mapping=%.04fs total=%.04fs]", httpRequestExecutionDuration, mappingDuration, objectRequestExecutionDuration]; - NSString *statusCodeAndElapsedTime = [NSString stringWithFormat:@"(%ld%@/ %lu objects) %@", (long)[HTTPRequestOperation.response statusCode], statusCodeDescription, (unsigned long) [objectRequestOperation.mappingResult count], elapsedTimeString]; + NSString *statusCodeAndElapsedTime = [NSString stringWithFormat:@"(%ld%@/ %lu objects) %@", (long)response.statusCode, statusCodeDescription, (unsigned long) [objectRequestOperation.mappingResult count], elapsedTimeString]; if (objectRequestOperation.error) { if ((_RKlcl_component_level[(__RKlcl_log_symbol(RKlcl_cRestKitNetwork))]) >= (__RKlcl_log_symbol(RKlcl_vTrace))) { - RKLogError(@"%@ '%@' %@:\nerror=%@", [HTTPRequestOperation.request HTTPMethod], [[HTTPRequestOperation.request URL] absoluteString], statusCodeAndElapsedTime, objectRequestOperation.error); + RKLogError(@"%@ '%@' %@:\nerror=%@", request.HTTPMethod, request.URL.absoluteString, statusCodeAndElapsedTime, objectRequestOperation.error); RKLogDebug(@"response.body=%@", HTTPRequestOperation.responseString); } else { if (objectRequestOperation.error.code == NSURLErrorCancelled) { - RKLogError(@"%@ '%@' %@: Cancelled", [HTTPRequestOperation.request HTTPMethod], [[HTTPRequestOperation.request URL] absoluteString], statusCodeAndElapsedTime); + RKLogError(@"%@ '%@' %@: Cancelled", request.HTTPMethod, request.URL.absoluteString, statusCodeAndElapsedTime); } else { - RKLogError(@"%@ '%@' %@: %@", [HTTPRequestOperation.request HTTPMethod], [[HTTPRequestOperation.request URL] absoluteString], statusCodeAndElapsedTime, objectRequestOperation.error); + RKLogError(@"%@ '%@' %@: %@", request.HTTPMethod, request.URL.absoluteString, statusCodeAndElapsedTime, objectRequestOperation.error); } } } else { if ((_RKlcl_component_level[(__RKlcl_log_symbol(RKlcl_cRestKitNetwork))]) >= (__RKlcl_log_symbol(RKlcl_vTrace))) { - RKLogTrace(@"%@ '%@' %@:\nresponse.headers=%@\nresponse.body=%@", [HTTPRequestOperation.request HTTPMethod], [[HTTPRequestOperation.request URL] absoluteString], statusCodeAndElapsedTime, [HTTPRequestOperation.response allHeaderFields], RKLogTruncateString(HTTPRequestOperation.responseString)); + RKLogTrace(@"%@ '%@' %@:\nresponse.headers=%@\nresponse.body=%@", request.HTTPMethod, request.URL.absoluteString, statusCodeAndElapsedTime, response.allHeaderFields, RKLogTruncateString(HTTPRequestOperation.responseString)); } else { - RKLogInfo(@"%@ '%@' %@", [HTTPRequestOperation.request HTTPMethod], [[HTTPRequestOperation.request URL] absoluteString], statusCodeAndElapsedTime); + RKLogInfo(@"%@ '%@' %@", request.HTTPMethod, request.URL.absoluteString, statusCodeAndElapsedTime); } } } From 84ad5b93c4c130f1d37a71cc7d42b828e33c6324 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ce=CC=81dric=20Luthi?= Date: Fri, 21 Aug 2015 11:43:48 +0200 Subject: [PATCH 42/94] Improve RKHTTPRequestOperation logs Log URL + headers + body incrementally, i.e * Log request method + URL and response status as _info_ * Log request headers and response headers as _debug_ * Log request body and response body as _trace_ Separating _info_ + _debug_ + _trace_ helps a lot when you use NSLogger where you can dynamically filter on the log level. Also log cancelled operations as _debug_ instead of _error_. --- Code/Network/RKObjectRequestOperation.m | 36 ++++++++++--------------- 1 file changed, 14 insertions(+), 22 deletions(-) diff --git a/Code/Network/RKObjectRequestOperation.m b/Code/Network/RKObjectRequestOperation.m index 4db5a20b08..07d248fc63 100644 --- a/Code/Network/RKObjectRequestOperation.m +++ b/Code/Network/RKObjectRequestOperation.m @@ -38,6 +38,8 @@ #undef RKLogComponent #define RKLogComponent RKlcl_cRestKitNetwork +#define RKLogIsTrace() (_RKlcl_component_level[(__RKlcl_log_symbol(RKlcl_cRestKitNetwork))]) >= (__RKlcl_log_symbol(RKlcl_vTrace)) + static BOOL RKLogIsStringBlank(NSString *string) { return ([[string stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]] length] == 0); @@ -132,15 +134,10 @@ - (void)objectRequestOperationDidStart:(NSNotification *)notification objc_setAssociatedObject(objectRequestOperation.HTTPRequestOperation, RKParentObjectRequestOperation, objectRequestOperation, OBJC_ASSOCIATION_RETAIN_NONATOMIC); NSURLRequest *request = objectRequestOperation.HTTPRequestOperation.request; - if ((_RKlcl_component_level[(__RKlcl_log_symbol(RKlcl_cRestKitNetwork))]) >= (__RKlcl_log_symbol(RKlcl_vTrace))) { - NSString *body = nil; - if (request.HTTPBody) { - body = RKLogTruncateString([[NSString alloc] initWithData:request.HTTPBody encoding:NSUTF8StringEncoding]); - } - - RKLogTrace(@"%@ '%@':\nrequest.headers=%@\nrequest.body=%@", request.HTTPMethod, request.URL.absoluteString, request.allHTTPHeaderFields, body); - } else { - RKLogInfo(@"%@ '%@'", request.HTTPMethod, request.URL.absoluteString); + RKLogInfo(@"%@ '%@'", request.HTTPMethod, request.URL.absoluteString); + RKLogDebug(@"request.headers=%@", request.allHTTPHeaderFields); + if (request.HTTPBody && RKLogIsTrace()) { + RKLogTrace(@"request.body=%@", RKLogTruncateString([[NSString alloc] initWithData:request.HTTPBody encoding:NSUTF8StringEncoding])); } } @@ -172,22 +169,17 @@ - (void)objectRequestOperationDidFinish:(NSNotification *)notification NSString *elapsedTimeString = [NSString stringWithFormat:@"[request=%.04fs mapping=%.04fs total=%.04fs]", httpRequestExecutionDuration, mappingDuration, objectRequestExecutionDuration]; NSString *statusCodeAndElapsedTime = [NSString stringWithFormat:@"(%ld%@/ %lu objects) %@", (long)response.statusCode, statusCodeDescription, (unsigned long) [objectRequestOperation.mappingResult count], elapsedTimeString]; if (objectRequestOperation.error) { - if ((_RKlcl_component_level[(__RKlcl_log_symbol(RKlcl_cRestKitNetwork))]) >= (__RKlcl_log_symbol(RKlcl_vTrace))) { - RKLogError(@"%@ '%@' %@:\nerror=%@", request.HTTPMethod, request.URL.absoluteString, statusCodeAndElapsedTime, objectRequestOperation.error); - RKLogDebug(@"response.body=%@", HTTPRequestOperation.responseString); + if (objectRequestOperation.error.code == NSURLErrorCancelled) { + RKLogDebug(@"%@ '%@' %@: Cancelled", request.HTTPMethod, request.URL.absoluteString, statusCodeAndElapsedTime); } else { - if (objectRequestOperation.error.code == NSURLErrorCancelled) { - RKLogError(@"%@ '%@' %@: Cancelled", request.HTTPMethod, request.URL.absoluteString, statusCodeAndElapsedTime); - } else { - RKLogError(@"%@ '%@' %@: %@", request.HTTPMethod, request.URL.absoluteString, statusCodeAndElapsedTime, objectRequestOperation.error); - } + RKLogError(@"%@ '%@' %@: %@", request.HTTPMethod, request.URL.absoluteString, statusCodeAndElapsedTime, objectRequestOperation.error); } } else { - if ((_RKlcl_component_level[(__RKlcl_log_symbol(RKlcl_cRestKitNetwork))]) >= (__RKlcl_log_symbol(RKlcl_vTrace))) { - RKLogTrace(@"%@ '%@' %@:\nresponse.headers=%@\nresponse.body=%@", request.HTTPMethod, request.URL.absoluteString, statusCodeAndElapsedTime, response.allHeaderFields, RKLogTruncateString(HTTPRequestOperation.responseString)); - } else { - RKLogInfo(@"%@ '%@' %@", request.HTTPMethod, request.URL.absoluteString, statusCodeAndElapsedTime); - } + RKLogInfo(@"%@ '%@' %@", request.HTTPMethod, request.URL.absoluteString, statusCodeAndElapsedTime); + RKLogDebug(@"response.headers=%@", response.allHeaderFields); + } + if (RKLogIsTrace()) { + RKLogTrace(@"response.body=%@", RKLogTruncateString(HTTPRequestOperation.responseString)); } } From dd1b18323b3a9dc669d9124caa82aa6711563787 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Tue, 25 Aug 2015 17:57:45 -0600 Subject: [PATCH 43/94] Fix documentation for RKEntityMapping.modificationAttribute --- Code/CoreData/RKEntityMapping.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/CoreData/RKEntityMapping.h b/Code/CoreData/RKEntityMapping.h index 65be05562d..848956f1a7 100644 --- a/Code/CoreData/RKEntityMapping.h +++ b/Code/CoreData/RKEntityMapping.h @@ -126,7 +126,7 @@ A common modification attribute is a 'last modified' or 'updated at' timestamp that specifies the timestamp of the last change to an object. When the `modificationAttribute` is non-nil, the mapper will compare the value returned of the attribute on an existing object instance with the value in the representation being mapped. - The semantics of the comparison are dependent on the data type of the modification attribute. If the attribute is a string, then the values are compared for equality. If the attribute is a date or a numeric value, then the values will be compared numerically and mapping will be skipped if the value in the representation is greater than the value of the modification attribute stored on the object. + The semantics of the comparison are dependent on the data type of the modification attribute. If the attribute is a string, then the values are compared for equality. If the attribute is a date or a numeric value, then the values will be compared numerically and mapping will be skipped unless the value in the representation is greater than the value of the modification attribute stored on the object. @raises NSInvalidArgumentException Raised if the attribute given is not a property of the receiver's entity. */ From 4aea56a760d2e6864510d5b8582f3d7ffa892028 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ce=CC=81dric=20Luthi?= Date: Wed, 26 Aug 2015 02:54:53 +0200 Subject: [PATCH 44/94] Update TransitionKit dependency to version 2.2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Version 2.2.0 introduced some enhancements to the state change notifications. If other projects depend on version 2.2.x, this `~> 2.1.0` dependency would make CocoaPods’ dependency resolver unhappy. Also changing from `~> 2.1.0` to `~> 2.2` so that all future 2.x versions will make the resolver happy. --- RestKit.podspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/RestKit.podspec b/RestKit.podspec index 75990c83ec..a4d883bac4 100644 --- a/RestKit.podspec +++ b/RestKit.podspec @@ -100,6 +100,6 @@ EOS s.subspec 'Support' do |ss| ss.source_files = 'Code/RestKit.h', 'Code/Support.h', 'Code/Support', 'Vendor/LibComponentLogging/Core' - ss.dependency 'TransitionKit', '~> 2.1.0' + ss.dependency 'TransitionKit', '~> 2.2' end end From 705990b7fa89a197bb3d8090f35de2a57cabea68 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Wed, 26 Aug 2015 13:34:47 -0600 Subject: [PATCH 45/94] Mapping: Ignore NSNull in source collections --- Code/ObjectMapping/RKMapperOperation.m | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Code/ObjectMapping/RKMapperOperation.m b/Code/ObjectMapping/RKMapperOperation.m index db0cdcbf77..7a85ec55b8 100644 --- a/Code/ObjectMapping/RKMapperOperation.m +++ b/Code/ObjectMapping/RKMapperOperation.m @@ -229,6 +229,8 @@ - (NSArray *)mapRepresentations:(id)representations atKeyPath:(NSString *)keyPat NSArray *metadataList = [NSArray arrayWithObjects:metadata, self.metadata, nil]; NSMutableArray *mappedObjects = [NSMutableArray arrayWithCapacity:[representations count]]; [objectsToMap enumerateObjectsUsingBlock:^(id mappableObject, NSUInteger index, BOOL *stop) { + if (mappableObject == [NSNull null]) { return; } + id destinationObject = [self objectForRepresentation:mappableObject withMapping:mapping]; if (destinationObject) { mappingData.collectionIndex = index; From fd4159c5b194ec78180d58d26c24a5cc137ec134 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Wed, 26 Aug 2015 13:41:45 -0600 Subject: [PATCH 46/94] indentation --- Code/ObjectMapping/RKMapperOperation.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/ObjectMapping/RKMapperOperation.m b/Code/ObjectMapping/RKMapperOperation.m index 7a85ec55b8..163caeffe1 100644 --- a/Code/ObjectMapping/RKMapperOperation.m +++ b/Code/ObjectMapping/RKMapperOperation.m @@ -229,7 +229,7 @@ - (NSArray *)mapRepresentations:(id)representations atKeyPath:(NSString *)keyPat NSArray *metadataList = [NSArray arrayWithObjects:metadata, self.metadata, nil]; NSMutableArray *mappedObjects = [NSMutableArray arrayWithCapacity:[representations count]]; [objectsToMap enumerateObjectsUsingBlock:^(id mappableObject, NSUInteger index, BOOL *stop) { - if (mappableObject == [NSNull null]) { return; } + if (mappableObject == [NSNull null]) { return; } id destinationObject = [self objectForRepresentation:mappableObject withMapping:mapping]; if (destinationObject) { From e7ad5018a808b1042db1cf8a2ee6423142b27569 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Wed, 26 Aug 2015 13:52:36 -0600 Subject: [PATCH 47/94] Test that mapper ignores NSNull in collections --- Tests/Fixtures/JSON/users.json | 6 +++++- .../ObjectMapping/RKObjectMappingNextGenTest.m | 17 +++++++++++++++++ 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/Tests/Fixtures/JSON/users.json b/Tests/Fixtures/JSON/users.json index f53c793920..ada7b7a772 100644 --- a/Tests/Fixtures/JSON/users.json +++ b/Tests/Fixtures/JSON/users.json @@ -5,7 +5,11 @@ }, { "id":187, - "name":"Jeremy Ellison" + "name":"Jeremy Ellison", + "friend": { + "id": 255, + "name": "Anthony Stark" + } }, { "id":7, diff --git a/Tests/Logic/ObjectMapping/RKObjectMappingNextGenTest.m b/Tests/Logic/ObjectMapping/RKObjectMappingNextGenTest.m index b69b508297..6bb7778128 100644 --- a/Tests/Logic/ObjectMapping/RKObjectMappingNextGenTest.m +++ b/Tests/Logic/ObjectMapping/RKObjectMappingNextGenTest.m @@ -262,6 +262,23 @@ - (void)testShouldMapACollectionOfSimpleObjectDictionaries assertThat(blake.name, is(equalTo(@"Blake Watters"))); } +- (void)testShouldIgnoreNSNullInCollections { + RKObjectMapping *mapping = [RKObjectMapping mappingForClass:[RKTestUser class]]; + RKAttributeMapping *idMapping = [RKAttributeMapping attributeMappingFromKeyPath:@"id" toKeyPath:@"userID"]; + [mapping addPropertyMapping:idMapping]; + RKAttributeMapping *nameMapping = [RKAttributeMapping attributeMappingFromKeyPath:@"name" toKeyPath:@"name"]; + [mapping addPropertyMapping:nameMapping]; + + RKMapperOperation *mapper = [RKMapperOperation new]; + mapper.mappingOperationDataSource = [RKObjectMappingOperationDataSource new]; + id userInfo = [RKTestFixture parsedObjectWithContentsOfFixture:@"users.json"]; + NSArray *friendReps = [userInfo valueForKey:@"friend"]; + NSArray *friends = [mapper mapRepresentations:friendReps atKeyPath:@"" usingMapping:mapping]; + assertThatUnsignedInteger([friends count], is(equalToInt(1))); + RKTestUser *tony = friends[0]; + assertThat(tony.name, is(equalTo(@"Anthony Stark"))); +} + - (void)testShouldDetermineTheObjectMappingByConsultingTheMappingProviderWhenThereIsATargetObject { RKObjectMapping *mapping = [RKObjectMapping mappingForClass:[RKTestUser class]]; From 4e4dc711d8419092ab6548fb9d31afede018308e Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Wed, 26 Aug 2015 16:44:43 -0600 Subject: [PATCH 48/94] Add RKEntityMapping.shouldMapRelationshipsIfObjectIsUnmodified flag --- Code/CoreData/RKEntityMapping.h | 9 +++++ Code/CoreData/RKEntityMapping.m | 1 + ...KManagedObjectMappingOperationDataSource.m | 22 +++++++++++-- Code/ObjectMapping/RKMappingOperation.m | 33 ++++++++++++------- .../RKMappingOperationDataSource.h | 4 ++- ...agedObjectMappingOperationDataSourceTest.m | 18 +++++----- 6 files changed, 63 insertions(+), 24 deletions(-) diff --git a/Code/CoreData/RKEntityMapping.h b/Code/CoreData/RKEntityMapping.h index 848956f1a7..8cbfb52e82 100644 --- a/Code/CoreData/RKEntityMapping.h +++ b/Code/CoreData/RKEntityMapping.h @@ -132,6 +132,15 @@ */ @property (nonatomic, strong) NSAttributeDescription *modificationAttribute; +/** + If this is YES, mapping operations will map relationships of the object even if the `modificationAttribute` shows that the object has not been modified. + + This is useful if a response contains a nested object that has been updated inside an object that has not. + + Defaults to NO. + */ +@property (nonatomic) BOOL shouldMapRelationshipsIfObjectIsUnmodified; + /** Sets the `modificationAttribute` to the receiver to the attribute with the specified name. diff --git a/Code/CoreData/RKEntityMapping.m b/Code/CoreData/RKEntityMapping.m index 247ee486ff..8a9037865b 100644 --- a/Code/CoreData/RKEntityMapping.m +++ b/Code/CoreData/RKEntityMapping.m @@ -142,6 +142,7 @@ @interface RKEntityMapping () @implementation RKEntityMapping @synthesize identificationAttributes = _identificationAttributes; +@synthesize shouldMapRelationshipsIfObjectIsUnmodified = _shouldMapRelationshipsIfObjectIsUnmodified; + (instancetype)mappingForClass:(Class)objectClass { diff --git a/Code/CoreData/RKManagedObjectMappingOperationDataSource.m b/Code/CoreData/RKManagedObjectMappingOperationDataSource.m index cf1ca6d12c..d2324f586e 100644 --- a/Code/CoreData/RKManagedObjectMappingOperationDataSource.m +++ b/Code/CoreData/RKManagedObjectMappingOperationDataSource.m @@ -467,8 +467,7 @@ - (BOOL)mappingOperationShouldSetUnchangedValues:(RKMappingOperation *)mappingOp return [mappingOperation isNewDestinationObject]; } -- (BOOL)mappingOperationShouldSkipPropertyMapping:(RKMappingOperation *)mappingOperation -{ +- (BOOL)isDestinationObjectNotModifiedInMappingOperation:(RKMappingOperation *)mappingOperation { // Use concrete mapping or original mapping if not available RKMapping *checkedMapping = mappingOperation.objectMapping ?: mappingOperation.mapping; @@ -498,6 +497,25 @@ - (BOOL)mappingOperationShouldSkipPropertyMapping:(RKMappingOperation *)mappingO } } +- (BOOL)mappingOperationShouldSkipAttributeMapping:(RKMappingOperation *)mappingOperation +{ + return [self isDestinationObjectNotModifiedInMappingOperation:mappingOperation]; +} + +- (BOOL)mappingOperationShouldSkipRelationshipMapping:(RKMappingOperation *)mappingOperation +{ + // Use concrete mapping or original mapping if not available + RKMapping *checkedMapping = mappingOperation.objectMapping ?: mappingOperation.mapping; + + if (! [checkedMapping isKindOfClass:[RKEntityMapping class]]) return NO; + RKEntityMapping *entityMapping = (id)checkedMapping; + if (entityMapping.shouldMapRelationshipsIfObjectIsUnmodified) { + return NO; + } else { + return [self isDestinationObjectNotModifiedInMappingOperation:mappingOperation]; + } +} + - (BOOL)mappingOperationShouldCollectMappingInfo:(RKMappingOperation *)mappingOperation { return YES; diff --git a/Code/ObjectMapping/RKMappingOperation.m b/Code/ObjectMapping/RKMappingOperation.m index 9787f171f5..d77147c895 100644 --- a/Code/ObjectMapping/RKMappingOperation.m +++ b/Code/ObjectMapping/RKMappingOperation.m @@ -1204,18 +1204,27 @@ - (void)main } } - BOOL canSkipMapping = [dataSource respondsToSelector:@selector(mappingOperationShouldSkipPropertyMapping:)] && [dataSource mappingOperationShouldSkipPropertyMapping:self]; - if (! canSkipMapping) { - [self applyNestedMappings]; - if ([self isCancelled]) return; - BOOL mappedSimpleAttributes = [self applyAttributeMappings:[self simpleAttributeMappings]]; - if ([self isCancelled]) return; - BOOL mappedRelationships = [[self relationshipMappings] count] ? [self applyRelationshipMappings] : NO; - if ([self isCancelled]) return; - // NOTE: We map key path attributes last to allow you to map across the object graphs for objects created/updated by the relationship mappings - BOOL mappedKeyPathAttributes = [self applyAttributeMappings:[self keyPathAttributeMappings]]; - - if (!mappedSimpleAttributes && !mappedRelationships && !mappedKeyPathAttributes) { + BOOL canSkipAttributes = [dataSource respondsToSelector:@selector(mappingOperationShouldSkipAttributeMapping:)] && [dataSource mappingOperationShouldSkipAttributeMapping:self]; + BOOL canSkipRelationships = [dataSource respondsToSelector:@selector(mappingOperationShouldSkipRelationshipMapping:)] && [dataSource mappingOperationShouldSkipRelationshipMapping:self]; + if (!canSkipRelationships || !canSkipAttributes) { + BOOL foundNoSimpleAttributes = NO; + BOOL foundNoRelationships = NO; + BOOL foundNoKeyPathAttributes = NO; + if (!canSkipAttributes) { + [self applyNestedMappings]; + if ([self isCancelled]) return; + foundNoSimpleAttributes = ![self applyAttributeMappings:[self simpleAttributeMappings]]; + } + if (!canSkipRelationships) { + if ([self isCancelled]) return; + foundNoRelationships = [[self relationshipMappings] count] ? ![self applyRelationshipMappings] : YES; + } + if (!canSkipAttributes) { + if ([self isCancelled]) return; + // NOTE: We map key path attributes last to allow you to map across the object graphs for objects created/updated by the relationship mappings + foundNoKeyPathAttributes = ![self applyAttributeMappings:[self keyPathAttributeMappings]]; + } + if (foundNoSimpleAttributes && foundNoRelationships && foundNoKeyPathAttributes) { // We did not find anything to do RKLogDebug(@"Mapping operation did not find any mappable values for the attribute and relationship mappings in the given object representation"); NSDictionary *userInfo = @{ NSLocalizedDescriptionKey: @"No mappable values found for any of the attributes or relationship mappings" }; diff --git a/Code/ObjectMapping/RKMappingOperationDataSource.h b/Code/ObjectMapping/RKMappingOperationDataSource.h index 2d06b34163..2be9112f1d 100644 --- a/Code/ObjectMapping/RKMappingOperationDataSource.h +++ b/Code/ObjectMapping/RKMappingOperationDataSource.h @@ -93,7 +93,9 @@ */ - (BOOL)mappingOperationShouldSetUnchangedValues:(RKMappingOperation *)mappingOperation; -- (BOOL)mappingOperationShouldSkipPropertyMapping:(RKMappingOperation *)mappingOperation; +- (BOOL)mappingOperationShouldSkipAttributeMapping:(RKMappingOperation *)mappingOperation; + +- (BOOL)mappingOperationShouldSkipRelationshipMapping:(RKMappingOperation *)mappingOperation; /** Asks the data source if the mapping operation should collect `RKMappingInfo` information during the mapping diff --git a/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m b/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m index 8bda2db5dc..e86a241647 100644 --- a/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m +++ b/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m @@ -1646,7 +1646,7 @@ - (void)testThatStringEqualityCausesSkipPropertyMappingToReturnYES RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipPropertyMapping:mappingOperation]; + BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; expect(canSkipMapping).to.equal(YES); } @@ -1668,7 +1668,7 @@ - (void)testThatStringInequalityCausesSkipPropertyMappingToReturnNO RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipPropertyMapping:mappingOperation]; + BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; expect(canSkipMapping).to.equal(NO); } @@ -1691,7 +1691,7 @@ - (void)testThatDateEqualityCausesSkipPropertyMappingToReturnYES RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipPropertyMapping:mappingOperation]; + BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; expect(canSkipMapping).to.equal(YES); } @@ -1715,7 +1715,7 @@ - (void)testThatDateDecensionCausesSkipPropertyMappingToReturnYES RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipPropertyMapping:mappingOperation]; + BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; expect(canSkipMapping).to.equal(YES); } @@ -1739,7 +1739,7 @@ - (void)testThatDateAscensionCausesSkipPropertyMappingToReturnNO RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipPropertyMapping:mappingOperation]; + BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; expect(canSkipMapping).to.equal(NO); } @@ -1761,7 +1761,7 @@ - (void)testThatNumericEqualityCausesSkipPropertyMappingToReturnYES RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipPropertyMapping:mappingOperation]; + BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; expect(canSkipMapping).to.equal(YES); } @@ -1783,7 +1783,7 @@ - (void)testThatNumericDecensionCausesSkipPropertyMappingToReturnYES RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipPropertyMapping:mappingOperation]; + BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; expect(canSkipMapping).to.equal(YES); } @@ -1805,7 +1805,7 @@ - (void)testThatNumericAscensionCausesSkipPropertyMappingToReturnNO RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipPropertyMapping:mappingOperation]; + BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; expect(canSkipMapping).to.equal(NO); } @@ -1838,7 +1838,7 @@ - (void)testThatDynamicMappingCanSkipPropertyMapping [mappingOperationDataSource.operationQueue waitUntilAllOperationsAreFinished]; assertThat(error, is(nilValue())); - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipPropertyMapping:mappingOperation]; + BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; expect(canSkipMapping).to.equal(YES); } From b71abc5df79361420e5503006ba690e7abbfd88b Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Wed, 26 Aug 2015 16:54:17 -0600 Subject: [PATCH 49/94] Add back mappingOperationShouldSkipPropertyMapping: for backwards compatibility --- .../RKManagedObjectMappingOperationDataSource.m | 5 +++++ Code/ObjectMapping/RKMappingOperation.m | 11 +++++++++-- Code/ObjectMapping/RKMappingOperationDataSource.h | 2 ++ 3 files changed, 16 insertions(+), 2 deletions(-) diff --git a/Code/CoreData/RKManagedObjectMappingOperationDataSource.m b/Code/CoreData/RKManagedObjectMappingOperationDataSource.m index d2324f586e..c32cd60e95 100644 --- a/Code/CoreData/RKManagedObjectMappingOperationDataSource.m +++ b/Code/CoreData/RKManagedObjectMappingOperationDataSource.m @@ -497,6 +497,11 @@ - (BOOL)isDestinationObjectNotModifiedInMappingOperation:(RKMappingOperation *)m } } +- (BOOL)mappingOperationShouldSkipPropertyMapping:(RKMappingOperation *)mappingOperation +{ + return [self isDestinationObjectNotModifiedInMappingOperation:mappingOperation]; +} + - (BOOL)mappingOperationShouldSkipAttributeMapping:(RKMappingOperation *)mappingOperation { return [self isDestinationObjectNotModifiedInMappingOperation:mappingOperation]; diff --git a/Code/ObjectMapping/RKMappingOperation.m b/Code/ObjectMapping/RKMappingOperation.m index d77147c895..b74c8f96d7 100644 --- a/Code/ObjectMapping/RKMappingOperation.m +++ b/Code/ObjectMapping/RKMappingOperation.m @@ -1204,8 +1204,15 @@ - (void)main } } - BOOL canSkipAttributes = [dataSource respondsToSelector:@selector(mappingOperationShouldSkipAttributeMapping:)] && [dataSource mappingOperationShouldSkipAttributeMapping:self]; - BOOL canSkipRelationships = [dataSource respondsToSelector:@selector(mappingOperationShouldSkipRelationshipMapping:)] && [dataSource mappingOperationShouldSkipRelationshipMapping:self]; + BOOL canSkipProperties = [dataSource respondsToSelector:@selector(mappingOperationShouldSkipPropertyMapping:)] && [dataSource mappingOperationShouldSkipPropertyMapping:self]; + BOOL canSkipAttributes = canSkipProperties; + BOOL canSkipRelationships = canSkipProperties; + if ([dataSource respondsToSelector:@selector(mappingOperationShouldSkipRelationshipMapping:)]) { + canSkipRelationships = [dataSource mappingOperationShouldSkipRelationshipMapping:self]; + } + if ([dataSource respondsToSelector:@selector(mappingOperationShouldSkipAttributeMapping:)]) { + canSkipAttributes = [dataSource mappingOperationShouldSkipAttributeMapping:self]; + } if (!canSkipRelationships || !canSkipAttributes) { BOOL foundNoSimpleAttributes = NO; BOOL foundNoRelationships = NO; diff --git a/Code/ObjectMapping/RKMappingOperationDataSource.h b/Code/ObjectMapping/RKMappingOperationDataSource.h index 2be9112f1d..c12cff5bed 100644 --- a/Code/ObjectMapping/RKMappingOperationDataSource.h +++ b/Code/ObjectMapping/RKMappingOperationDataSource.h @@ -93,6 +93,8 @@ */ - (BOOL)mappingOperationShouldSetUnchangedValues:(RKMappingOperation *)mappingOperation; +- (BOOL)mappingOperationShouldSkipPropertyMapping:(RKMappingOperation *)mappingOperation DEPRECATED_MSG_ATTRIBUTE("use mappingOperationShouldSkipAttributeMapping: and mappingOperationShouldSkipRelationshipMapping: instead"); + - (BOOL)mappingOperationShouldSkipAttributeMapping:(RKMappingOperation *)mappingOperation; - (BOOL)mappingOperationShouldSkipRelationshipMapping:(RKMappingOperation *)mappingOperation; From a44b246f06ae97e837de686e069787cf7e74a863 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Wed, 26 Aug 2015 18:23:37 -0600 Subject: [PATCH 50/94] Test that shouldMapRelationshipsIfObjectIsUnmodified flag works --- ...agedObjectMappingOperationDataSourceTest.m | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m b/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m index e86a241647..62a261c0d1 100644 --- a/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m +++ b/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m @@ -1628,6 +1628,31 @@ - (void)testThatMappingRequiredHasManyRelationshipDoesNotCrash expect([catHoarder valueForKeyPath:@"hoardedCats"]).to.haveCountOf(1); } +- (void)testThatShouldMapRelationshipsIfObjectIsUnmodifiedFlagWorks { + RKManagedObjectStore *managedObjectStore = [RKTestFactory managedObjectStore]; + RKFetchRequestManagedObjectCache *managedObjectCache = [RKFetchRequestManagedObjectCache new]; + RKManagedObjectMappingOperationDataSource *mappingOperationDataSource = [[RKManagedObjectMappingOperationDataSource alloc] initWithManagedObjectContext:managedObjectStore.persistentStoreManagedObjectContext + cache:managedObjectCache]; + mappingOperationDataSource.operationQueue = [NSOperationQueue new]; + + NSDate *updatedAt = [NSDate date]; + NSDictionary *representation = @{ @"name": @"Blake Watters", @"railsID": @123, @"updatedAt": updatedAt }; + RKEntityMapping *humanMapping = [RKEntityMapping mappingForEntityForName:@"Human" inManagedObjectStore:managedObjectStore]; + [humanMapping addAttributeMappingsFromArray:@[ @"name", @"railsID", @"updatedAt" ]]; + [humanMapping setModificationAttributeForName:@"updatedAt"]; + humanMapping.shouldMapRelationshipsIfObjectIsUnmodified = YES; + + NSManagedObject *human = [NSEntityDescription insertNewObjectForEntityForName:@"Human" inManagedObjectContext:managedObjectStore.persistentStoreManagedObjectContext]; + [human setValue:updatedAt forKey:@"updatedAt"]; + RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; + mappingOperation.dataSource = mappingOperationDataSource; + + BOOL canSkipAttrs = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttrs).to.equal(YES); + expect(canSkipRelationships).to.equal(NO); +} + - (void)testThatStringEqualityCausesSkipPropertyMappingToReturnYES { RKManagedObjectStore *managedObjectStore = [RKTestFactory managedObjectStore]; From 72ac303b6a1b9c88653205fb21d066a652140d6d Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Wed, 26 Aug 2015 18:26:03 -0600 Subject: [PATCH 51/94] Update other managed object data source tests for relationship skipping --- ...agedObjectMappingOperationDataSourceTest.m | 54 ++++++++++++------- 1 file changed, 36 insertions(+), 18 deletions(-) diff --git a/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m b/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m index 62a261c0d1..8f753ce0f2 100644 --- a/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m +++ b/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m @@ -1671,8 +1671,10 @@ - (void)testThatStringEqualityCausesSkipPropertyMappingToReturnYES RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - expect(canSkipMapping).to.equal(YES); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(YES); + expect(canSkipRelationships).to.equal(YES); } - (void)testThatStringInequalityCausesSkipPropertyMappingToReturnNO @@ -1693,8 +1695,10 @@ - (void)testThatStringInequalityCausesSkipPropertyMappingToReturnNO RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - expect(canSkipMapping).to.equal(NO); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(NO); + expect(canSkipRelationships).to.equal(NO); } - (void)testThatDateEqualityCausesSkipPropertyMappingToReturnYES @@ -1716,8 +1720,10 @@ - (void)testThatDateEqualityCausesSkipPropertyMappingToReturnYES RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - expect(canSkipMapping).to.equal(YES); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(YES); + expect(canSkipRelationships).to.equal(YES); } - (void)testThatDateDecensionCausesSkipPropertyMappingToReturnYES @@ -1740,8 +1746,10 @@ - (void)testThatDateDecensionCausesSkipPropertyMappingToReturnYES RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - expect(canSkipMapping).to.equal(YES); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(YES); + expect(canSkipRelationships).to.equal(YES); } - (void)testThatDateAscensionCausesSkipPropertyMappingToReturnNO @@ -1764,8 +1772,10 @@ - (void)testThatDateAscensionCausesSkipPropertyMappingToReturnNO RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - expect(canSkipMapping).to.equal(NO); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(NO); + expect(canSkipRelationships).to.equal(NO); } - (void)testThatNumericEqualityCausesSkipPropertyMappingToReturnYES @@ -1786,8 +1796,10 @@ - (void)testThatNumericEqualityCausesSkipPropertyMappingToReturnYES RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - expect(canSkipMapping).to.equal(YES); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(YES); + expect(canSkipRelationships).to.equal(YES); } - (void)testThatNumericDecensionCausesSkipPropertyMappingToReturnYES @@ -1808,8 +1820,10 @@ - (void)testThatNumericDecensionCausesSkipPropertyMappingToReturnYES RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - expect(canSkipMapping).to.equal(YES); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(YES); + expect(canSkipRelationships).to.equal(YES); } - (void)testThatNumericAscensionCausesSkipPropertyMappingToReturnNO @@ -1830,8 +1844,10 @@ - (void)testThatNumericAscensionCausesSkipPropertyMappingToReturnNO RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - expect(canSkipMapping).to.equal(NO); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(NO); + expect(canSkipRelationships).to.equal(NO); } - (void)testThatDynamicMappingCanSkipPropertyMapping @@ -1863,8 +1879,10 @@ - (void)testThatDynamicMappingCanSkipPropertyMapping [mappingOperationDataSource.operationQueue waitUntilAllOperationsAreFinished]; assertThat(error, is(nilValue())); - BOOL canSkipMapping = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - expect(canSkipMapping).to.equal(YES); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(YES); + expect(canSkipRelationships).to.equal(YES); } @end From d08cd4d5427e39da471ca33c60b5e11f0414130d Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Wed, 26 Aug 2015 18:32:09 -0600 Subject: [PATCH 52/94] Remove implementation of deprecated method --- Code/CoreData/RKManagedObjectMappingOperationDataSource.m | 5 ----- 1 file changed, 5 deletions(-) diff --git a/Code/CoreData/RKManagedObjectMappingOperationDataSource.m b/Code/CoreData/RKManagedObjectMappingOperationDataSource.m index c32cd60e95..d2324f586e 100644 --- a/Code/CoreData/RKManagedObjectMappingOperationDataSource.m +++ b/Code/CoreData/RKManagedObjectMappingOperationDataSource.m @@ -497,11 +497,6 @@ - (BOOL)isDestinationObjectNotModifiedInMappingOperation:(RKMappingOperation *)m } } -- (BOOL)mappingOperationShouldSkipPropertyMapping:(RKMappingOperation *)mappingOperation -{ - return [self isDestinationObjectNotModifiedInMappingOperation:mappingOperation]; -} - - (BOOL)mappingOperationShouldSkipAttributeMapping:(RKMappingOperation *)mappingOperation { return [self isDestinationObjectNotModifiedInMappingOperation:mappingOperation]; From 8b0d916ef52ea930e949f2f061c31770fa87ba61 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Wed, 26 Aug 2015 18:35:47 -0600 Subject: [PATCH 53/94] Indentation --- ...agedObjectMappingOperationDataSourceTest.m | 70 +++++++++---------- 1 file changed, 35 insertions(+), 35 deletions(-) diff --git a/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m b/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m index 8f753ce0f2..ac5b7b5566 100644 --- a/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m +++ b/Tests/Logic/CoreData/RKManagedObjectMappingOperationDataSourceTest.m @@ -1640,8 +1640,8 @@ - (void)testThatShouldMapRelationshipsIfObjectIsUnmodifiedFlagWorks { RKEntityMapping *humanMapping = [RKEntityMapping mappingForEntityForName:@"Human" inManagedObjectStore:managedObjectStore]; [humanMapping addAttributeMappingsFromArray:@[ @"name", @"railsID", @"updatedAt" ]]; [humanMapping setModificationAttributeForName:@"updatedAt"]; - humanMapping.shouldMapRelationshipsIfObjectIsUnmodified = YES; - + humanMapping.shouldMapRelationshipsIfObjectIsUnmodified = YES; + NSManagedObject *human = [NSEntityDescription insertNewObjectForEntityForName:@"Human" inManagedObjectContext:managedObjectStore.persistentStoreManagedObjectContext]; [human setValue:updatedAt forKey:@"updatedAt"]; RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; @@ -1674,7 +1674,7 @@ - (void)testThatStringEqualityCausesSkipPropertyMappingToReturnYES BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; expect(canSkipAttributes).to.equal(YES); - expect(canSkipRelationships).to.equal(YES); + expect(canSkipRelationships).to.equal(YES); } - (void)testThatStringInequalityCausesSkipPropertyMappingToReturnNO @@ -1695,10 +1695,10 @@ - (void)testThatStringInequalityCausesSkipPropertyMappingToReturnNO RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; - expect(canSkipAttributes).to.equal(NO); - expect(canSkipRelationships).to.equal(NO); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(NO); + expect(canSkipRelationships).to.equal(NO); } - (void)testThatDateEqualityCausesSkipPropertyMappingToReturnYES @@ -1720,10 +1720,10 @@ - (void)testThatDateEqualityCausesSkipPropertyMappingToReturnYES RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; - expect(canSkipAttributes).to.equal(YES); - expect(canSkipRelationships).to.equal(YES); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(YES); + expect(canSkipRelationships).to.equal(YES); } - (void)testThatDateDecensionCausesSkipPropertyMappingToReturnYES @@ -1746,10 +1746,10 @@ - (void)testThatDateDecensionCausesSkipPropertyMappingToReturnYES RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; - expect(canSkipAttributes).to.equal(YES); - expect(canSkipRelationships).to.equal(YES); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(YES); + expect(canSkipRelationships).to.equal(YES); } - (void)testThatDateAscensionCausesSkipPropertyMappingToReturnNO @@ -1772,10 +1772,10 @@ - (void)testThatDateAscensionCausesSkipPropertyMappingToReturnNO RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; - expect(canSkipAttributes).to.equal(NO); - expect(canSkipRelationships).to.equal(NO); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(NO); + expect(canSkipRelationships).to.equal(NO); } - (void)testThatNumericEqualityCausesSkipPropertyMappingToReturnYES @@ -1796,10 +1796,10 @@ - (void)testThatNumericEqualityCausesSkipPropertyMappingToReturnYES RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; - expect(canSkipAttributes).to.equal(YES); - expect(canSkipRelationships).to.equal(YES); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(YES); + expect(canSkipRelationships).to.equal(YES); } - (void)testThatNumericDecensionCausesSkipPropertyMappingToReturnYES @@ -1820,10 +1820,10 @@ - (void)testThatNumericDecensionCausesSkipPropertyMappingToReturnYES RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; - expect(canSkipAttributes).to.equal(YES); - expect(canSkipRelationships).to.equal(YES); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(YES); + expect(canSkipRelationships).to.equal(YES); } - (void)testThatNumericAscensionCausesSkipPropertyMappingToReturnNO @@ -1844,10 +1844,10 @@ - (void)testThatNumericAscensionCausesSkipPropertyMappingToReturnNO RKMappingOperation *mappingOperation = [[RKMappingOperation alloc] initWithSourceObject:representation destinationObject:human mapping:humanMapping]; mappingOperation.dataSource = mappingOperationDataSource; - BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; - expect(canSkipAttributes).to.equal(NO); - expect(canSkipRelationships).to.equal(NO); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(NO); + expect(canSkipRelationships).to.equal(NO); } - (void)testThatDynamicMappingCanSkipPropertyMapping @@ -1879,10 +1879,10 @@ - (void)testThatDynamicMappingCanSkipPropertyMapping [mappingOperationDataSource.operationQueue waitUntilAllOperationsAreFinished]; assertThat(error, is(nilValue())); - BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; - BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; - expect(canSkipAttributes).to.equal(YES); - expect(canSkipRelationships).to.equal(YES); + BOOL canSkipAttributes = [mappingOperationDataSource mappingOperationShouldSkipAttributeMapping:mappingOperation]; + BOOL canSkipRelationships = [mappingOperationDataSource mappingOperationShouldSkipRelationshipMapping:mappingOperation]; + expect(canSkipAttributes).to.equal(YES); + expect(canSkipRelationships).to.equal(YES); } @end From f3d6d6b5b979d8454c2fbb0299265b0e6f4ad597 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Thu, 27 Aug 2015 00:03:15 -0600 Subject: [PATCH 54/94] Document mapping operation data source shouldSkip methods --- .../RKMappingOperationDataSource.h | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/Code/ObjectMapping/RKMappingOperationDataSource.h b/Code/ObjectMapping/RKMappingOperationDataSource.h index c12cff5bed..4bf9545754 100644 --- a/Code/ObjectMapping/RKMappingOperationDataSource.h +++ b/Code/ObjectMapping/RKMappingOperationDataSource.h @@ -93,10 +93,35 @@ */ - (BOOL)mappingOperationShouldSetUnchangedValues:(RKMappingOperation *)mappingOperation; +/** + **Deprecated in v0.26.0** + Asks the data source if it should skip mapping. This method can significantly improve performance if, for example, the data source has determined that the properties in the representation are not newer than the current target object's properties. See `modificationAttribute` in `RKEntityMapping` for an example of when skipping property mapping would be appropriate. + + If this method is not implemented by the data source, then the mapping operation defaults to `NO`. + + @param mappingOperation The mapping operation that is querying the data source. + @return `YES` if the mapping operation should skip mapping properties, else `NO`. + */ - (BOOL)mappingOperationShouldSkipPropertyMapping:(RKMappingOperation *)mappingOperation DEPRECATED_MSG_ATTRIBUTE("use mappingOperationShouldSkipAttributeMapping: and mappingOperationShouldSkipRelationshipMapping: instead"); +/** + Asks the data source if it should skip mapping attributes. This method can significantly improve performance if, for example, the data source has determined that the attributes in the representation are not newer than the current target object's attributes. See `modificationAttribute` in `RKEntityMapping` for an example of when skipping attribute mapping would be appropriate. + + If this method is not implemented by the data source, then the mapping operation defaults to `NO`. + + @param mappingOperation The mapping operation that is querying the data source. + @return `YES` if the mapping operation should skip mapping attributes, else `NO`. + */ - (BOOL)mappingOperationShouldSkipAttributeMapping:(RKMappingOperation *)mappingOperation; +/** + Asks the data source if it should skip mapping relationships. This method can significantly improve performance if, for example, the data source has determined that the relationships in the representation are not newer than the current target object's relationships. See `modificationAttribute` and `shouldMapRelationshipsIfObjectIsUnmodified` in `RKEntityMapping` for an example of when skipping relationship mapping might be appropriate. + + If this method is not implemented by the data source, then the mapping operation defaults to `NO`. + + @param mappingOperation The mapping operation that is querying the data source. + @return `YES` if the mapping operation should skip mapping relationships, else `NO`. + */ - (BOOL)mappingOperationShouldSkipRelationshipMapping:(RKMappingOperation *)mappingOperation; /** From a874245036f213e5e767d27364d70490155f9662 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Fri, 28 Aug 2015 19:42:34 -0600 Subject: [PATCH 55/94] RKObjectMapping.inverseMappings should be `RKObjectMapping *` not `instancetype` --- Code/ObjectMapping/RKObjectMapping.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Code/ObjectMapping/RKObjectMapping.h b/Code/ObjectMapping/RKObjectMapping.h index ff15c62004..9094c11f09 100644 --- a/Code/ObjectMapping/RKObjectMapping.h +++ b/Code/ObjectMapping/RKObjectMapping.h @@ -340,7 +340,7 @@ @return A new mapping that will map the inverse of the receiver. */ -- (instancetype)inverseMapping; +- (RKObjectMapping *)inverseMapping; /** Generates an inverse mapping with all property mappings of the receiver that pass the given test. Each `RKAttributeMapping` and `RKRelationshipMapping` added to the receiver is yielded to the block for evaluation. The block is also invoked for any nested relationships that are traversed during the inversion process. @@ -349,7 +349,7 @@ @return A new mapping that will map the inverse of the receiver. @see inverseMapping */ -- (instancetype)inverseMappingWithPropertyMappingsPassingTest:(BOOL (^)(RKPropertyMapping *propertyMapping))predicate; +- (RKObjectMapping *)inverseMappingWithPropertyMappingsPassingTest:(BOOL (^)(RKPropertyMapping *propertyMapping))predicate; ///--------------------------------------------------- /// @name Obtaining Information About the Target Class From 5c055fe9208ce1bda37e25a0aef8c02c075ec020 Mon Sep 17 00:00:00 2001 From: "Samuel E. Giddins" Date: Sat, 29 Aug 2015 18:32:34 -0700 Subject: [PATCH 56/94] Use frameworks when integrating the OS X example --- Examples/RKMacOSX/Podfile | 1 + .../RKMacOSX.xcodeproj/project.pbxproj | 24 +++++++++++++++---- Podfile.lock | 10 ++++---- 3 files changed, 26 insertions(+), 9 deletions(-) diff --git a/Examples/RKMacOSX/Podfile b/Examples/RKMacOSX/Podfile index 573ff403c9..eb9c2b72ff 100644 --- a/Examples/RKMacOSX/Podfile +++ b/Examples/RKMacOSX/Podfile @@ -1,4 +1,5 @@ # Install via CocoaPods pointing at current local codebase +use_frameworks! pod 'RestKit/Network', :path => '../../' pod 'RestKit/ObjectMapping', :path => '../../' pod 'RestKit/CoreData', :path => '../../' diff --git a/Examples/RKMacOSX/RKMacOSX.xcodeproj/project.pbxproj b/Examples/RKMacOSX/RKMacOSX.xcodeproj/project.pbxproj index 1207602835..fb6735df27 100644 --- a/Examples/RKMacOSX/RKMacOSX.xcodeproj/project.pbxproj +++ b/Examples/RKMacOSX/RKMacOSX.xcodeproj/project.pbxproj @@ -7,7 +7,6 @@ objects = { /* Begin PBXBuildFile section */ - 1CE1DD3E5F2FE7DA177F56EF /* libPods.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A28BE5513E3B77C342497A9E /* libPods.a */; }; 25D63919135184CE000879B1 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 25D63918135184CE000879B1 /* Cocoa.framework */; }; 25D63923135184CE000879B1 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 25D63921135184CE000879B1 /* InfoPlist.strings */; }; 25D63926135184CE000879B1 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 25D63925135184CE000879B1 /* main.m */; }; @@ -17,9 +16,11 @@ 25D6397F13518574000879B1 /* CoreData.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 25D6397E13518574000879B1 /* CoreData.framework */; }; 25D639811351858A000879B1 /* AppKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 25D639801351858A000879B1 /* AppKit.framework */; }; 25D63983135185B6000879B1 /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 25D63982135185B6000879B1 /* SystemConfiguration.framework */; }; + 71754387C10576ABC5CC4966 /* Pods.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 148AFEC0CCE8D1725077BDEC /* Pods.framework */; settings = {ATTRIBUTES = (Weak, ); }; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ + 148AFEC0CCE8D1725077BDEC /* Pods.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 25D63914135184CE000879B1 /* RKMacOSX.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = RKMacOSX.app; sourceTree = BUILT_PRODUCTS_DIR; }; 25D63918135184CE000879B1 /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = System/Library/Frameworks/Cocoa.framework; sourceTree = SDKROOT; }; 25D6391B135184CE000879B1 /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = System/Library/Frameworks/AppKit.framework; sourceTree = SDKROOT; }; @@ -37,7 +38,6 @@ 25D639801351858A000879B1 /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = System/Library/Frameworks/AppKit.framework; sourceTree = SDKROOT; }; 25D63982135185B6000879B1 /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = System/Library/Frameworks/SystemConfiguration.framework; sourceTree = SDKROOT; }; 663395048EDD9B445E77BF72 /* Pods.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.debug.xcconfig; path = "Pods/Target Support Files/Pods/Pods.debug.xcconfig"; sourceTree = ""; }; - A28BE5513E3B77C342497A9E /* libPods.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libPods.a; sourceTree = BUILT_PRODUCTS_DIR; }; CDF0146ADF834F0317B19719 /* Pods.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.release.xcconfig; path = "Pods/Target Support Files/Pods/Pods.release.xcconfig"; sourceTree = ""; }; /* End PBXFileReference section */ @@ -50,7 +50,7 @@ 25D639811351858A000879B1 /* AppKit.framework in Frameworks */, 25D6397F13518574000879B1 /* CoreData.framework in Frameworks */, 25D63919135184CE000879B1 /* Cocoa.framework in Frameworks */, - 1CE1DD3E5F2FE7DA177F56EF /* libPods.a in Frameworks */, + 71754387C10576ABC5CC4966 /* Pods.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -84,7 +84,7 @@ 25D6397E13518574000879B1 /* CoreData.framework */, 25D63918135184CE000879B1 /* Cocoa.framework */, 25D6391A135184CE000879B1 /* Other Frameworks */, - A28BE5513E3B77C342497A9E /* libPods.a */, + 148AFEC0CCE8D1725077BDEC /* Pods.framework */, ); name = Frameworks; sourceTree = ""; @@ -143,6 +143,7 @@ 25D63911135184CE000879B1 /* Frameworks */, 25D63912135184CE000879B1 /* Resources */, E02916F51F1155DFDAB83400 /* Copy Pods Resources */, + 6CFBD5D31A295A90E94A1A6A /* Embed Pods Frameworks */, ); buildRules = ( ); @@ -207,6 +208,21 @@ shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n"; showEnvVarsInLog = 0; }; + 6CFBD5D31A295A90E94A1A6A /* Embed Pods Frameworks */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Embed Pods Frameworks"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods/Pods-frameworks.sh\"\n"; + showEnvVarsInLog = 0; + }; E02916F51F1155DFDAB83400 /* Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; diff --git a/Podfile.lock b/Podfile.lock index be721f31d4..a59bfa9255 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -25,7 +25,7 @@ PODS: - RestKit/Search (0.25.0): - RestKit/CoreData - RestKit/Support (0.25.0): - - TransitionKit (~> 2.1.0) + - TransitionKit (~> 2.2) - RestKit/Testing (0.25.0): - RestKit/Network - RKCLLocationValueTransformer (1.1.0): @@ -33,7 +33,7 @@ PODS: - RKValueTransformers (1.1.2) - SOCKit (1.1) - Specta (0.2.1) - - TransitionKit (2.1.1) + - TransitionKit (2.2.1) DEPENDENCIES: - AFNetworking (~> 1.3.0) @@ -48,7 +48,7 @@ DEPENDENCIES: - RKValueTransformers (~> 1.1.0) - SOCKit - Specta (= 0.2.1) - - TransitionKit (~> 2.1.0) + - TransitionKit (~> 2.2) EXTERNAL SOURCES: RestKit: @@ -60,11 +60,11 @@ SPEC CHECKSUMS: ISO8601DateFormatterValueTransformer: 52da467d6ec899d6aedda8e48280ac92e8ee97e6 OCHamcrest: e19857683e4eefab64b878668eac04c2f4567118 OCMock: a6a7dc0e3997fb9f35d99f72528698ebf60d64f2 - RestKit: a4fcaf3d4bb2c204679856a46d596160bf208095 + RestKit: da3154995dd4d8f5998dc3b6caba0ff85793841c RKCLLocationValueTransformer: 2cf0ea0fb7cd4bc70c56834fb92abc717c66f982 RKValueTransformers: 66ac5e4f077fdbe3496e792d89eeff4c3eb67701 SOCKit: c7376ac262bea9115b8f749358f762522a47d392 Specta: 15a276a6343867b426d5ed135d5aa4d04123a573 - TransitionKit: 3a14b6acc7cf2d1dd3e454e24dbad1cfab9a1ef1 + TransitionKit: 9ceccda4cd0cdc0a05ef85eb235e5a3292c3c250 COCOAPODS: 0.38.2 From 8cbb122f499ecfa9175311f78fc864d6f5e5b305 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Mon, 31 Aug 2015 12:35:10 -0700 Subject: [PATCH 57/94] Use NS_ENUM for RKMappingErrorCode --- Code/ObjectMapping/RKMappingErrors.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Code/ObjectMapping/RKMappingErrors.h b/Code/ObjectMapping/RKMappingErrors.h index 794e70340a..4636bcb803 100644 --- a/Code/ObjectMapping/RKMappingErrors.h +++ b/Code/ObjectMapping/RKMappingErrors.h @@ -20,8 +20,7 @@ #import "RKErrors.h" -typedef UInt32 RKMappingErrorCode; -enum { +typedef NS_ENUM(NSInteger, RKMappingErrorCode) { RKMappingErrorNotFound = 1001, // No mapping found RKMappingErrorTypeMismatch = 1002, // Target class and object mapping are in disagreement RKMappingErrorUnmappableRepresentation = 1003, // No values were found at the key paths of any attribute or relationship mappings in the given representation From 9cb579cf48a62dff1aac5ed6911fe1f5d06d0377 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ce=CC=81dric=20Luthi?= Date: Sun, 20 Sep 2015 23:24:00 +0200 Subject: [PATCH 58/94] Add debug logs for inferred identification attributes --- Code/CoreData/RKEntityMapping.m | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Code/CoreData/RKEntityMapping.m b/Code/CoreData/RKEntityMapping.m index 8a9037865b..a68096b71b 100644 --- a/Code/CoreData/RKEntityMapping.m +++ b/Code/CoreData/RKEntityMapping.m @@ -111,7 +111,9 @@ { NSArray *attributes = RKEntityIdentificationAttributesFromUserInfoOfEntity(entity); if (attributes) { - return RKArrayOfAttributesForEntityFromAttributesOrNames(entity, attributes); + NSArray *identificationAttributes = RKArrayOfAttributesForEntityFromAttributesOrNames(entity, attributes); + RKLogDebug(@"Inferred identification attributes for %@: %@", entity.name, [[identificationAttributes valueForKeyPath:@"name"] componentsJoinedByString:@", "]); + return identificationAttributes; } NSMutableArray *identifyingAttributes = [RKEntityIdentificationAttributeNamesForEntity(entity) mutableCopy]; @@ -119,9 +121,11 @@ for (NSString *attributeName in identifyingAttributes) { NSAttributeDescription *attribute = [[entity attributesByName] valueForKey:attributeName]; if (attribute) { + RKLogDebug(@"Inferred identification attribute for %@: %@", entity.name, attributeName); return @[ attribute ]; } } + RKLogDebug(@"No inferred identification attributes for %@", entity.name); return nil; } From b2f5c2d1d1e8cc16e9c1dfeacb6909a18c6f8e1e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ce=CC=81dric=20Luthi?= Date: Mon, 21 Sep 2015 00:02:18 +0200 Subject: [PATCH 59/94] Handle comma-separated string for `RKEntityIdentificationAttributes` This is useful if you want to enter the identification attributes directly in the xcdatamodel editor where the only type available for the User Info dictionary is string. --- Code/CoreData/RKEntityMapping.m | 10 +++++++++- Tests/Logic/CoreData/RKEntityMappingTest.m | 16 ++++++++++++++++ 2 files changed, 25 insertions(+), 1 deletion(-) diff --git a/Code/CoreData/RKEntityMapping.m b/Code/CoreData/RKEntityMapping.m index a68096b71b..a578e62869 100644 --- a/Code/CoreData/RKEntityMapping.m +++ b/Code/CoreData/RKEntityMapping.m @@ -39,7 +39,15 @@ do { id userInfoValue = [[entity userInfo] valueForKey:RKEntityIdentificationAttributesUserInfoKey]; if (userInfoValue) { - NSArray *attributeNames = [userInfoValue isKindOfClass:[NSArray class]] ? userInfoValue : @[ userInfoValue ]; + NSArray *attributeNames; + if ([userInfoValue isKindOfClass:[NSString class]]) { + attributeNames = [userInfoValue componentsSeparatedByString:@","]; + } else if ([userInfoValue isKindOfClass:[NSArray class]]) { + attributeNames = userInfoValue; + } else { + attributeNames = @[ userInfoValue ]; + } + NSMutableArray *attributes = [NSMutableArray arrayWithCapacity:[attributeNames count]]; [attributeNames enumerateObjectsUsingBlock:^(NSString *attributeName, NSUInteger idx, BOOL *stop) { if (! [attributeName isKindOfClass:[NSString class]]) { diff --git a/Tests/Logic/CoreData/RKEntityMappingTest.m b/Tests/Logic/CoreData/RKEntityMappingTest.m index 03bca00a66..2aeaba3359 100644 --- a/Tests/Logic/CoreData/RKEntityMappingTest.m +++ b/Tests/Logic/CoreData/RKEntityMappingTest.m @@ -619,6 +619,22 @@ - (void)testEntityIdentifierInferenceFromUserInfoKeyForSingleValue expect([identificationAttributes valueForKey:@"name"]).to.equal(attributeNames); } +- (void)testEntityIdentifierInferenceFromUserInfoKeyForCommaSeparatedString +{ + NSEntityDescription *entity = [[NSEntityDescription alloc] init]; + [entity setName:@"Monkey"]; + NSAttributeDescription *identifierAttribute = [NSAttributeDescription new]; + [identifierAttribute setName:@"monkeyID"]; + NSAttributeDescription *nameAttribute = [NSAttributeDescription new]; + [nameAttribute setName:@"name"]; + [entity setProperties:@[ identifierAttribute, nameAttribute ]]; + [entity setUserInfo:@{ RKEntityIdentificationAttributesUserInfoKey: @"name,monkeyID" }]; + NSArray *identificationAttributes = RKIdentificationAttributesInferredFromEntity(entity); + expect(identificationAttributes).notTo.beNil(); + NSArray *attributeNames = @[ @"name", @"monkeyID" ]; + expect([identificationAttributes valueForKey:@"name"]).to.equal(attributeNames); +} + - (void)testEntityIdentifierInferenceFromUserInfoKeyForArrayOfValues { NSEntityDescription *entity = [[NSEntityDescription alloc] init]; From ea1a8e8ef08ca3d686d2deb40a33e964c76db5ef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ce=CC=81dric=20Luthi?= Date: Mon, 21 Sep 2015 00:06:05 +0200 Subject: [PATCH 60/94] Use a for/in loop instead of `enumerateObjectsUsingBlock:` MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The index is not needed and a for/in loop is easier to handle with the debugger (step over doesn’t work with `enumerateObjectsUsingBlock:`). --- Code/CoreData/RKEntityMapping.m | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Code/CoreData/RKEntityMapping.m b/Code/CoreData/RKEntityMapping.m index a578e62869..9a90f38878 100644 --- a/Code/CoreData/RKEntityMapping.m +++ b/Code/CoreData/RKEntityMapping.m @@ -49,7 +49,7 @@ } NSMutableArray *attributes = [NSMutableArray arrayWithCapacity:[attributeNames count]]; - [attributeNames enumerateObjectsUsingBlock:^(NSString *attributeName, NSUInteger idx, BOOL *stop) { + for (NSString *attributeName in attributeNames) { if (! [attributeName isKindOfClass:[NSString class]]) { [NSException raise:NSInvalidArgumentException format:@"Invalid value given in user info key '%@' of entity '%@': expected an `NSString` or `NSArray` of strings, instead got '%@' (%@)", RKEntityIdentificationAttributesUserInfoKey, [entity name], attributeName, [attributeName class]]; } @@ -60,7 +60,7 @@ } [attributes addObject:attribute]; - }]; + }; return attributes; } entity = [entity superentity]; From 971b5a87278b968e202e79fd2d83eeb6b8506469 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ce=CC=81dric=20Luthi?= Date: Fri, 28 Aug 2015 15:04:20 +0200 Subject: [PATCH 61/94] Fix potential crash when mapping an invalid keyPath --- Code/ObjectMapping/RKMappingOperation.m | 37 +++++++++++-------- .../ObjectMapping/RKMappingOperationTest.m | 14 +++++++ 2 files changed, 35 insertions(+), 16 deletions(-) diff --git a/Code/ObjectMapping/RKMappingOperation.m b/Code/ObjectMapping/RKMappingOperation.m index b74c8f96d7..0cc8ae205d 100644 --- a/Code/ObjectMapping/RKMappingOperation.m +++ b/Code/ObjectMapping/RKMappingOperation.m @@ -317,22 +317,27 @@ - (id)valueForKeyPath:(NSString *)keyPath /* Using firstChar as a small performance enhancement -- one check can avoid several hasPrefix calls */ unichar firstChar = [keyPath length] > 0 ? [keyPath characterAtIndex:0] : 0; - if (firstChar == 's' && [keyPath hasPrefix:RKSelfKeyPathPrefix]) { - NSString *selfKeyPath = [keyPath substringFromIndex:[RKSelfKeyPathPrefix length]]; - return [_object valueForKeyPath:selfKeyPath]; - } else if (firstChar != '@') { - return [_object valueForKeyPath:keyPath]; - } else if ([keyPath hasPrefix:RKMetadataKeyPathPrefix]) { - NSString *metadataKeyPath = [keyPath substringFromIndex:[RKMetadataKeyPathPrefix length]]; - return [self metadataValueForKeyPath:metadataKeyPath]; - } else if ([keyPath hasPrefix:RKParentKeyPathPrefix]) { - NSString *parentKeyPath = [keyPath substringFromIndex:[RKParentKeyPathPrefix length]]; - return [self.parentObject valueForKeyPath:parentKeyPath]; - } else if ([keyPath hasPrefix:RKRootKeyPathPrefix]) { - NSString *rootKeyPath = [keyPath substringFromIndex:[RKRootKeyPathPrefix length]]; - return [self.rootObject valueForKeyPath:rootKeyPath]; - } else { - return [_object valueForKeyPath:keyPath]; + @try { + if (firstChar == 's' && [keyPath hasPrefix:RKSelfKeyPathPrefix]) { + NSString *selfKeyPath = [keyPath substringFromIndex:[RKSelfKeyPathPrefix length]]; + return [_object valueForKeyPath:selfKeyPath]; + } else if (firstChar != '@') { + return [_object valueForKeyPath:keyPath]; + } else if ([keyPath hasPrefix:RKMetadataKeyPathPrefix]) { + NSString *metadataKeyPath = [keyPath substringFromIndex:[RKMetadataKeyPathPrefix length]]; + return [self metadataValueForKeyPath:metadataKeyPath]; + } else if ([keyPath hasPrefix:RKParentKeyPathPrefix]) { + NSString *parentKeyPath = [keyPath substringFromIndex:[RKParentKeyPathPrefix length]]; + return [self.parentObject valueForKeyPath:parentKeyPath]; + } else if ([keyPath hasPrefix:RKRootKeyPathPrefix]) { + NSString *rootKeyPath = [keyPath substringFromIndex:[RKRootKeyPathPrefix length]]; + return [self.rootObject valueForKeyPath:rootKeyPath]; + } else { + return [_object valueForKeyPath:keyPath]; + } + } + @catch (NSException *exception) { + return nil; } } diff --git a/Tests/Logic/ObjectMapping/RKMappingOperationTest.m b/Tests/Logic/ObjectMapping/RKMappingOperationTest.m index a204269408..fdf496fb2c 100644 --- a/Tests/Logic/ObjectMapping/RKMappingOperationTest.m +++ b/Tests/Logic/ObjectMapping/RKMappingOperationTest.m @@ -288,6 +288,20 @@ - (void)testShouldFailTheMappingOperationIfKeyValueValidationSetsAnError assertThat(error, isNot(nilValue())); } +- (void)testShouldFailWithoutThrowingIfMappingAnInvalidKeyPath +{ + RKObjectMapping *mapping = [RKObjectMapping mappingForClass:[TestMappable class]]; + [mapping addAttributeMappingsFromDictionary:@{ @"object.number": @"number" }]; + TestMappable *object = [[TestMappable alloc] init]; + NSDictionary *dictionary = @{@"object": @"a string instead of a dictionary"}; + RKMappingOperation *operation = [[RKMappingOperation alloc] initWithSourceObject:dictionary destinationObject:object mapping:mapping]; + NSError *error = nil; + BOOL success = [operation performMapping:&error]; + assertThatBool(success, is(equalToBool(NO))); + assertThat(error.domain, is(equalTo(RKErrorDomain))); + assertThatInteger(error.code, is(equalToInteger(RKMappingErrorUnmappableRepresentation))); +} + - (void)testShouldNotSetTheAttributeIfKeyValueValidationReturnsNo { RKObjectMapping *mapping = [RKObjectMapping mappingForClass:[TestMappable class]]; From fc101de9133d96bc0e2221153de7f699f8c1f06d Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Thu, 24 Sep 2015 17:53:52 -0500 Subject: [PATCH 62/94] [Travis] Limit the branches we build --- .travis.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.travis.yml b/.travis.yml index 6971100594..d3015b8fc4 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,3 +5,8 @@ install: - bundle exec pod install script: - bundle exec rake ci +branches: + only: + - master + - development + - /^release/ From 4f23e6d7af9fc7e43eaf7918b27915de6f991a09 Mon Sep 17 00:00:00 2001 From: "Marc-A. Berube" Date: Wed, 30 Sep 2015 19:33:21 -0400 Subject: [PATCH 63/94] Fix nested refetched objects * Managed objects that were nested inside a sub-collection using a nil source key path were not refetched resulting on them being faulted (and not restorable) when they were accessed * Add test that covers the case --- .../Network/RKManagedObjectRequestOperation.m | 30 ++++++++++--------- RestKit.xcodeproj/project.pbxproj | 2 ++ ...to_one_relationship_inside_collection.json | 14 +++++++++ .../RKManagedObjectRequestOperationTest.m | 27 +++++++++++++++++ 4 files changed, 59 insertions(+), 14 deletions(-) create mode 100644 Tests/Fixtures/JSON/humans/with_to_one_relationship_inside_collection.json diff --git a/Code/Network/RKManagedObjectRequestOperation.m b/Code/Network/RKManagedObjectRequestOperation.m index 61b7b9a61a..8e1e72fa0c 100644 --- a/Code/Network/RKManagedObjectRequestOperation.m +++ b/Code/Network/RKManagedObjectRequestOperation.m @@ -262,20 +262,7 @@ - (RKMappingResult *)refetchedMappingResult NSString *destinationKey = [keyPathComponents lastObject]; [keyPathComponents removeLastObject]; id sourceObject = [keyPathComponents count] ? [mappingResultsAtRootKey valueForKeyPath:[keyPathComponents componentsJoinedByString:@"."]] : mappingResultsAtRootKey; - if (RKObjectIsCollection(sourceObject)) { - // This is a to-many relationship, we want to refetch each item at the keyPath - for (id nestedObject in sourceObject) { - // NOTE: If this collection was mapped with a dynamic mapping then each instance may not respond to the key - if ([nestedObject respondsToSelector:NSSelectorFromString(destinationKey)]) { - NSManagedObject *managedObject = [nestedObject valueForKey:destinationKey]; - [nestedObject setValue:RKRefetchedValueInManagedObjectContext(managedObject, self.managedObjectContext) forKey:destinationKey]; - } - } - } else { - // This is a singular relationship. We want to refetch the object and set it directly. - id valueToRefetch = [sourceObject valueForKey:destinationKey]; - [sourceObject setValue:RKRefetchedValueInManagedObjectContext(valueToRefetch, self.managedObjectContext) forKey:destinationKey]; - } + [self refetchSourceObject:sourceObject atDestinationKey:destinationKey]; } } } @@ -284,6 +271,21 @@ - (RKMappingResult *)refetchedMappingResult return [[RKMappingResult alloc] initWithDictionary:newDictionary]; } +- (void) refetchSourceObject:(id) sourceObject atDestinationKey:(NSString *)destinationKey { + if (RKObjectIsCollection(sourceObject)) { + // This is a to-many relationship, we want to refetch each item at the keyPath + for (id nestedObject in sourceObject) { + [self refetchSourceObject:nestedObject atDestinationKey:destinationKey]; + } + } else { + // NOTE: If this collection was mapped with a dynamic mapping then each instance may not respond to the key + if ([sourceObject respondsToSelector:NSSelectorFromString(destinationKey)]) { + id valueToRefetch = [sourceObject valueForKey:destinationKey]; + [sourceObject setValue:RKRefetchedValueInManagedObjectContext(valueToRefetch, self.managedObjectContext) forKey:destinationKey]; + } + } +} + @end NSArray *RKArrayOfFetchRequestFromBlocksWithURL(NSArray *fetchRequestBlocks, NSURL *URL) diff --git a/RestKit.xcodeproj/project.pbxproj b/RestKit.xcodeproj/project.pbxproj index ee6bd30e8c..7f3d0030f8 100644 --- a/RestKit.xcodeproj/project.pbxproj +++ b/RestKit.xcodeproj/project.pbxproj @@ -868,6 +868,7 @@ 25FBB851159272DD00955D27 /* RKRouter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKRouter.m; sourceTree = ""; }; 3E886DC0169E10A70069C56B /* has_many_with_to_one_relationship.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = has_many_with_to_one_relationship.json; sourceTree = ""; }; 3EB0D83816ADCEFC00E9CEA2 /* empty_human.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = empty_human.json; sourceTree = ""; }; + 538B0BD51BBCAF8C0068C386 /* with_to_one_relationship_inside_collection.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = with_to_one_relationship_inside_collection.json; sourceTree = ""; }; 54CDB45917B408B100FAC285 /* RKStringTokenizer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKStringTokenizer.h; sourceTree = ""; }; 54CDB45A17B408B100FAC285 /* RKStringTokenizer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKStringTokenizer.m; sourceTree = ""; }; 5910B0B01AC9811900721876 /* hoarderWithCats_issue_2192.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = hoarderWithCats_issue_2192.json; sourceTree = ""; }; @@ -1335,6 +1336,7 @@ 3E886DC0169E10A70069C56B /* has_many_with_to_one_relationship.json */, 25160FE31456F2330060A5C5 /* with_to_one_relationship.json */, F66056291744FF9000A87A45 /* and_cats.json */, + 538B0BD51BBCAF8C0068C386 /* with_to_one_relationship_inside_collection.json */, ); path = humans; sourceTree = ""; diff --git a/Tests/Fixtures/JSON/humans/with_to_one_relationship_inside_collection.json b/Tests/Fixtures/JSON/humans/with_to_one_relationship_inside_collection.json new file mode 100644 index 0000000000..aa5bb7b728 --- /dev/null +++ b/Tests/Fixtures/JSON/humans/with_to_one_relationship_inside_collection.json @@ -0,0 +1,14 @@ +[{ + "name": "Blake Watters", + "id": null, + "age": 28, + "favorite_cat_id": 1234, + "children": [ { + "name": "Marc Berube", + "id": null, + "age": 29, + "favorite_cat_id": 1234} + ] +} +] + diff --git a/Tests/Logic/Network/RKManagedObjectRequestOperationTest.m b/Tests/Logic/Network/RKManagedObjectRequestOperationTest.m index d10d34832c..ceb4407d8b 100644 --- a/Tests/Logic/Network/RKManagedObjectRequestOperationTest.m +++ b/Tests/Logic/Network/RKManagedObjectRequestOperationTest.m @@ -1364,6 +1364,33 @@ - (void)testThatRefetchingOfNestedNonManagedAndManagedObjectsWorksWithHasOneRela expect([user.bestFriend managedObjectContext]).to.equal(managedObjectStore.persistentStoreManagedObjectContext); } +- (void)testThatEntityMappingUsingNilKeyPathInsideNestedMappingDoesRefetchManagedObjects +{ + RKLogConfigureByName("RestKit/ObjectMapping", RKLogLevelTrace); + RKManagedObjectStore *managedObjectStore = [RKTestFactory managedObjectStore]; + RKObjectMapping *userMapping = [RKObjectMapping mappingForClass:[RKTestUser class]]; + RKEntityMapping *entityMapping = [RKEntityMapping mappingForEntityForName:@"Human" inManagedObjectStore:managedObjectStore]; + [entityMapping addPropertyMapping:[RKAttributeMapping attributeMappingFromKeyPath:nil toKeyPath:@"favoriteCatID"]]; + entityMapping.identificationAttributes = @[@"favoriteCatID"]; + [userMapping addPropertyMapping:[RKRelationshipMapping relationshipMappingFromKeyPath:@"favorite_cat_id" toKeyPath:@"bestFriend" withMapping:entityMapping]]; + [userMapping addPropertyMapping:[RKRelationshipMapping relationshipMappingFromKeyPath:@"children" toKeyPath:@"friends" withMapping:userMapping]]; + RKResponseDescriptor *responseDescriptor = [RKResponseDescriptor responseDescriptorWithMapping:userMapping method:RKRequestMethodAny pathPattern:nil keyPath:nil statusCodes:[NSIndexSet indexSetWithIndex:200]]; + + NSURLRequest *request = [NSURLRequest requestWithURL:[NSURL URLWithString:@"/JSON/humans/with_to_one_relationship_inside_collection.json" relativeToURL:[RKTestFactory baseURL]]]; + RKManagedObjectRequestOperation *managedObjectRequestOperation = [[RKManagedObjectRequestOperation alloc] initWithRequest:request responseDescriptors:@[ responseDescriptor ]]; + managedObjectRequestOperation.managedObjectContext = managedObjectStore.persistentStoreManagedObjectContext; + [managedObjectRequestOperation start]; + [managedObjectRequestOperation waitUntilFinished]; + expect(managedObjectRequestOperation.error).to.beNil(); + RKMappableObject *result = managedObjectRequestOperation.mappingResult.firstObject; + RKTestUser *user = (RKTestUser *)result; + expect(user.bestFriend).to.beInstanceOf([RKHuman class]); + expect(user.friends.count).to.equal(1); + RKTestUser *child = (RKTestUser *)user.friends.firstObject; + expect([user.bestFriend managedObjectContext]).to.equal(managedObjectStore.persistentStoreManagedObjectContext); + expect([child.bestFriend managedObjectContext]).to.equal(managedObjectStore.persistentStoreManagedObjectContext); +} + - (void)testThatAnEmptyResultHasTheProperManagedObjectContext { RKManagedObjectStore *managedObjectStore = [RKTestFactory managedObjectStore]; From af03d63b6d20f336625d07cc8194419ad8a45bd7 Mon Sep 17 00:00:00 2001 From: Nick Robinson Date: Thu, 1 Oct 2015 12:13:54 -0400 Subject: [PATCH 64/94] override superclass designated initializer and throw exception if designated initilizer should be used instead. --- Code/CoreData/RKManagedObjectStore.m | 22 ++++++++---- Code/Network/RKPaginator.m | 8 +++++ Code/Network/RKResponseMapperOperation.m | 8 +++++ Code/ObjectMapping/RKMappingOperation.m | 8 +++++ Code/ObjectMapping/RKObjectMappingMatcher.m | 40 +++++++++++++++++++++ Code/Search/RKSearchPredicate.m | 16 +++++++++ Code/Support/RKMIMETypeSerialization.m | 8 +++++ Code/Support/RKURLEncodedSerialization.m | 8 +++++ Code/Testing/RKMappingTest.m | 8 +++++ 9 files changed, 120 insertions(+), 6 deletions(-) diff --git a/Code/CoreData/RKManagedObjectStore.m b/Code/CoreData/RKManagedObjectStore.m index ef9f96ecaa..f4d41bc6be 100644 --- a/Code/CoreData/RKManagedObjectStore.m +++ b/Code/CoreData/RKManagedObjectStore.m @@ -70,6 +70,14 @@ - (instancetype)initWithObservedContext:(NSManagedObjectContext *)observedContex @implementation RKManagedObjectContextChangeMergingObserver +- (instancetype)init +{ + @throw [NSException exceptionWithName:NSInternalInconsistencyException + reason:[NSString stringWithFormat:@"-init is not a valid initializer for the class %@, use designated initilizer -initWithObservedContext:mergeContext:", NSStringFromClass([self class])] + userInfo:nil]; + return [self init]; +} + - (instancetype)initWithObservedContext:(NSManagedObjectContext *)observedContext mergeContext:(NSManagedObjectContext *)mergeContext { if (! observedContext) [NSException raise:NSInvalidArgumentException format:@"observedContext cannot be `nil`."]; @@ -165,6 +173,14 @@ + (void)setDefaultStore:(RKManagedObjectStore *)managedObjectStore } } +- (instancetype)init +{ + @throw [NSException exceptionWithName:NSInternalInconsistencyException + reason:[NSString stringWithFormat:@"-init is not a valid initializer for the class %@, use designated initilizer -initWithManagedObjectModel:", NSStringFromClass([self class])] + userInfo:nil]; + return [self init]; +} + - (instancetype)initWithManagedObjectModel:(NSManagedObjectModel *)managedObjectModel { self = [super init]; @@ -191,12 +207,6 @@ - (instancetype)initWithPersistentStoreCoordinator:(NSPersistentStoreCoordinator return self; } -- (instancetype)init -{ - NSManagedObjectModel *managedObjectModel = [NSManagedObjectModel mergedModelFromBundles:[NSBundle allBundles]]; - return [self initWithManagedObjectModel:managedObjectModel]; -} - - (void)dealloc { [[NSNotificationCenter defaultCenter] removeObserver:self]; diff --git a/Code/Network/RKPaginator.m b/Code/Network/RKPaginator.m index f5ef61d402..3b7034d021 100644 --- a/Code/Network/RKPaginator.m +++ b/Code/Network/RKPaginator.m @@ -60,6 +60,14 @@ @interface RKPaginator () @implementation RKPaginator +- (instancetype)init +{ + @throw [NSException exceptionWithName:NSInternalInconsistencyException + reason:[NSString stringWithFormat:@"-init is not a valid initializer for the class %@, use designated initilizer -initWithRequest:paginationMapping:responseDescriptors:", NSStringFromClass([self class])] + userInfo:nil]; + return [self init]; +} + - (instancetype)initWithRequest:(NSURLRequest *)request paginationMapping:(RKObjectMapping *)paginationMapping responseDescriptors:(NSArray *)responseDescriptors; diff --git a/Code/Network/RKResponseMapperOperation.m b/Code/Network/RKResponseMapperOperation.m index 81787e8c8f..d7103a188d 100644 --- a/Code/Network/RKResponseMapperOperation.m +++ b/Code/Network/RKResponseMapperOperation.m @@ -173,6 +173,14 @@ + (void)registerMappingOperationDataSourceClass:(Class *)subpredicates +{ + @throw [NSException exceptionWithName:NSInternalInconsistencyException + reason:[NSString stringWithFormat:@"-initWithType: is not a valid initializer for the class %@, use designated initilizer -initWithSearchText:type:", NSStringFromClass([self class])] + userInfo:nil]; + return [self init]; +} + - (instancetype)initWithSearchText:(NSString *)searchText type:(NSCompoundPredicateType)type { RKStringTokenizer *tokenizer = [RKStringTokenizer new]; diff --git a/Code/Support/RKMIMETypeSerialization.m b/Code/Support/RKMIMETypeSerialization.m index caf414510e..2e3bf562a8 100644 --- a/Code/Support/RKMIMETypeSerialization.m +++ b/Code/Support/RKMIMETypeSerialization.m @@ -40,6 +40,14 @@ - (BOOL)matchesMIMEType:(NSString *)MIMEType; @implementation RKMIMETypeSerializationRegistration +- (instancetype)init +{ + @throw [NSException exceptionWithName:NSInternalInconsistencyException + reason:[NSString stringWithFormat:@"-init is not a valid initializer for the class %@, use designated initilizer -initWithMIMEType:serializationClass:", NSStringFromClass([self class])] + userInfo:nil]; + return [self init]; +} + - (instancetype)initWithMIMEType:(id)MIMETypeStringOrRegularExpression serializationClass:(Class)serializationClass { NSParameterAssert(MIMETypeStringOrRegularExpression); diff --git a/Code/Support/RKURLEncodedSerialization.m b/Code/Support/RKURLEncodedSerialization.m index 09f7ae7557..8a1d7ed9c6 100644 --- a/Code/Support/RKURLEncodedSerialization.m +++ b/Code/Support/RKURLEncodedSerialization.m @@ -49,6 +49,14 @@ - (NSString *)URLEncodedStringValueWithEncoding:(NSStringEncoding)stringEncoding @implementation RKAFQueryStringPair +- (instancetype)init +{ + @throw [NSException exceptionWithName:NSInternalInconsistencyException + reason:[NSString stringWithFormat:@"-init is not a valid initializer for the class %@, use designated initilizer -initWithField:", NSStringFromClass([self class])] + userInfo:nil]; + return [self init]; +} + - (instancetype)initWithField:(id)field value:(id)value { self = [super init]; if (!self) { diff --git a/Code/Testing/RKMappingTest.m b/Code/Testing/RKMappingTest.m index 9ef84e5224..231f5fb631 100644 --- a/Code/Testing/RKMappingTest.m +++ b/Code/Testing/RKMappingTest.m @@ -152,6 +152,14 @@ + (instancetype)testForMapping:(RKMapping *)mapping sourceObject:(id)sourceObjec return [[self alloc] initWithMapping:mapping sourceObject:sourceObject destinationObject:destinationObject]; } +- (instancetype)init +{ + @throw [NSException exceptionWithName:NSInternalInconsistencyException + reason:[NSString stringWithFormat:@"-init is not a valid initializer for the class %@, use designated initilizer -initWithMapping", NSStringFromClass([self class])] + userInfo:nil]; + return [self init]; +} + - (instancetype)initWithMapping:(RKMapping *)mapping sourceObject:(id)sourceObject destinationObject:(id)destinationObject { NSAssert(sourceObject != nil, @"Cannot perform a mapping operation without a sourceObject object"); From 4facc308f9ca3351016c942ab2262f7955da63b7 Mon Sep 17 00:00:00 2001 From: Nick Robinson Date: Thu, 1 Oct 2015 12:23:27 -0400 Subject: [PATCH 65/94] additional initializer overrides --- Code/Network/RKObjectManager.m | 16 ++++++++++++++++ Code/ObjectMapping/RKMapperOperation.m | 8 ++++++++ 2 files changed, 24 insertions(+) diff --git a/Code/Network/RKObjectManager.m b/Code/Network/RKObjectManager.m index 2d27428724..994d955130 100644 --- a/Code/Network/RKObjectManager.m +++ b/Code/Network/RKObjectManager.m @@ -172,6 +172,14 @@ @interface RKMappingGraphVisitor () @implementation RKMappingGraphVisitor +- (instancetype)init +{ + @throw [NSException exceptionWithName:NSInternalInconsistencyException + reason:[NSString stringWithFormat:@"-init is not a valid initializer for the class %@, use designated initilizer -initWithMapping:", NSStringFromClass([self class])] + userInfo:nil]; + return [self init]; +} + - (instancetype)initWithMapping:(RKMapping *)mapping { self = [super init]; @@ -348,6 +356,14 @@ @interface RKObjectManager () @implementation RKObjectManager +- (instancetype)init +{ + @throw [NSException exceptionWithName:NSInternalInconsistencyException + reason:[NSString stringWithFormat:@"-init is not a valid initializer for the class %@, use designated initilizer -initWithHTTPClient:", NSStringFromClass([self class])] + userInfo:nil]; + return [self init]; +} + - (instancetype)initWithHTTPClient:(AFHTTPClient *)client { self = [super init]; diff --git a/Code/ObjectMapping/RKMapperOperation.m b/Code/ObjectMapping/RKMapperOperation.m index 163caeffe1..d8f1cb0871 100644 --- a/Code/ObjectMapping/RKMapperOperation.m +++ b/Code/ObjectMapping/RKMapperOperation.m @@ -80,6 +80,14 @@ @interface RKMapperOperation () @implementation RKMapperOperation +- (instancetype)init +{ + @throw [NSException exceptionWithName:NSInternalInconsistencyException + reason:[NSString stringWithFormat:@"-init is not a valid initializer for the class %@, use designated initilizer -initWithRepresentation:mappingDictionary:", NSStringFromClass([self class])] + userInfo:nil]; + return [self init]; +} + - (instancetype)initWithRepresentation:(id)representation mappingsDictionary:(NSDictionary *)mappingsDictionary; { self = [super init]; From 60789151583b0ff900cdb0d143f05a90fff26e65 Mon Sep 17 00:00:00 2001 From: Nick Robinson Date: Thu, 1 Oct 2015 12:37:58 -0400 Subject: [PATCH 66/94] removed typed array --- Code/Search/RKSearchPredicate.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Search/RKSearchPredicate.m b/Code/Search/RKSearchPredicate.m index 43b66b2e6d..ecb1369ffc 100644 --- a/Code/Search/RKSearchPredicate.m +++ b/Code/Search/RKSearchPredicate.m @@ -24,7 +24,7 @@ - (instancetype)initWithCoder:(NSCoder *)coder return [self init]; } -- (instancetype)initWithType:(NSCompoundPredicateType)type subpredicates:(NSArray *)subpredicates +- (instancetype)initWithType:(NSCompoundPredicateType)type subpredicates:(NSArray *)subpredicates { @throw [NSException exceptionWithName:NSInternalInconsistencyException reason:[NSString stringWithFormat:@"-initWithType: is not a valid initializer for the class %@, use designated initilizer -initWithSearchText:type:", NSStringFromClass([self class])] From 75fca812b48873150f7d7d9b9b0782e35c419a68 Mon Sep 17 00:00:00 2001 From: Nick Robinson Date: Thu, 1 Oct 2015 16:50:52 -0400 Subject: [PATCH 67/94] Internally assign initWithType:subpredicates as designated initializer while leaving initWithSearchText:type: as external designated initializer. unmark RKPaginator initWithRequest:pagingMapping:responseDescriptors as designated initializer. --- Code/Network/RKPaginator.h | 4 ++-- Code/Network/RKPaginator.m | 7 ------- Code/ObjectMapping/RKMapperOperation.m | 5 +---- Code/Search/RKSearchPredicate.m | 11 +++++++---- 4 files changed, 10 insertions(+), 17 deletions(-) diff --git a/Code/Network/RKPaginator.h b/Code/Network/RKPaginator.h index 32cda58328..9baecd0f10 100644 --- a/Code/Network/RKPaginator.h +++ b/Code/Network/RKPaginator.h @@ -63,8 +63,8 @@ @return The receiver, initialized with the request, pagination mapping, and response descriptors. */ - (instancetype)initWithRequest:(NSURLRequest *)request - paginationMapping:(RKObjectMapping *)paginationMapping - responseDescriptors:(NSArray *)responseDescriptors NS_DESIGNATED_INITIALIZER; + paginationMapping:(RKObjectMapping *)paginationMapping + responseDescriptors:(NSArray *)responseDescriptors; ///----------------------------- /// @name Configuring Networking diff --git a/Code/Network/RKPaginator.m b/Code/Network/RKPaginator.m index 3b7034d021..9d93465afb 100644 --- a/Code/Network/RKPaginator.m +++ b/Code/Network/RKPaginator.m @@ -60,13 +60,6 @@ @interface RKPaginator () @implementation RKPaginator -- (instancetype)init -{ - @throw [NSException exceptionWithName:NSInternalInconsistencyException - reason:[NSString stringWithFormat:@"-init is not a valid initializer for the class %@, use designated initilizer -initWithRequest:paginationMapping:responseDescriptors:", NSStringFromClass([self class])] - userInfo:nil]; - return [self init]; -} - (instancetype)initWithRequest:(NSURLRequest *)request paginationMapping:(RKObjectMapping *)paginationMapping diff --git a/Code/ObjectMapping/RKMapperOperation.m b/Code/ObjectMapping/RKMapperOperation.m index d8f1cb0871..c58cebc595 100644 --- a/Code/ObjectMapping/RKMapperOperation.m +++ b/Code/ObjectMapping/RKMapperOperation.m @@ -82,10 +82,7 @@ @implementation RKMapperOperation - (instancetype)init { - @throw [NSException exceptionWithName:NSInternalInconsistencyException - reason:[NSString stringWithFormat:@"-init is not a valid initializer for the class %@, use designated initilizer -initWithRepresentation:mappingDictionary:", NSStringFromClass([self class])] - userInfo:nil]; - return [self init]; + return [self initWithRepresentation:nil mappingsDictionary:nil]; } - (instancetype)initWithRepresentation:(id)representation mappingsDictionary:(NSDictionary *)mappingsDictionary; diff --git a/Code/Search/RKSearchPredicate.m b/Code/Search/RKSearchPredicate.m index ecb1369ffc..37df4d9b62 100644 --- a/Code/Search/RKSearchPredicate.m +++ b/Code/Search/RKSearchPredicate.m @@ -9,6 +9,12 @@ #import "RKSearchPredicate.h" #import "RKStringTokenizer.h" +@interface RKSearchPredicate() + +- (instancetype)initWithType:(NSCompoundPredicateType)type subpredicates:(NSArray *)subpredicates NS_DESIGNATED_INITIALIZER; + +@end + @implementation RKSearchPredicate + (NSPredicate *)searchPredicateWithText:(NSString *)searchText type:(NSCompoundPredicateType)type @@ -26,10 +32,7 @@ - (instancetype)initWithCoder:(NSCoder *)coder - (instancetype)initWithType:(NSCompoundPredicateType)type subpredicates:(NSArray *)subpredicates { - @throw [NSException exceptionWithName:NSInternalInconsistencyException - reason:[NSString stringWithFormat:@"-initWithType: is not a valid initializer for the class %@, use designated initilizer -initWithSearchText:type:", NSStringFromClass([self class])] - userInfo:nil]; - return [self init]; + return [super initWithType:type subpredicates:subpredicates]; } - (instancetype)initWithSearchText:(NSString *)searchText type:(NSCompoundPredicateType)type From 224244889ccbb955e89e46e92c8d19b8a6bff452 Mon Sep 17 00:00:00 2001 From: Nick Robinson Date: Mon, 5 Oct 2015 12:18:30 -0400 Subject: [PATCH 68/94] Reverted back to calling designated initializer initWithManagedObjectModel from overrided -init method. --- Code/CoreData/RKManagedObjectStore.m | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/Code/CoreData/RKManagedObjectStore.m b/Code/CoreData/RKManagedObjectStore.m index f4d41bc6be..862acd106d 100644 --- a/Code/CoreData/RKManagedObjectStore.m +++ b/Code/CoreData/RKManagedObjectStore.m @@ -173,14 +173,6 @@ + (void)setDefaultStore:(RKManagedObjectStore *)managedObjectStore } } -- (instancetype)init -{ - @throw [NSException exceptionWithName:NSInternalInconsistencyException - reason:[NSString stringWithFormat:@"-init is not a valid initializer for the class %@, use designated initilizer -initWithManagedObjectModel:", NSStringFromClass([self class])] - userInfo:nil]; - return [self init]; -} - - (instancetype)initWithManagedObjectModel:(NSManagedObjectModel *)managedObjectModel { self = [super init]; @@ -197,6 +189,12 @@ - (instancetype)initWithManagedObjectModel:(NSManagedObjectModel *)managedObject return self; } +- (instancetype)init +{ + NSManagedObjectModel *managedObjectModel = [NSManagedObjectModel mergedModelFromBundles:[NSBundle allBundles]]; + return [self initWithManagedObjectModel:managedObjectModel]; +} + - (instancetype)initWithPersistentStoreCoordinator:(NSPersistentStoreCoordinator *)persistentStoreCoordinator { self = [self initWithManagedObjectModel:persistentStoreCoordinator.managedObjectModel]; From 12d99d80e5c9c85013ccc94c888b77ab79717465 Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Fri, 9 Oct 2015 20:06:08 -0500 Subject: [PATCH 69/94] [Gemfile] Update CocoaPods to 0.39 --- .../RKTwitter.xcodeproj/project.pbxproj | 2 +- Gemfile | 2 +- Gemfile.lock | 51 ++++++++++--------- Podfile.lock | 2 +- RestKit.xcodeproj/project.pbxproj | 34 ++++++++++++- 5 files changed, 62 insertions(+), 29 deletions(-) diff --git a/Examples/RKTwitter/RKTwitter.xcodeproj/project.pbxproj b/Examples/RKTwitter/RKTwitter.xcodeproj/project.pbxproj index 5a0ec789fc..0c69e0326e 100755 --- a/Examples/RKTwitter/RKTwitter.xcodeproj/project.pbxproj +++ b/Examples/RKTwitter/RKTwitter.xcodeproj/project.pbxproj @@ -23,7 +23,7 @@ 25AABD0B17B69CC50061DC5B /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1D30AB110D05D00D00671497 /* Foundation.framework */; }; 25AABD0C17B69CC50061DC5B /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1DF5F4DF0D08C38300B7A737 /* UIKit.framework */; }; 25AABD0D17B69CC50061DC5B /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 288765A40DF7441C002DB57D /* CoreGraphics.framework */; }; - 73D990C2D2D5A068521FACEF /* Pods.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F0C5817426474EE329BB79E2 /* Pods.framework */; settings = {ATTRIBUTES = (Weak, ); }; }; + 73D990C2D2D5A068521FACEF /* Pods.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F0C5817426474EE329BB79E2 /* Pods.framework */; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ diff --git a/Gemfile b/Gemfile index 5cd08006e6..a5b2ace934 100644 --- a/Gemfile +++ b/Gemfile @@ -4,6 +4,6 @@ gem 'rakeup', '~> 1.2.0' gem 'sinatra', '~> 1.4.0' gem 'sinatra-contrib', '~> 1.4.0' gem 'thin', '~> 1.5.0' -gem 'cocoapods', '~> 0.38.0' +gem 'cocoapods', '~> 0.39.0' gem 'xctasks', '~> 0.5.0' gem 'xcpretty', '~> 0.1.6' diff --git a/Gemfile.lock b/Gemfile.lock index d14a9b2ba5..529299f8ba 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,7 +1,7 @@ GEM remote: https://rubygems.org/ specs: - activesupport (4.2.3) + activesupport (4.2.4) i18n (~> 0.7) json (~> 1.7, >= 1.7.7) minitest (~> 5.1) @@ -9,33 +9,34 @@ GEM tzinfo (~> 1.1) backports (3.6.5) claide (0.9.1) - cocoapods (0.38.2) - activesupport (>= 3.2.15) + cocoapods (0.39.0) + activesupport (>= 4.0.2) claide (~> 0.9.1) - cocoapods-core (= 0.38.2) - cocoapods-downloader (~> 0.9.1) + cocoapods-core (= 0.39.0) + cocoapods-downloader (~> 0.9.3) cocoapods-plugins (~> 0.4.2) - cocoapods-stats (~> 0.5.3) - cocoapods-trunk (~> 0.6.1) - cocoapods-try (~> 0.4.5) + cocoapods-search (~> 0.1.0) + cocoapods-stats (~> 0.6.2) + cocoapods-trunk (~> 0.6.4) + cocoapods-try (~> 0.5.1) colored (~> 1.2) escape (~> 0.0.4) - molinillo (~> 0.3.1) - nap (~> 0.8) - xcodeproj (~> 0.26.3) - cocoapods-core (0.38.2) - activesupport (>= 3.2.15) + molinillo (~> 0.4.0) + nap (~> 1.0) + xcodeproj (~> 0.28.2) + cocoapods-core (0.39.0) + activesupport (>= 4.0.2) fuzzy_match (~> 2.0.4) - nap (~> 0.8.0) - cocoapods-downloader (0.9.1) + nap (~> 1.0) + cocoapods-downloader (0.9.3) cocoapods-plugins (0.4.2) nap - cocoapods-stats (0.5.3) - nap (~> 0.8) - cocoapods-trunk (0.6.1) - nap (>= 0.8) + cocoapods-search (0.1.0) + cocoapods-stats (0.6.2) + cocoapods-trunk (0.6.4) + nap (>= 0.8, < 2.0) netrc (= 0.7.8) - cocoapods-try (0.4.5) + cocoapods-try (0.5.1) colored (1.2) daemons (1.2.3) escape (0.0.4) @@ -44,10 +45,10 @@ GEM i18n (0.7.0) json (1.8.3) mini_portile (0.6.2) - minitest (5.8.0) - molinillo (0.3.1) + minitest (5.8.1) + molinillo (0.4.0) multi_json (1.11.2) - nap (0.8.0) + nap (1.0.0) netrc (0.7.8) nokogiri (1.6.6.2) mini_portile (~> 0.6.0) @@ -79,7 +80,7 @@ GEM tilt (2.0.1) tzinfo (1.2.2) thread_safe (~> 0.1) - xcodeproj (0.26.3) + xcodeproj (0.28.2) activesupport (>= 3) claide (~> 0.9.1) colored (~> 1.2) @@ -92,7 +93,7 @@ PLATFORMS ruby DEPENDENCIES - cocoapods (~> 0.38.0) + cocoapods (~> 0.39.0) rakeup (~> 1.2.0) sinatra (~> 1.4.0) sinatra-contrib (~> 1.4.0) diff --git a/Podfile.lock b/Podfile.lock index a59bfa9255..2694653fe9 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -67,4 +67,4 @@ SPEC CHECKSUMS: Specta: 15a276a6343867b426d5ed135d5aa4d04123a573 TransitionKit: 9ceccda4cd0cdc0a05ef85eb235e5a3292c3c250 -COCOAPODS: 0.38.2 +COCOAPODS: 0.39.0 diff --git a/RestKit.xcodeproj/project.pbxproj b/RestKit.xcodeproj/project.pbxproj index 7f3d0030f8..79b4449a5e 100644 --- a/RestKit.xcodeproj/project.pbxproj +++ b/RestKit.xcodeproj/project.pbxproj @@ -884,12 +884,12 @@ 73D3907114CA19F90093E3D6 /* parent.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = parent.json; sourceTree = ""; }; 73D3907314CA1A4A0093E3D6 /* child.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = child.json; sourceTree = ""; }; 73D3907814CA1D710093E3D6 /* channels.xml */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = channels.xml; sourceTree = ""; }; + 8AB68F0A1AE5B3B300DD655A /* RKFetchedResultsControllerUpdateTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKFetchedResultsControllerUpdateTest.m; sourceTree = ""; }; 9B15BBB1F11B91C32F72DFBF /* libPods-RestKitFramework.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-RestKitFramework.a"; sourceTree = BUILT_PRODUCTS_DIR; }; A339C3AFD7C094BEAFE92A93 /* Pods-ios.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ios.release.xcconfig"; path = "Pods/Target Support Files/Pods-ios/Pods-ios.release.xcconfig"; sourceTree = ""; }; A920AEDAEC3C6599433D2720 /* Pods-osx.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-osx.debug.xcconfig"; path = "Pods/Target Support Files/Pods-osx/Pods-osx.debug.xcconfig"; sourceTree = ""; }; AD144E244684975F290D70ED /* Pods-RestKit.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RestKit.release.xcconfig"; path = "Pods/Target Support Files/Pods-RestKit/Pods-RestKit.release.xcconfig"; sourceTree = ""; }; AD2DD8D9C9EA769B53865C88 /* Pods-RestKit.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RestKit.debug.xcconfig"; path = "Pods/Target Support Files/Pods-RestKit/Pods-RestKit.debug.xcconfig"; sourceTree = ""; }; - 8AB68F0A1AE5B3B300DD655A /* RKFetchedResultsControllerUpdateTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKFetchedResultsControllerUpdateTest.m; sourceTree = ""; }; BE05BDCF1782109F00F7C9C9 /* RKRouteTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKRouteTest.m; sourceTree = ""; }; C0F11CE1190883380054AEA0 /* RKPathMatcher.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKPathMatcher.h; sourceTree = ""; }; C0F11CE2190883380054AEA0 /* RKPathMatcher.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKPathMatcher.m; sourceTree = ""; }; @@ -1842,6 +1842,7 @@ 25160D2314564E820060A5C5 /* Resources */, 25160D2414564E820060A5C5 /* ShellScript */, D00A58B091EC84A57A1FB098 /* Copy Pods Resources */, + D53939EC83FE6753732850FE /* Embed Pods Frameworks */, ); buildRules = ( ); @@ -1884,6 +1885,7 @@ 250CA67F147D8EEC0047D347 /* CopyFiles */, 25160E76145651060060A5C5 /* ShellScript */, D9DDA304517443E2F6FD2B2C /* Copy Pods Resources */, + 2FFB30DF4A3D492F0C2C5F2C /* Embed Pods Frameworks */, ); buildRules = ( ); @@ -2071,6 +2073,21 @@ shellPath = /bin/sh; shellScript = "# Run the unit tests in this test bundle.\n\"${SYSTEM_DEVELOPER_DIR}/Tools/RunUnitTests\"\n"; }; + 2FFB30DF4A3D492F0C2C5F2C /* Embed Pods Frameworks */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Embed Pods Frameworks"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-osx/Pods-osx-frameworks.sh\"\n"; + showEnvVarsInLog = 0; + }; 31E61254417653D2A601DDF8 /* Check Pods Manifest.lock */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; @@ -2146,6 +2163,21 @@ shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-ios/Pods-ios-resources.sh\"\n"; showEnvVarsInLog = 0; }; + D53939EC83FE6753732850FE /* Embed Pods Frameworks */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Embed Pods Frameworks"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-ios/Pods-ios-frameworks.sh\"\n"; + showEnvVarsInLog = 0; + }; D9DDA304517443E2F6FD2B2C /* Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; From 49dae11423f662db2d89569a8b4e2898bd73f440 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roger=20Jo=CC=88nsson?= Date: Mon, 26 Oct 2015 14:07:21 +0100 Subject: [PATCH 70/94] Support "Age" HTTP response header. According to RFC 2616 content delivery networks (CDNs) shall deliver the Date header received from the origin. Amazon CloudFront have this behaviour, many others don't. Clients must use the Age parameter in order to calculate the next validation time, since infrequently changed messages will have old Date values. This commit makes use of the Age parameter if it exist and is larger than zero. Otherwise the logic is as before. Previously RestKit returned expire dates from the past during these circumstances. --- Code/ObjectMapping/RKHTTPUtilities.m | 11 ++++++++++- Tests/Logic/Support/RKHTTPUtilitiesTest.m | 24 +++++++++++++++++++++++ 2 files changed, 34 insertions(+), 1 deletion(-) diff --git a/Code/ObjectMapping/RKHTTPUtilities.m b/Code/ObjectMapping/RKHTTPUtilities.m index 046a3edb99..ac8eeeb7f9 100644 --- a/Code/ObjectMapping/RKHTTPUtilities.m +++ b/Code/ObjectMapping/RKHTTPUtilities.m @@ -503,7 +503,16 @@ RKRequestMethod RKRequestMethodFromString(NSString *methodName) [cacheControlScanner setScanLocation:foundRange.location + foundRange.length]; [cacheControlScanner scanString:@"=" intoString:nil]; if ([cacheControlScanner scanInteger:&maxAge]) { - return maxAge > 0 ? [[NSDate alloc] initWithTimeInterval:maxAge sinceDate:now] : nil; + if(maxAge > 0) + { + const NSInteger age = ((NSString *)headers[@"Age"]).integerValue; + if(age > 0) + return [[NSDate alloc] initWithTimeIntervalSinceNow:(maxAge - age)]; + else + return [[NSDate alloc] initWithTimeInterval:maxAge sinceDate:now]; + } + else + return nil; } } } diff --git a/Tests/Logic/Support/RKHTTPUtilitiesTest.m b/Tests/Logic/Support/RKHTTPUtilitiesTest.m index 1493272979..e451be4bdb 100644 --- a/Tests/Logic/Support/RKHTTPUtilitiesTest.m +++ b/Tests/Logic/Support/RKHTTPUtilitiesTest.m @@ -171,4 +171,28 @@ - (void)testRKDateFromHTTPDateString testBlock(dateComponents); } +- (void)testRKHTTPCacheExpirationDateFromHeadersWithStatusCode +{ + const NSInteger maxAge = 3600; + NSDate * const date = [NSDate dateWithTimeIntervalSinceReferenceDate:1234]; + + NSDateFormatter * const dateFormatter = [[NSDateFormatter alloc] init]; + dateFormatter.locale = [[NSLocale alloc] initWithLocaleIdentifier:@"en_US"]; + dateFormatter.timeZone = [NSTimeZone timeZoneWithAbbreviation:@"GMT"]; + dateFormatter.dateFormat = @"EEE',' dd MMM yyyy HH':'mm':'ss z"; + + NSMutableDictionary * const headers = [[NSMutableDictionary alloc] initWithDictionary:@{ + @"Cache-Control" : [NSString stringWithFormat:@"public, max-age=%d", maxAge], + @"Date" : [dateFormatter stringFromDate:date] + }]; + + expect(RKHTTPCacheExpirationDateFromHeadersWithStatusCode(headers, 200)).to.equal([date dateByAddingTimeInterval:maxAge]); + + [headers setObject:[NSNumber numberWithInteger:(maxAge + 60)] forKey:@"Age"]; + expect(RKHTTPCacheExpirationDateFromHeadersWithStatusCode(headers, 200)).to.beLessThan(NSDate.date); + + [headers setObject:[NSNumber numberWithInteger:(maxAge - 60)] forKey:@"Age"]; + expect(RKHTTPCacheExpirationDateFromHeadersWithStatusCode(headers, 200)).to.beGreaterThan(NSDate.date); +} + @end From 7512827bbeb6e0dd377777bf9091b2bad43fc750 Mon Sep 17 00:00:00 2001 From: Rayman Rosevear Date: Wed, 28 Oct 2015 15:05:08 +0200 Subject: [PATCH 71/94] Don't return deleted NSManagedObject objects from the in memory cache --- Code/CoreData/RKEntityByAttributeCache.m | 7 ++++--- .../CoreData/RKEntityByAttributeCacheTest.m | 21 +++++++++++++++++++ 2 files changed, 25 insertions(+), 3 deletions(-) diff --git a/Code/CoreData/RKEntityByAttributeCache.m b/Code/CoreData/RKEntityByAttributeCache.m index 6ecac27dea..bf4c8600f7 100644 --- a/Code/CoreData/RKEntityByAttributeCache.m +++ b/Code/CoreData/RKEntityByAttributeCache.m @@ -211,16 +211,17 @@ - (NSManagedObject *)objectForObjectID:(NSManagedObjectID *)objectID inContext:( { /** NOTE: - + We use `existingObjectWithID:` as opposed to `objectWithID:` as `objectWithID:` can return us a fault - that will raise an exception when fired. `existingObjectWithID:error:` will return nil if the ID has been - deleted. `objectRegisteredForID:` is also an acceptable approach. + that will raise an exception when fired. `objectRegisteredForID:` is also an acceptable approach. */ __block NSError *error = nil; __block NSManagedObject *object; [context performBlockAndWait:^{ object = [context existingObjectWithID:objectID error:&error]; }]; + // Don't return the object if it has been deleted. + if ([object isDeleted]) object = nil; if (! object) { // Referential integrity errors often indicates that the temporary objectID does not exist in the specified context if (error && !([objectID isTemporaryID] && [error code] == NSManagedObjectReferentialIntegrityError)) { diff --git a/Tests/Logic/CoreData/RKEntityByAttributeCacheTest.m b/Tests/Logic/CoreData/RKEntityByAttributeCacheTest.m index 6dfbf6e16b..e6ace84c82 100644 --- a/Tests/Logic/CoreData/RKEntityByAttributeCacheTest.m +++ b/Tests/Logic/CoreData/RKEntityByAttributeCacheTest.m @@ -233,6 +233,27 @@ - (void)testRetrievalOfObjectsWithMoreThanOneCollectionAttributeValue assertThat(objects, hasCountOf(0)); } +- (void)testRetrievalOfDeletedObjectReturnsNil +{ + RKHuman *human = [NSEntityDescription insertNewObjectForEntityForName:@"Human" inManagedObjectContext:self.managedObjectStore.persistentStoreManagedObjectContext]; + human.railsID = @12345; + [self.managedObjectStore.persistentStoreManagedObjectContext save:nil]; + + __block BOOL done = NO; + [self.cache addObjects:[NSSet setWithObjects:human, nil] completion:^{ + done = YES; + }]; + expect(done).will.equal(YES); + + NSManagedObjectContext *childContext = [[NSManagedObjectContext alloc] initWithConcurrencyType:NSPrivateQueueConcurrencyType]; + childContext.parentContext = self.managedObjectContext; + + [childContext deleteObject:[childContext objectWithID:[human objectID]]]; + + NSManagedObject *object = [self.cache objectWithAttributeValues:@{ @"railsID": @"12345" } inContext:childContext]; + assertThat(object, is(nilValue())); +} + // Do this with 3 attributes, 2 that are arrays and 1 that is not // check // Test blowing up if you request objects without enough cache keys From 4d8ff80eb3503045b61c16e43e5c05db24b537fa Mon Sep 17 00:00:00 2001 From: Tim Bodeit Date: Tue, 11 Aug 2015 15:32:45 +0200 Subject: [PATCH 72/94] Add CocoaLumberjack subspec Include dependency on CocoaLumberjack Define RKLOG_USE_COCOALUMBERJACK macro --- RestKit.podspec | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/RestKit.podspec b/RestKit.podspec index a4d883bac4..977893ed3f 100644 --- a/RestKit.podspec +++ b/RestKit.podspec @@ -102,4 +102,9 @@ EOS ss.source_files = 'Code/RestKit.h', 'Code/Support.h', 'Code/Support', 'Vendor/LibComponentLogging/Core' ss.dependency 'TransitionKit', '~> 2.2' end + + s.subspec 'CocoaLumberjack' do |cl| + cl.dependency 'CocoaLumberjack' + cl.pod_target_xcconfig = { 'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) RKLOG_USE_COCOALUMBERJACK=1' } + end end From 9bee0e6cbbd3160fd61436215a2d895eaea18fd9 Mon Sep 17 00:00:00 2001 From: Tim Bodeit Date: Tue, 11 Aug 2015 15:34:53 +0200 Subject: [PATCH 73/94] Check RKLOG_USE_COCOALUMBERJACK macro before using CocoaLumberjack --- Code/Support/RKLog.m | 2 +- Code/Support/RKLumberjackLogger.h | 2 +- Code/Support/RKLumberjackLogger.m | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Code/Support/RKLog.m b/Code/Support/RKLog.m index 100798ed56..7930e4429c 100644 --- a/Code/Support/RKLog.m +++ b/Code/Support/RKLog.m @@ -27,7 +27,7 @@ @interface RKNSLogLogger : NSObject #import "LCLNSLogger_RK.h" #define RKLOG_CLASS LCLNSLogger_RK -#elif __has_include("DDLog.h") +#elif RKLOG_USE_COCOALUMBERJACK && __has_include("DDLog.h") #import "RKLumberjackLogger.h" #define RKLOG_CLASS RKLumberjackLogger diff --git a/Code/Support/RKLumberjackLogger.h b/Code/Support/RKLumberjackLogger.h index c77def651a..ffa5da90bf 100644 --- a/Code/Support/RKLumberjackLogger.h +++ b/Code/Support/RKLumberjackLogger.h @@ -8,7 +8,7 @@ #import -#if __has_include("DDLog.h") +#if RKLOG_USE_COCOALUMBERJACK && __has_include("DDLog.h") #import "RKLog.h" @interface RKLumberjackLogger : NSObject diff --git a/Code/Support/RKLumberjackLogger.m b/Code/Support/RKLumberjackLogger.m index cdf0d51a28..21750d8186 100644 --- a/Code/Support/RKLumberjackLogger.m +++ b/Code/Support/RKLumberjackLogger.m @@ -6,7 +6,7 @@ // // -#if __has_include("DDLog.h") +#if RKLOG_USE_COCOALUMBERJACK && __has_include("DDLog.h") #import "RKLumberjackLogger.h" #import "DDLog.h" From 90e0113969d88d52d375f22e88e9ec61e7f68091 Mon Sep 17 00:00:00 2001 From: Tim Bodeit Date: Tue, 11 Aug 2015 16:11:50 +0200 Subject: [PATCH 74/94] Move RKLumberjackLogger to different folder --- Code/{Support => CocoaLumberjack}/RKLumberjackLogger.h | 0 Code/{Support => CocoaLumberjack}/RKLumberjackLogger.m | 0 RestKit.podspec | 2 ++ 3 files changed, 2 insertions(+) rename Code/{Support => CocoaLumberjack}/RKLumberjackLogger.h (100%) rename Code/{Support => CocoaLumberjack}/RKLumberjackLogger.m (100%) diff --git a/Code/Support/RKLumberjackLogger.h b/Code/CocoaLumberjack/RKLumberjackLogger.h similarity index 100% rename from Code/Support/RKLumberjackLogger.h rename to Code/CocoaLumberjack/RKLumberjackLogger.h diff --git a/Code/Support/RKLumberjackLogger.m b/Code/CocoaLumberjack/RKLumberjackLogger.m similarity index 100% rename from Code/Support/RKLumberjackLogger.m rename to Code/CocoaLumberjack/RKLumberjackLogger.m diff --git a/RestKit.podspec b/RestKit.podspec index 977893ed3f..ed690df0da 100644 --- a/RestKit.podspec +++ b/RestKit.podspec @@ -104,7 +104,9 @@ EOS end s.subspec 'CocoaLumberjack' do |cl| + cl.source_files = 'Code/CocoaLumberjack/RKLumberjackLogger.*' cl.dependency 'CocoaLumberjack' + cl.dependency 'RestKit/Support' cl.pod_target_xcconfig = { 'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) RKLOG_USE_COCOALUMBERJACK=1' } end end From 4d43dc9455b9eb1890086d43a44d9ab04bd02c03 Mon Sep 17 00:00:00 2001 From: Tim Bodeit Date: Fri, 21 Aug 2015 23:27:40 +0200 Subject: [PATCH 75/94] Fix RestKit project --- RestKit.xcodeproj/project.pbxproj | 32 +++++++++++++++++++------------ 1 file changed, 20 insertions(+), 12 deletions(-) diff --git a/RestKit.xcodeproj/project.pbxproj b/RestKit.xcodeproj/project.pbxproj index 79b4449a5e..b67a7a41de 100644 --- a/RestKit.xcodeproj/project.pbxproj +++ b/RestKit.xcodeproj/project.pbxproj @@ -7,6 +7,10 @@ objects = { /* Begin PBXBuildFile section */ + 1689DAEF1B87CEA900254FB7 /* RKLumberjackLogger.h in Headers */ = {isa = PBXBuildFile; fileRef = 1689DAED1B87CEA900254FB7 /* RKLumberjackLogger.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 1689DAF01B87CEA900254FB7 /* RKLumberjackLogger.h in Headers */ = {isa = PBXBuildFile; fileRef = 1689DAED1B87CEA900254FB7 /* RKLumberjackLogger.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 1689DAF11B87CEA900254FB7 /* RKLumberjackLogger.m in Sources */ = {isa = PBXBuildFile; fileRef = 1689DAEE1B87CEA900254FB7 /* RKLumberjackLogger.m */; }; + 1689DAF21B87CEA900254FB7 /* RKLumberjackLogger.m in Sources */ = {isa = PBXBuildFile; fileRef = 1689DAEE1B87CEA900254FB7 /* RKLumberjackLogger.m */; }; 2502C8ED15F79CF70060FD75 /* CoreData.h in Headers */ = {isa = PBXBuildFile; fileRef = 2502C8E715F79CF70060FD75 /* CoreData.h */; settings = {ATTRIBUTES = (Public, ); }; }; 2502C8EE15F79CF70060FD75 /* CoreData.h in Headers */ = {isa = PBXBuildFile; fileRef = 2502C8E715F79CF70060FD75 /* CoreData.h */; settings = {ATTRIBUTES = (Public, ); }; }; 2502C8EF15F79CF70060FD75 /* Network.h in Headers */ = {isa = PBXBuildFile; fileRef = 2502C8E815F79CF70060FD75 /* Network.h */; settings = {ATTRIBUTES = (Public, ); }; }; @@ -538,10 +542,6 @@ C0F11CE6190883460054AEA0 /* RKPathMatcher.m in Sources */ = {isa = PBXBuildFile; fileRef = C0F11CE2190883380054AEA0 /* RKPathMatcher.m */; }; C0F11CE81908C7E60054AEA0 /* RKCoreData.h in Headers */ = {isa = PBXBuildFile; fileRef = C0F11CE71908C7E60054AEA0 /* RKCoreData.h */; settings = {ATTRIBUTES = (Public, ); }; }; C0F11CE91908C7E60054AEA0 /* RKCoreData.h in Headers */ = {isa = PBXBuildFile; fileRef = C0F11CE71908C7E60054AEA0 /* RKCoreData.h */; settings = {ATTRIBUTES = (Public, ); }; }; - DB1148441A0B26B100C8A00A /* RKLumberjackLogger.h in Headers */ = {isa = PBXBuildFile; fileRef = DB1148421A0B26B100C8A00A /* RKLumberjackLogger.h */; settings = {ATTRIBUTES = (Public, ); }; }; - DB1148451A0B26B100C8A00A /* RKLumberjackLogger.h in Headers */ = {isa = PBXBuildFile; fileRef = DB1148421A0B26B100C8A00A /* RKLumberjackLogger.h */; settings = {ATTRIBUTES = (Public, ); }; }; - DB1148461A0B26B100C8A00A /* RKLumberjackLogger.m in Sources */ = {isa = PBXBuildFile; fileRef = DB1148431A0B26B100C8A00A /* RKLumberjackLogger.m */; }; - DB1148471A0B26B100C8A00A /* RKLumberjackLogger.m in Sources */ = {isa = PBXBuildFile; fileRef = DB1148431A0B26B100C8A00A /* RKLumberjackLogger.m */; }; FFD7948D0AE44A4290977909 /* libPods-RestKit.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5EA1EF52129B3341280753E4 /* libPods-RestKit.a */; }; /* End PBXBuildFile section */ @@ -576,6 +576,8 @@ /* Begin PBXFileReference section */ 0B096CE4874E766ECE78D229 /* Pods-ios.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ios.debug.xcconfig"; path = "Pods/Target Support Files/Pods-ios/Pods-ios.debug.xcconfig"; sourceTree = ""; }; + 1689DAED1B87CEA900254FB7 /* RKLumberjackLogger.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKLumberjackLogger.h; sourceTree = ""; }; + 1689DAEE1B87CEA900254FB7 /* RKLumberjackLogger.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKLumberjackLogger.m; sourceTree = ""; }; 1ABDEC386A27292EF883B0BE /* Pods-RestKitFramework.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RestKitFramework.release.xcconfig"; path = "Pods/Target Support Files/Pods-RestKitFramework/Pods-RestKitFramework.release.xcconfig"; sourceTree = ""; }; 2501405215366000004E0466 /* RKObjectiveCppTest.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = RKObjectiveCppTest.mm; sourceTree = ""; }; 2502C8E715F79CF70060FD75 /* CoreData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CoreData.h; sourceTree = ""; }; @@ -895,8 +897,6 @@ C0F11CE2190883380054AEA0 /* RKPathMatcher.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKPathMatcher.m; sourceTree = ""; }; C0F11CE71908C7E60054AEA0 /* RKCoreData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKCoreData.h; sourceTree = ""; }; C5608EB544CBB19BBACC13BA /* Pods-RestKitFramework.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RestKitFramework.debug.xcconfig"; path = "Pods/Target Support Files/Pods-RestKitFramework/Pods-RestKitFramework.debug.xcconfig"; sourceTree = ""; }; - DB1148421A0B26B100C8A00A /* RKLumberjackLogger.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RKLumberjackLogger.h; sourceTree = ""; }; - DB1148431A0B26B100C8A00A /* RKLumberjackLogger.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RKLumberjackLogger.m; sourceTree = ""; }; DB867C56C81696C5E9366366 /* libPods-osx.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-osx.a"; sourceTree = BUILT_PRODUCTS_DIR; }; DC09A8FD6016D24B797977A1 /* libPods-ios.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-ios.a"; sourceTree = BUILT_PRODUCTS_DIR; }; F66056291744FF9000A87A45 /* and_cats.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = and_cats.json; sourceTree = ""; }; @@ -957,6 +957,15 @@ /* End PBXFrameworksBuildPhase section */ /* Begin PBXGroup section */ + 1689DAEC1B87CEA900254FB7 /* CocoaLumberjack */ = { + isa = PBXGroup; + children = ( + 1689DAED1B87CEA900254FB7 /* RKLumberjackLogger.h */, + 1689DAEE1B87CEA900254FB7 /* RKLumberjackLogger.m */, + ); + path = CocoaLumberjack; + sourceTree = ""; + }; 21C3ABBAD1E23EF5D671E158 /* Pods */ = { isa = PBXGroup; children = ( @@ -1066,6 +1075,7 @@ 2502C8EB15F79CF70060FD75 /* Support.h */, 25160DA2145650490060A5C5 /* Support */, 2502C8EC15F79CF70060FD75 /* Testing.h */, + 1689DAEC1B87CEA900254FB7 /* CocoaLumberjack */, 252EFB1F14D9A8D4004863C8 /* Testing */, 2502C8EA15F79CF70060FD75 /* Search.h */, 25104F0E15C30C7900829135 /* Search */, @@ -1171,8 +1181,6 @@ 25160DBF145650490060A5C5 /* RKDotNetDateFormatter.m */, 25160DC1145650490060A5C5 /* RKLog.h */, 25160DC2145650490060A5C5 /* RKLog.m */, - DB1148421A0B26B100C8A00A /* RKLumberjackLogger.h */, - DB1148431A0B26B100C8A00A /* RKLumberjackLogger.m */, 25160DC3145650490060A5C5 /* RKMIMETypes.h */, 25160DC4145650490060A5C5 /* RKMIMETypes.m */, 25160DC5145650490060A5C5 /* RKSerialization.h */, @@ -1636,7 +1644,6 @@ 25160E0B145650490060A5C5 /* RKErrorMessage.h in Headers */, 25160E0F145650490060A5C5 /* RKAttributeMapping.h in Headers */, 25160E16145650490060A5C5 /* RKMapperOperation.h in Headers */, - DB1148441A0B26B100C8A00A /* RKLumberjackLogger.h in Headers */, 25160E18145650490060A5C5 /* RKMapperOperation_Private.h in Headers */, 25160E1A145650490060A5C5 /* RKObjectMapping.h in Headers */, 25160E1C145650490060A5C5 /* RKMapping.h in Headers */, @@ -1654,6 +1661,7 @@ 25160E4E145650490060A5C5 /* RKSerialization.h in Headers */, 25160EE21456532C0060A5C5 /* lcl_RK.h in Headers */, 25160E2E145650490060A5C5 /* RestKit.h in Headers */, + 1689DAEF1B87CEA900254FB7 /* RKLumberjackLogger.h in Headers */, 25B408261491CDDC00F21111 /* RKPathUtilities.h in Headers */, 25B6E95514CF795D00B1E881 /* RKErrors.h in Headers */, 25B6E95C14CF7E3C00B1E881 /* RKObjectMappingMatcher.h in Headers */, @@ -1727,7 +1735,6 @@ 25160F4A145655C60060A5C5 /* RKAttributeMapping.h in Headers */, 25160F51145655C60060A5C5 /* RKMapperOperation.h in Headers */, 25160F53145655C60060A5C5 /* RKMapperOperation_Private.h in Headers */, - DB1148451A0B26B100C8A00A /* RKLumberjackLogger.h in Headers */, 25160F55145655C60060A5C5 /* RKObjectMapping.h in Headers */, 25160F57145655C60060A5C5 /* RKMapping.h in Headers */, 25160F58145655C60060A5C5 /* RKMappingOperation.h in Headers */, @@ -1747,6 +1754,7 @@ 25160F971456576C0060A5C5 /* RKSerialization.h in Headers */, 25160F25145655AF0060A5C5 /* RestKit.h in Headers */, 25B408271491CDDC00F21111 /* RKPathUtilities.h in Headers */, + 1689DAF01B87CEA900254FB7 /* RKLumberjackLogger.h in Headers */, 25B6E95614CF795D00B1E881 /* RKErrors.h in Headers */, 25B6E95D14CF7E3C00B1E881 /* RKObjectMappingMatcher.h in Headers */, 25FABED314E3796C00E609E7 /* RKTestNotificationObserver.h in Headers */, @@ -2221,7 +2229,6 @@ 25160DE2145650490060A5C5 /* RKManagedObjectStore.m in Sources */, 25160DE6145650490060A5C5 /* RKPropertyInspector+CoreData.m in Sources */, 25160E0A145650490060A5C5 /* RKDynamicMapping.m in Sources */, - DB1148461A0B26B100C8A00A /* RKLumberjackLogger.m in Sources */, 25160E0C145650490060A5C5 /* RKErrorMessage.m in Sources */, 25160E10145650490060A5C5 /* RKAttributeMapping.m in Sources */, 25160E17145650490060A5C5 /* RKMapperOperation.m in Sources */, @@ -2240,6 +2247,7 @@ 25CA7A8F14EC570200888FF8 /* RKMapping.m in Sources */, 25055B8614EEF32A00B9C4DD /* RKMappingTest.m in Sources */, 25055B8A14EEF32A00B9C4DD /* RKTestFactory.m in Sources */, + 1689DAF11B87CEA900254FB7 /* RKLumberjackLogger.m in Sources */, 25055B9114EEF40000B9C4DD /* RKPropertyMappingTestExpectation.m in Sources */, 25EC1A3B14F72B1300C3CF3F /* RKFetchRequestManagedObjectCache.m in Sources */, 25EC1A3F14F72B3100C3CF3F /* RKInMemoryManagedObjectCache.m in Sources */, @@ -2364,7 +2372,6 @@ 25160F45145655C60060A5C5 /* RKDynamicMapping.m in Sources */, 25160F47145655C60060A5C5 /* RKErrorMessage.m in Sources */, 25160F4B145655C60060A5C5 /* RKAttributeMapping.m in Sources */, - DB1148471A0B26B100C8A00A /* RKLumberjackLogger.m in Sources */, 25160F52145655C60060A5C5 /* RKMapperOperation.m in Sources */, 25160F56145655C60060A5C5 /* RKObjectMapping.m in Sources */, 25160F59145655C60060A5C5 /* RKMappingOperation.m in Sources */, @@ -2385,6 +2392,7 @@ 25CA7A9114EC5C2D00888FF8 /* RKTestFixture.m in Sources */, 25055B8714EEF32A00B9C4DD /* RKMappingTest.m in Sources */, 25055B8B14EEF32A00B9C4DD /* RKTestFactory.m in Sources */, + 1689DAF21B87CEA900254FB7 /* RKLumberjackLogger.m in Sources */, 25055B9214EEF40000B9C4DD /* RKPropertyMappingTestExpectation.m in Sources */, 25EC1A3C14F72B1400C3CF3F /* RKFetchRequestManagedObjectCache.m in Sources */, 25EC1A4014F72B3300C3CF3F /* RKInMemoryManagedObjectCache.m in Sources */, From 52551e2916879a8da9d618f3e5a76315d7ff4adf Mon Sep 17 00:00:00 2001 From: Tim Bodeit Date: Sat, 22 Aug 2015 00:12:13 +0200 Subject: [PATCH 76/94] Switch to CocoaLumberjack 2.0 API [#2263] --- Code/CocoaLumberjack/RKLumberjackLogger.h | 2 +- Code/CocoaLumberjack/RKLumberjackLogger.m | 60 +++++++++++------------ 2 files changed, 31 insertions(+), 31 deletions(-) diff --git a/Code/CocoaLumberjack/RKLumberjackLogger.h b/Code/CocoaLumberjack/RKLumberjackLogger.h index ffa5da90bf..41ab47c1cb 100644 --- a/Code/CocoaLumberjack/RKLumberjackLogger.h +++ b/Code/CocoaLumberjack/RKLumberjackLogger.h @@ -8,7 +8,7 @@ #import -#if RKLOG_USE_COCOALUMBERJACK && __has_include("DDLog.h") +#if RKLOG_USE_COCOALUMBERJACK && __has_include() #import "RKLog.h" @interface RKLumberjackLogger : NSObject diff --git a/Code/CocoaLumberjack/RKLumberjackLogger.m b/Code/CocoaLumberjack/RKLumberjackLogger.m index 21750d8186..a48272bbd4 100644 --- a/Code/CocoaLumberjack/RKLumberjackLogger.m +++ b/Code/CocoaLumberjack/RKLumberjackLogger.m @@ -6,51 +6,51 @@ // // -#if RKLOG_USE_COCOALUMBERJACK && __has_include("DDLog.h") +#if RKLOG_USE_COCOALUMBERJACK && __has_include() #import "RKLumberjackLogger.h" -#import "DDLog.h" +#import @implementation RKLumberjackLogger -+ (int)ddLogLevelFromRKLogLevel:(_RKlcl_level_t)rkLevel ++ (DDLogLevel)ddLogLevelFromRKLogLevel:(_RKlcl_level_t)rkLevel { switch (rkLevel) { - case RKLogLevelOff: return LOG_LEVEL_OFF; - case RKLogLevelCritical: return LOG_LEVEL_ERROR; - case RKLogLevelError: return LOG_LEVEL_ERROR; - case RKLogLevelWarning: return LOG_LEVEL_WARN; - case RKLogLevelInfo: return LOG_LEVEL_INFO; - case RKLogLevelDebug: return LOG_LEVEL_DEBUG; - case RKLogLevelTrace: return LOG_LEVEL_VERBOSE; + case RKLogLevelOff: return DDLogLevelOff; + case RKLogLevelCritical: return DDLogLevelError; + case RKLogLevelError: return DDLogLevelError; + case RKLogLevelWarning: return DDLogLevelWarning; + case RKLogLevelInfo: return DDLogLevelInfo; + case RKLogLevelDebug: return DDLogLevelDebug; + case RKLogLevelTrace: return DDLogLevelVerbose; } - return LOG_LEVEL_DEBUG; + return DDLogLevelDebug; } -+ (int)ddLogFlagFromRKLogLevel:(_RKlcl_level_t)rkLevel ++ (DDLogFlag)ddLogFlagFromRKLogLevel:(_RKlcl_level_t)rkLevel { switch (rkLevel) { case RKLogLevelOff: return 0; - case RKLogLevelCritical: return LOG_FLAG_ERROR; - case RKLogLevelError: return LOG_FLAG_ERROR; - case RKLogLevelWarning: return LOG_FLAG_WARN; - case RKLogLevelInfo: return LOG_FLAG_INFO; - case RKLogLevelDebug: return LOG_FLAG_DEBUG; - case RKLogLevelTrace: return LOG_FLAG_VERBOSE; + case RKLogLevelCritical: return DDLogFlagError; + case RKLogLevelError: return DDLogFlagError; + case RKLogLevelWarning: return DDLogFlagWarning; + case RKLogLevelInfo: return DDLogFlagInfo; + case RKLogLevelDebug: return DDLogFlagDebug; + case RKLogLevelTrace: return DDLogFlagVerbose; } - return LOG_FLAG_DEBUG; + return DDLogFlagDebug; } -+ (_RKlcl_level_t)rkLogLevelFromDDLogLevel:(int)ddLogLevel ++ (_RKlcl_level_t)rkLogLevelFromDDLogLevel:(DDLogLevel)ddLogLevel { - if (ddLogLevel & LOG_FLAG_VERBOSE) return RKLogLevelTrace; - if (ddLogLevel & LOG_FLAG_DEBUG) return RKLogLevelDebug; - if (ddLogLevel & LOG_FLAG_INFO) return RKLogLevelInfo; - if (ddLogLevel & LOG_FLAG_WARN) return RKLogLevelWarning; - if (ddLogLevel & LOG_FLAG_ERROR) return RKLogLevelError; + if (ddLogLevel & DDLogFlagVerbose) return RKLogLevelTrace; + if (ddLogLevel & DDLogFlagDebug) return RKLogLevelDebug; + if (ddLogLevel & DDLogFlagInfo) return RKLogLevelInfo; + if (ddLogLevel & DDLogFlagWarning) return RKLogLevelWarning; + if (ddLogLevel & DDLogFlagError) return RKLogLevelError; return RKLogLevelOff; } @@ -68,9 +68,9 @@ + (void)logWithComponent:(_RKlcl_component_t)component va_list args; va_start(args, format); - int flag = [self ddLogFlagFromRKLogLevel:level]; - int componentLevel = [self ddLogLevelFromRKLogLevel:_RKlcl_component_level[component]]; - BOOL async = LOG_ASYNC_ENABLED && ((flag & LOG_FLAG_ERROR) == 0); + DDLogFlag flag = [self ddLogFlagFromRKLogLevel:level]; + DDLogLevel componentLevel = [self ddLogLevelFromRKLogLevel:_RKlcl_component_level[component]]; + BOOL async = LOG_ASYNC_ENABLED && ((flag & DDLogFlagError) == 0); [DDLog log:async level:componentLevel @@ -93,11 +93,11 @@ + (void)logWithComponent:(_RKlcl_component_t)component @interface RKLumberjackLog##_identifier : NSObject \ @end \ @implementation RKLumberjackLog##_identifier \ - + (int)ddLogLevel { \ + + (DDLogLevel)ddLogLevel { \ _RKlcl_level_t level = _RKlcl_component_level[RKlcl_c##_identifier]; \ return [RKLumberjackLogger ddLogLevelFromRKLogLevel:level]; \ } \ - + (void)ddSetLogLevel:(int)logLevel { \ + + (void)ddSetLogLevel:(DDLogLevel)logLevel { \ RKLogConfigureByName(_name, [RKLumberjackLogger rkLogLevelFromDDLogLevel:logLevel]); \ } \ @end From 0d41f8b5191c4553c9c30151f7769f89572d010a Mon Sep 17 00:00:00 2001 From: Tim Bodeit Date: Tue, 3 Nov 2015 05:31:45 +0100 Subject: [PATCH 77/94] Replace RKLOG_USE_COCOALUMBERJACK macro Use __has_include("RKLumberjackLogger.h") instead to check whether CocoaLumberjack subspec has been included. --- Code/CocoaLumberjack/RKLumberjackLogger.h | 2 +- Code/CocoaLumberjack/RKLumberjackLogger.m | 2 +- Code/Support/RKLog.m | 2 +- Podfile.lock | 12 +++++++++++- RestKit.podspec | 1 - 5 files changed, 14 insertions(+), 5 deletions(-) diff --git a/Code/CocoaLumberjack/RKLumberjackLogger.h b/Code/CocoaLumberjack/RKLumberjackLogger.h index 41ab47c1cb..be43dc7110 100644 --- a/Code/CocoaLumberjack/RKLumberjackLogger.h +++ b/Code/CocoaLumberjack/RKLumberjackLogger.h @@ -8,7 +8,7 @@ #import -#if RKLOG_USE_COCOALUMBERJACK && __has_include() +#if __has_include() #import "RKLog.h" @interface RKLumberjackLogger : NSObject diff --git a/Code/CocoaLumberjack/RKLumberjackLogger.m b/Code/CocoaLumberjack/RKLumberjackLogger.m index a48272bbd4..e314e90c00 100644 --- a/Code/CocoaLumberjack/RKLumberjackLogger.m +++ b/Code/CocoaLumberjack/RKLumberjackLogger.m @@ -6,7 +6,7 @@ // // -#if RKLOG_USE_COCOALUMBERJACK && __has_include() +#if __has_include() #import "RKLumberjackLogger.h" #import diff --git a/Code/Support/RKLog.m b/Code/Support/RKLog.m index 7930e4429c..c89639a32e 100644 --- a/Code/Support/RKLog.m +++ b/Code/Support/RKLog.m @@ -27,7 +27,7 @@ @interface RKNSLogLogger : NSObject #import "LCLNSLogger_RK.h" #define RKLOG_CLASS LCLNSLogger_RK -#elif RKLOG_USE_COCOALUMBERJACK && __has_include("DDLog.h") +#elif __has_include("RKLumberjackLogger.h") && __has_include() #import "RKLumberjackLogger.h" #define RKLOG_CLASS RKLumberjackLogger diff --git a/Podfile.lock b/Podfile.lock index 2694653fe9..fdbaa5dbed 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -1,5 +1,13 @@ PODS: - AFNetworking (1.3.4) + - CocoaLumberjack (2.2.0): + - CocoaLumberjack/Default (= 2.2.0) + - CocoaLumberjack/Extensions (= 2.2.0) + - CocoaLumberjack/Core (2.2.0) + - CocoaLumberjack/Default (2.2.0): + - CocoaLumberjack/Core + - CocoaLumberjack/Extensions (2.2.0): + - CocoaLumberjack/Default - Expecta (0.3.1) - ISO8601DateFormatterValueTransformer (0.6.1): - RKValueTransformers (~> 1.1.0) @@ -37,6 +45,7 @@ PODS: DEPENDENCIES: - AFNetworking (~> 1.3.0) + - CocoaLumberjack - Expecta (= 0.3.1) - ISO8601DateFormatterValueTransformer (~> 0.6.1) - OCHamcrest (= 3.0.1) @@ -56,11 +65,12 @@ EXTERNAL SOURCES: SPEC CHECKSUMS: AFNetworking: cf8e418e16f0c9c7e5c3150d019a3c679d015018 + CocoaLumberjack: 17fe8581f84914d5d7e6360f7c70022b173c3ae0 Expecta: a354d4633409dd9fe8c4f5ff5130426adbe31628 ISO8601DateFormatterValueTransformer: 52da467d6ec899d6aedda8e48280ac92e8ee97e6 OCHamcrest: e19857683e4eefab64b878668eac04c2f4567118 OCMock: a6a7dc0e3997fb9f35d99f72528698ebf60d64f2 - RestKit: da3154995dd4d8f5998dc3b6caba0ff85793841c + RestKit: 6a1ceadec4fb2bfdffbcbe60b706d37444679e5b RKCLLocationValueTransformer: 2cf0ea0fb7cd4bc70c56834fb92abc717c66f982 RKValueTransformers: 66ac5e4f077fdbe3496e792d89eeff4c3eb67701 SOCKit: c7376ac262bea9115b8f749358f762522a47d392 diff --git a/RestKit.podspec b/RestKit.podspec index ed690df0da..a07930d31c 100644 --- a/RestKit.podspec +++ b/RestKit.podspec @@ -107,6 +107,5 @@ EOS cl.source_files = 'Code/CocoaLumberjack/RKLumberjackLogger.*' cl.dependency 'CocoaLumberjack' cl.dependency 'RestKit/Support' - cl.pod_target_xcconfig = { 'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) RKLOG_USE_COCOALUMBERJACK=1' } end end From 2e014006c30edb6e3b77aed6c8e9310fd8705be8 Mon Sep 17 00:00:00 2001 From: "Samuel E. Giddins" Date: Thu, 24 Sep 2015 17:25:44 -0500 Subject: [PATCH 78/94] Use framework-style import statements --- Code/CocoaLumberjack/RKLumberjackLogger.h | 2 +- Code/CocoaLumberjack/RKLumberjackLogger.m | 4 +-- Code/CoreData.h | 22 ++++++------ Code/CoreData/NSManagedObject+RKAdditions.m | 8 ++--- .../NSManagedObjectContext+RKAdditions.m | 4 +-- Code/CoreData/RKConnectionDescription.m | 2 +- Code/CoreData/RKCoreData.h | 2 +- Code/CoreData/RKEntityByAttributeCache.m | 12 +++---- Code/CoreData/RKEntityCache.m | 4 +-- Code/CoreData/RKEntityMapping.h | 6 ++-- Code/CoreData/RKEntityMapping.m | 14 ++++---- .../RKFetchRequestManagedObjectCache.h | 2 +- .../RKFetchRequestManagedObjectCache.m | 10 +++--- Code/CoreData/RKInMemoryManagedObjectCache.h | 2 +- Code/CoreData/RKInMemoryManagedObjectCache.m | 8 ++--- Code/CoreData/RKManagedObjectImporter.m | 16 ++++----- ...KManagedObjectMappingOperationDataSource.h | 2 +- ...KManagedObjectMappingOperationDataSource.m | 28 +++++++-------- Code/CoreData/RKManagedObjectStore.h | 4 +-- Code/CoreData/RKManagedObjectStore.m | 16 ++++----- Code/CoreData/RKPropertyInspector+CoreData.h | 2 +- Code/CoreData/RKPropertyInspector+CoreData.m | 8 ++--- .../RKRelationshipConnectionOperation.m | 16 ++++----- Code/Network.h | 22 ++++++------ Code/Network/RKHTTPRequestOperation.m | 8 ++--- .../Network/RKManagedObjectRequestOperation.h | 4 +-- .../Network/RKManagedObjectRequestOperation.m | 24 ++++++------- Code/Network/RKObjectManager.h | 6 ++-- Code/Network/RKObjectManager.m | 34 +++++++++---------- Code/Network/RKObjectParameterization.h | 2 +- Code/Network/RKObjectParameterization.m | 22 ++++++------ Code/Network/RKObjectRequestOperation.h | 6 ++-- Code/Network/RKObjectRequestOperation.m | 18 +++++----- Code/Network/RKPaginator.h | 8 ++--- Code/Network/RKPaginator.m | 14 ++++---- Code/Network/RKPathMatcher.m | 8 ++--- Code/Network/RKRequestDescriptor.h | 2 +- Code/Network/RKRequestDescriptor.m | 6 ++-- Code/Network/RKResponseDescriptor.h | 2 +- Code/Network/RKResponseDescriptor.m | 8 ++--- Code/Network/RKResponseMapperOperation.h | 6 ++-- Code/Network/RKResponseMapperOperation.m | 20 +++++------ Code/Network/RKRoute.h | 2 +- Code/Network/RKRoute.m | 2 +- Code/Network/RKRouteSet.h | 2 +- Code/Network/RKRouteSet.m | 4 +-- Code/Network/RKRouter.h | 2 +- Code/Network/RKRouter.m | 8 ++--- Code/ObjectMapping.h | 14 ++++---- Code/ObjectMapping/RKAttributeMapping.h | 2 +- Code/ObjectMapping/RKAttributeMapping.m | 2 +- Code/ObjectMapping/RKDynamicMapping.h | 4 +-- Code/ObjectMapping/RKDynamicMapping.m | 6 ++-- Code/ObjectMapping/RKErrorMessage.m | 2 +- Code/ObjectMapping/RKHTTPUtilities.m | 2 +- Code/ObjectMapping/RKMapperOperation.h | 10 +++--- Code/ObjectMapping/RKMapperOperation.m | 16 ++++----- Code/ObjectMapping/RKMapping.m | 2 +- Code/ObjectMapping/RKMappingErrors.h | 2 +- Code/ObjectMapping/RKMappingOperation.h | 4 +-- Code/ObjectMapping/RKMappingOperation.m | 26 +++++++------- Code/ObjectMapping/RKMappingResult.m | 2 +- Code/ObjectMapping/RKObjectMapping.h | 4 +-- Code/ObjectMapping/RKObjectMapping.m | 16 ++++----- Code/ObjectMapping/RKObjectMappingMatcher.h | 2 +- Code/ObjectMapping/RKObjectMappingMatcher.m | 4 +-- .../RKObjectMappingOperationDataSource.h | 2 +- .../RKObjectMappingOperationDataSource.m | 6 ++-- Code/ObjectMapping/RKObjectUtilities.m | 2 +- Code/ObjectMapping/RKPropertyInspector.m | 6 ++-- Code/ObjectMapping/RKPropertyMapping.m | 4 +-- Code/ObjectMapping/RKRelationshipMapping.h | 2 +- Code/ObjectMapping/RKRelationshipMapping.m | 4 +-- Code/RestKit.h | 8 ++--- Code/Search.h | 6 ++-- .../RKManagedObjectStore+RKSearchAdditions.h | 4 +-- .../RKManagedObjectStore+RKSearchAdditions.m | 4 +-- Code/Search/RKSearchIndexer.m | 14 ++++---- Code/Search/RKSearchPredicate.m | 4 +-- Code/Search/RKSearchWord.m | 4 +-- Code/Search/RKSearchWordEntity.m | 2 +- Code/Support.h | 20 +++++------ Code/Support/RKDictionaryUtilities.m | 2 +- Code/Support/RKDotNetDateFormatter.m | 4 +-- Code/Support/RKErrors.m | 2 +- Code/Support/RKLog.m | 6 ++-- Code/Support/RKMIMETypeSerialization.h | 4 +-- Code/Support/RKMIMETypeSerialization.m | 12 +++---- Code/Support/RKMIMETypes.m | 2 +- Code/Support/RKNSJSONSerialization.h | 2 +- Code/Support/RKNSJSONSerialization.m | 2 +- Code/Support/RKOperationStateMachine.m | 4 +-- Code/Support/RKPathUtilities.m | 4 +-- Code/Support/RKStringTokenizer.m | 2 +- Code/Support/RKURLEncodedSerialization.h | 2 +- Code/Support/RKURLEncodedSerialization.m | 2 +- Code/Testing.h | 12 +++---- Code/Testing/RKBenchmark.m | 2 +- Code/Testing/RKConnectionTestExpectation.m | 4 +-- Code/Testing/RKMappingTest.h | 4 +-- Code/Testing/RKMappingTest.m | 22 ++++++------ .../RKPropertyMappingTestExpectation.m | 4 +-- Code/Testing/RKTestFactory.m | 14 ++++---- Code/Testing/RKTestFixture.m | 8 ++--- Code/Testing/RKTestHelpers.h | 2 +- Code/Testing/RKTestHelpers.m | 14 ++++---- Code/Testing/RKTestNotificationObserver.m | 2 +- 107 files changed, 392 insertions(+), 392 deletions(-) diff --git a/Code/CocoaLumberjack/RKLumberjackLogger.h b/Code/CocoaLumberjack/RKLumberjackLogger.h index be43dc7110..935a778bae 100644 --- a/Code/CocoaLumberjack/RKLumberjackLogger.h +++ b/Code/CocoaLumberjack/RKLumberjackLogger.h @@ -9,7 +9,7 @@ #import #if __has_include() -#import "RKLog.h" +#import @interface RKLumberjackLogger : NSObject @end diff --git a/Code/CocoaLumberjack/RKLumberjackLogger.m b/Code/CocoaLumberjack/RKLumberjackLogger.m index e314e90c00..e0e3f13dfc 100644 --- a/Code/CocoaLumberjack/RKLumberjackLogger.m +++ b/Code/CocoaLumberjack/RKLumberjackLogger.m @@ -7,7 +7,7 @@ // #if __has_include() -#import "RKLumberjackLogger.h" +#import #import @implementation RKLumberjackLogger @@ -86,7 +86,7 @@ + (void)logWithComponent:(_RKlcl_component_t)component /* Create a DDRegisteredDynamicLogging class for each RestKit component */ -#import "lcl_config_components_RK.h" +#import #undef _RKlcl_component #define _RKlcl_component(_identifier, _header, _name) \ diff --git a/Code/CoreData.h b/Code/CoreData.h index ff8972d4a6..ed12a379f4 100644 --- a/Code/CoreData.h +++ b/Code/CoreData.h @@ -19,15 +19,15 @@ // #import -#import "ObjectMapping.h" -#import "RKManagedObjectStore.h" -#import "RKManagedObjectImporter.h" -#import "RKManagedObjectMappingOperationDataSource.h" -#import "RKEntityMapping.h" -#import "RKManagedObjectCaching.h" -#import "RKInMemoryManagedObjectCache.h" -#import "RKFetchRequestManagedObjectCache.h" +#import +#import +#import +#import +#import +#import +#import +#import -#import "RKPropertyInspector+CoreData.h" -#import "NSManagedObjectContext+RKAdditions.h" -#import "NSManagedObject+RKAdditions.h" +#import +#import +#import diff --git a/Code/CoreData/NSManagedObject+RKAdditions.m b/Code/CoreData/NSManagedObject+RKAdditions.m index 196ff18979..178ccabdf0 100644 --- a/Code/CoreData/NSManagedObject+RKAdditions.m +++ b/Code/CoreData/NSManagedObject+RKAdditions.m @@ -6,10 +6,10 @@ // Copyright (c) 2009-2012 RestKit. All rights reserved. // -#import "NSManagedObject+RKAdditions.h" -#import "NSManagedObjectContext+RKAdditions.h" -#import "RKLog.h" -#import "RKManagedObjectStore.h" +#import +#import +#import +#import @implementation NSManagedObject (RKAdditions) diff --git a/Code/CoreData/NSManagedObjectContext+RKAdditions.m b/Code/CoreData/NSManagedObjectContext+RKAdditions.m index 8f22e10c19..a0ec7f5ad0 100644 --- a/Code/CoreData/NSManagedObjectContext+RKAdditions.m +++ b/Code/CoreData/NSManagedObjectContext+RKAdditions.m @@ -19,8 +19,8 @@ // #import -#import "NSManagedObjectContext+RKAdditions.h" -#import "RKLog.h" +#import +#import @implementation NSManagedObjectContext (RKAdditions) diff --git a/Code/CoreData/RKConnectionDescription.m b/Code/CoreData/RKConnectionDescription.m index ee47003508..d868f3e7d1 100644 --- a/Code/CoreData/RKConnectionDescription.m +++ b/Code/CoreData/RKConnectionDescription.m @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKConnectionDescription.h" +#import static NSSet *RKSetWithInvalidAttributesForEntity(NSArray *attributes, NSEntityDescription *entity) { diff --git a/Code/CoreData/RKCoreData.h b/Code/CoreData/RKCoreData.h index 01c826eb75..5d700c8d94 100644 --- a/Code/CoreData/RKCoreData.h +++ b/Code/CoreData/RKCoreData.h @@ -21,6 +21,6 @@ #ifndef RestKit_RKCoreData_h #define RestKit_RKCoreData_h -#import "CoreData.h" +#import #endif diff --git a/Code/CoreData/RKEntityByAttributeCache.m b/Code/CoreData/RKEntityByAttributeCache.m index bf4c8600f7..54ce2626b3 100644 --- a/Code/CoreData/RKEntityByAttributeCache.m +++ b/Code/CoreData/RKEntityByAttributeCache.m @@ -22,12 +22,12 @@ #import #endif -#import "RKEntityByAttributeCache.h" -#import "RKLog.h" -#import "RKPropertyInspector.h" -#import "RKPropertyInspector+CoreData.h" -#import "NSManagedObject+RKAdditions.h" -#import "RKObjectUtilities.h" +#import +#import +#import +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/CoreData/RKEntityCache.m b/Code/CoreData/RKEntityCache.m index 90241db133..d5f1279d65 100644 --- a/Code/CoreData/RKEntityCache.m +++ b/Code/CoreData/RKEntityCache.m @@ -18,8 +18,8 @@ // limitations under the License. // -#import "RKEntityCache.h" -#import "RKEntityByAttributeCache.h" +#import +#import @interface RKEntityCache () @property (nonatomic, strong) NSMutableSet *attributeCaches; diff --git a/Code/CoreData/RKEntityMapping.h b/Code/CoreData/RKEntityMapping.h index 8cbfb52e82..6fb4db6d83 100644 --- a/Code/CoreData/RKEntityMapping.h +++ b/Code/CoreData/RKEntityMapping.h @@ -19,9 +19,9 @@ // #import -#import "RKObjectMapping.h" -#import "RKConnectionDescription.h" -#import "RKMacros.h" +#import +#import +#import @class RKManagedObjectStore; diff --git a/Code/CoreData/RKEntityMapping.m b/Code/CoreData/RKEntityMapping.m index 9a90f38878..0bcccb9716 100644 --- a/Code/CoreData/RKEntityMapping.m +++ b/Code/CoreData/RKEntityMapping.m @@ -18,13 +18,13 @@ // limitations under the License. // -#import "RKEntityMapping.h" -#import "RKManagedObjectStore.h" -#import "RKObjectMappingMatcher.h" -#import "RKPropertyInspector+CoreData.h" -#import "RKLog.h" -#import "RKRelationshipMapping.h" -#import "RKObjectUtilities.h" +#import +#import +#import +#import +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/CoreData/RKFetchRequestManagedObjectCache.h b/Code/CoreData/RKFetchRequestManagedObjectCache.h index da50ebee12..69e1832a39 100644 --- a/Code/CoreData/RKFetchRequestManagedObjectCache.h +++ b/Code/CoreData/RKFetchRequestManagedObjectCache.h @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKManagedObjectCaching.h" +#import /** Provides a simple managed object cache strategy in which every request for an object diff --git a/Code/CoreData/RKFetchRequestManagedObjectCache.m b/Code/CoreData/RKFetchRequestManagedObjectCache.m index 3a1d5b61db..5e370824ee 100644 --- a/Code/CoreData/RKFetchRequestManagedObjectCache.m +++ b/Code/CoreData/RKFetchRequestManagedObjectCache.m @@ -18,11 +18,11 @@ // limitations under the License. // -#import "RKFetchRequestManagedObjectCache.h" -#import "RKLog.h" -#import "RKPropertyInspector.h" -#import "RKPropertyInspector+CoreData.h" -#import "RKObjectUtilities.h" +#import +#import +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/CoreData/RKInMemoryManagedObjectCache.h b/Code/CoreData/RKInMemoryManagedObjectCache.h index 09916908a1..70781e21f0 100644 --- a/Code/CoreData/RKInMemoryManagedObjectCache.h +++ b/Code/CoreData/RKInMemoryManagedObjectCache.h @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKManagedObjectCaching.h" +#import /** Provides a fast managed object cache where-in object instances are retained in memory to avoid hitting the Core Data persistent store. Performance is greatly increased over fetch request based strategy at the expense of memory consumption. diff --git a/Code/CoreData/RKInMemoryManagedObjectCache.m b/Code/CoreData/RKInMemoryManagedObjectCache.m index e41857b0af..1655c432ee 100644 --- a/Code/CoreData/RKInMemoryManagedObjectCache.m +++ b/Code/CoreData/RKInMemoryManagedObjectCache.m @@ -18,10 +18,10 @@ // limitations under the License. // -#import "RKInMemoryManagedObjectCache.h" -#import "RKEntityCache.h" -#import "RKLog.h" -#import "RKEntityByAttributeCache.h" +#import +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/CoreData/RKManagedObjectImporter.m b/Code/CoreData/RKManagedObjectImporter.m index 65213b7b51..c9c1cb88d2 100644 --- a/Code/CoreData/RKManagedObjectImporter.m +++ b/Code/CoreData/RKManagedObjectImporter.m @@ -22,14 +22,14 @@ #import #endif -#import "RKManagedObjectImporter.h" -#import "RKMapperOperation.h" -#import "RKManagedObjectMappingOperationDataSource.h" -#import "RKInMemoryManagedObjectCache.h" -#import "RKFetchRequestManagedObjectCache.h" -#import "RKMIMETypeSerialization.h" -#import "RKPathUtilities.h" -#import "RKLog.h" +#import +#import +#import +#import +#import +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/CoreData/RKManagedObjectMappingOperationDataSource.h b/Code/CoreData/RKManagedObjectMappingOperationDataSource.h index 9f8c19d9fa..4bad46ba8d 100644 --- a/Code/CoreData/RKManagedObjectMappingOperationDataSource.h +++ b/Code/CoreData/RKManagedObjectMappingOperationDataSource.h @@ -19,7 +19,7 @@ // #import -#import "RKMappingOperationDataSource.h" +#import @protocol RKManagedObjectCaching; diff --git a/Code/CoreData/RKManagedObjectMappingOperationDataSource.m b/Code/CoreData/RKManagedObjectMappingOperationDataSource.m index d2324f586e..d4b2699167 100644 --- a/Code/CoreData/RKManagedObjectMappingOperationDataSource.m +++ b/Code/CoreData/RKManagedObjectMappingOperationDataSource.m @@ -19,20 +19,20 @@ // #import -#import "RKManagedObjectMappingOperationDataSource.h" -#import "RKObjectMapping.h" -#import "RKEntityMapping.h" -#import "RKLog.h" -#import "RKManagedObjectStore.h" -#import "RKMappingOperation.h" -#import "RKObjectMappingMatcher.h" -#import "RKManagedObjectCaching.h" -#import "RKRelationshipConnectionOperation.h" -#import "RKMappingErrors.h" -#import "RKValueTransformers.h" -#import "RKRelationshipMapping.h" -#import "RKObjectUtilities.h" -#import "NSManagedObject+RKAdditions.h" +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import extern NSString * const RKObjectMappingNestingAttributeKeyName; diff --git a/Code/CoreData/RKManagedObjectStore.h b/Code/CoreData/RKManagedObjectStore.h index d11ecf3a18..83dafd63a1 100644 --- a/Code/CoreData/RKManagedObjectStore.h +++ b/Code/CoreData/RKManagedObjectStore.h @@ -19,8 +19,8 @@ // #import -#import "RKEntityMapping.h" -#import "RKManagedObjectCaching.h" +#import +#import @class RKManagedObjectStore; diff --git a/Code/CoreData/RKManagedObjectStore.m b/Code/CoreData/RKManagedObjectStore.m index 862acd106d..a5464714c6 100644 --- a/Code/CoreData/RKManagedObjectStore.m +++ b/Code/CoreData/RKManagedObjectStore.m @@ -19,14 +19,14 @@ // #import -#import "RKManagedObjectStore.h" -#import "RKLog.h" -#import "RKPropertyInspector.h" -#import "RKPropertyInspector+CoreData.h" -#import "RKPathUtilities.h" -#import "RKInMemoryManagedObjectCache.h" -#import "RKFetchRequestManagedObjectCache.h" -#import "NSManagedObjectContext+RKAdditions.h" +#import +#import +#import +#import +#import +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/CoreData/RKPropertyInspector+CoreData.h b/Code/CoreData/RKPropertyInspector+CoreData.h index 2afbc8d636..d4e1f50665 100644 --- a/Code/CoreData/RKPropertyInspector+CoreData.h +++ b/Code/CoreData/RKPropertyInspector+CoreData.h @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKPropertyInspector.h" +#import /** The `CoreData` category augments the `RKPropertyInspector` class with support for introspecting the property types for `NSManagedObject` and `NSEntityDescription` objects. diff --git a/Code/CoreData/RKPropertyInspector+CoreData.m b/Code/CoreData/RKPropertyInspector+CoreData.m index 3716deaf15..a37c1c5cb3 100644 --- a/Code/CoreData/RKPropertyInspector+CoreData.m +++ b/Code/CoreData/RKPropertyInspector+CoreData.m @@ -20,10 +20,10 @@ #import #import -#import "RKPropertyInspector+CoreData.h" -#import "RKLog.h" -#import "RKObjectUtilities.h" -#import "RKMacros.h" +#import +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/CoreData/RKRelationshipConnectionOperation.m b/Code/CoreData/RKRelationshipConnectionOperation.m index 5cba533edd..a7a3b7c39c 100644 --- a/Code/CoreData/RKRelationshipConnectionOperation.m +++ b/Code/CoreData/RKRelationshipConnectionOperation.m @@ -19,14 +19,14 @@ // #import -#import "RKRelationshipConnectionOperation.h" -#import "RKConnectionDescription.h" -#import "RKEntityMapping.h" -#import "RKLog.h" -#import "RKManagedObjectCaching.h" -#import "RKObjectMappingMatcher.h" -#import "RKErrors.h" -#import "RKObjectUtilities.h" +#import +#import +#import +#import +#import +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/Network.h b/Code/Network.h index 53d34a53cf..c2d2afc7b7 100644 --- a/Code/Network.h +++ b/Code/Network.h @@ -18,17 +18,17 @@ // limitations under the License. // -#import "RKRoute.h" -#import "RKRouteSet.h" -#import "RKRouter.h" -#import "RKRequestDescriptor.h" -#import "RKResponseDescriptor.h" -#import "RKObjectManager.h" -#import "RKHTTPUtilities.h" -#import "RKObjectRequestOperation.h" -#import "RKObjectParameterization.h" -#import "RKPathMatcher.h" +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import #ifdef _COREDATADEFINES_H -#import "RKManagedObjectRequestOperation.h" +#import #endif diff --git a/Code/Network/RKHTTPRequestOperation.m b/Code/Network/RKHTTPRequestOperation.m index 8b6f6aff2b..60f20337f1 100644 --- a/Code/Network/RKHTTPRequestOperation.m +++ b/Code/Network/RKHTTPRequestOperation.m @@ -18,11 +18,11 @@ // limitations under the License. // -#import "RKHTTPRequestOperation.h" -#import "RKLog.h" +#import +#import #import "lcl_RK.h" -#import "RKHTTPUtilities.h" -#import "RKMIMETypes.h" +#import +#import extern NSString * const RKErrorDomain; diff --git a/Code/Network/RKManagedObjectRequestOperation.h b/Code/Network/RKManagedObjectRequestOperation.h index c677e98a9b..7f8d05e960 100644 --- a/Code/Network/RKManagedObjectRequestOperation.h +++ b/Code/Network/RKManagedObjectRequestOperation.h @@ -21,8 +21,8 @@ #ifdef _COREDATADEFINES_H #if __has_include("RKManagedObjectCaching.h") -#import "RKObjectRequestOperation.h" -#import "RKManagedObjectCaching.h" +#import +#import /** `RKManagedObjectRequestOperation` is a subclass of `RKObjectRequestOperation` that implements object mapping on the response body of an `NSHTTPResponse` loaded via an `RKHTTPRequestOperation` in which the mapping targets `NSManagedObject` objects managed by Core Data. diff --git a/Code/Network/RKManagedObjectRequestOperation.m b/Code/Network/RKManagedObjectRequestOperation.m index 8e1e72fa0c..fb35980d48 100644 --- a/Code/Network/RKManagedObjectRequestOperation.m +++ b/Code/Network/RKManagedObjectRequestOperation.m @@ -21,20 +21,20 @@ #ifdef _COREDATADEFINES_H #if __has_include("RKManagedObjectCaching.h") -#import "RKManagedObjectRequestOperation.h" -#import "RKLog.h" -#import "RKHTTPUtilities.h" -#import "RKResponseMapperOperation.h" -#import "RKObjectRequestOperationSubclass.h" -#import "NSManagedObjectContext+RKAdditions.h" -#import "NSManagedObject+RKAdditions.h" -#import "RKObjectUtilities.h" +#import +#import +#import +#import +#import +#import +#import +#import // Graph visitor -#import "RKResponseDescriptor.h" -#import "RKEntityMapping.h" -#import "RKDynamicMapping.h" -#import "RKRelationshipMapping.h" +#import +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/Network/RKObjectManager.h b/Code/Network/RKObjectManager.h index 7b107b67d5..450051946a 100644 --- a/Code/Network/RKObjectManager.h +++ b/Code/Network/RKObjectManager.h @@ -18,9 +18,9 @@ // limitations under the License. // -#import "RKRouter.h" -#import "RKPaginator.h" -#import "RKMacros.h" +#import +#import +#import #import diff --git a/Code/Network/RKObjectManager.m b/Code/Network/RKObjectManager.m index 994d955130..dc08014647 100644 --- a/Code/Network/RKObjectManager.m +++ b/Code/Network/RKObjectManager.m @@ -19,23 +19,23 @@ // #import -#import "RKObjectManager.h" -#import "RKObjectParameterization.h" -#import "RKRequestDescriptor.h" -#import "RKResponseDescriptor.h" -#import "RKDictionaryUtilities.h" -#import "RKMIMETypes.h" -#import "RKLog.h" -#import "RKMIMETypeSerialization.h" -#import "RKPathMatcher.h" -#import "RKMappingErrors.h" -#import "RKPaginator.h" -#import "RKDynamicMapping.h" -#import "RKRelationshipMapping.h" -#import "RKObjectRequestOperation.h" -#import "RKRouter.h" -#import "RKRoute.h" -#import "RKRouteSet.h" +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import #ifdef _COREDATADEFINES_H # if __has_include("RKCoreData.h") diff --git a/Code/Network/RKObjectParameterization.h b/Code/Network/RKObjectParameterization.h index 5e9c68f97a..be03c8869f 100644 --- a/Code/Network/RKObjectParameterization.h +++ b/Code/Network/RKObjectParameterization.h @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKRequestDescriptor.h" +#import /** The `RKObjectParameterization` class provides an interface for mapping a local domain object into an `NSDictionary` representation suitable for use as the parameters of an HTTP request. diff --git a/Code/Network/RKObjectParameterization.m b/Code/Network/RKObjectParameterization.m index 857c81a540..b91a75203d 100644 --- a/Code/Network/RKObjectParameterization.m +++ b/Code/Network/RKObjectParameterization.m @@ -18,17 +18,17 @@ // limitations under the License. // -#import "RKMIMETypes.h" -#import "RKSerialization.h" -#import "RKObjectParameterization.h" -#import "RKMIMETypeSerialization.h" -#import "RKLog.h" -#import "RKObjectMappingOperationDataSource.h" -#import "RKObjectMapping.h" -#import "RKMappingOperation.h" -#import "RKMappingErrors.h" -#import "RKPropertyInspector.h" -#import "RKValueTransformers.h" +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/Network/RKObjectRequestOperation.h b/Code/Network/RKObjectRequestOperation.h index ea0d17b251..5fac34aa6a 100644 --- a/Code/Network/RKObjectRequestOperation.h +++ b/Code/Network/RKObjectRequestOperation.h @@ -18,9 +18,9 @@ // limitations under the License. // -#import "RKHTTPRequestOperation.h" -#import "RKMappingResult.h" -#import "RKMapperOperation.h" +#import +#import +#import /** The key for a Boolean NSNumber value that indicates if a `NSCachedURLResponse` stored in the `NSURLCache` has been object mapped to completion. This key is stored on the `userInfo` of the cached response, if any, just before an `RKObjectRequestOperation` transitions to the finished state. diff --git a/Code/Network/RKObjectRequestOperation.m b/Code/Network/RKObjectRequestOperation.m index 07d248fc63..f6abe262c4 100644 --- a/Code/Network/RKObjectRequestOperation.m +++ b/Code/Network/RKObjectRequestOperation.m @@ -19,19 +19,19 @@ // #import -#import "RKObjectRequestOperation.h" -#import "RKResponseMapperOperation.h" -#import "RKResponseDescriptor.h" -#import "RKMIMETypeSerialization.h" -#import "RKHTTPUtilities.h" -#import "RKLog.h" -#import "RKMappingErrors.h" -#import "RKOperationStateMachine.h" +#import +#import +#import +#import +#import +#import +#import +#import #import #if __IPHONE_OS_VERSION_MIN_REQUIRED -#import "AFNetworkActivityIndicatorManager.h" +#import #endif // Set Logging Component diff --git a/Code/Network/RKPaginator.h b/Code/Network/RKPaginator.h index 9baecd0f10..ad906f24e3 100644 --- a/Code/Network/RKPaginator.h +++ b/Code/Network/RKPaginator.h @@ -18,10 +18,10 @@ // limitations under the License. // -#import "RKHTTPRequestOperation.h" -#import "RKObjectRequestOperation.h" -#import "RKObjectMapping.h" -#import "RKMappingResult.h" +#import +#import +#import +#import @protocol RKManagedObjectCaching; diff --git a/Code/Network/RKPaginator.m b/Code/Network/RKPaginator.m index 9d93465afb..69593416f5 100644 --- a/Code/Network/RKPaginator.m +++ b/Code/Network/RKPaginator.m @@ -18,17 +18,17 @@ // limitations under the License. // -#import "RKPaginator.h" -#import "RKMappingOperation.h" -#import "SOCKit.h" -#import "RKLog.h" -#import "RKPathMatcher.h" -#import "RKHTTPUtilities.h" +#import +#import +#import +#import +#import +#import #ifdef _COREDATADEFINES_H #if __has_include("RKCoreData.h") #define RKCoreDataIncluded -#import "RKManagedObjectRequestOperation.h" +#import #endif #endif diff --git a/Code/Network/RKPathMatcher.m b/Code/Network/RKPathMatcher.m index a8ce9bc3ee..258ad63922 100644 --- a/Code/Network/RKPathMatcher.m +++ b/Code/Network/RKPathMatcher.m @@ -18,10 +18,10 @@ // limitations under the License. // -#import "RKPathMatcher.h" -#import "SOCKit.h" -#import "RKLog.h" -#import "RKDictionaryUtilities.h" +#import +#import +#import +#import static NSString *RKEncodeURLString(NSString *unencodedString); extern NSDictionary *RKQueryParametersFromStringWithEncoding(NSString *string, NSStringEncoding stringEncoding); diff --git a/Code/Network/RKRequestDescriptor.h b/Code/Network/RKRequestDescriptor.h index 3b45e17319..83b6e6c322 100644 --- a/Code/Network/RKRequestDescriptor.h +++ b/Code/Network/RKRequestDescriptor.h @@ -19,7 +19,7 @@ // #import -#import "RKHTTPUtilities.h" +#import @class RKMapping; diff --git a/Code/Network/RKRequestDescriptor.m b/Code/Network/RKRequestDescriptor.m index 0a1ddd5c8c..dc61bf7a73 100644 --- a/Code/Network/RKRequestDescriptor.m +++ b/Code/Network/RKRequestDescriptor.m @@ -21,9 +21,9 @@ // limitations under the License. // -#import "RKRequestDescriptor.h" -#import "RKObjectMapping.h" -#import "RKDynamicMapping.h" +#import +#import +#import static void RKAssertValidMappingForRequestDescriptor(RKMapping *mapping) { diff --git a/Code/Network/RKResponseDescriptor.h b/Code/Network/RKResponseDescriptor.h index d2d99289a5..857d1ecc8b 100644 --- a/Code/Network/RKResponseDescriptor.h +++ b/Code/Network/RKResponseDescriptor.h @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKHTTPUtilities.h" +#import @class RKMapping; diff --git a/Code/Network/RKResponseDescriptor.m b/Code/Network/RKResponseDescriptor.m index 9c6bc0ceef..dc51ea6862 100644 --- a/Code/Network/RKResponseDescriptor.m +++ b/Code/Network/RKResponseDescriptor.m @@ -18,10 +18,10 @@ // limitations under the License. // -#import "RKPathMatcher.h" -#import "RKResponseDescriptor.h" -#import "RKHTTPUtilities.h" -#import "RKMapping.h" +#import +#import +#import +#import // Cloned from AFStringFromIndexSet -- method should be non-static for reuse NSString *RKStringFromIndexSet(NSIndexSet *indexSet); diff --git a/Code/Network/RKResponseMapperOperation.h b/Code/Network/RKResponseMapperOperation.h index 7fc04f2774..8c61868f5e 100644 --- a/Code/Network/RKResponseMapperOperation.h +++ b/Code/Network/RKResponseMapperOperation.h @@ -18,9 +18,9 @@ // limitations under the License. // -#import "RKMappingOperationDataSource.h" -#import "RKMapperOperation.h" -#import "RKMappingResult.h" +#import +#import +#import #ifdef _COREDATADEFINES_H @protocol RKManagedObjectCaching; diff --git a/Code/Network/RKResponseMapperOperation.m b/Code/Network/RKResponseMapperOperation.m index d7103a188d..fd9803b312 100644 --- a/Code/Network/RKResponseMapperOperation.m +++ b/Code/Network/RKResponseMapperOperation.m @@ -18,20 +18,20 @@ // limitations under the License. // -#import "RKObjectMappingOperationDataSource.h" -#import "RKLog.h" -#import "RKResponseDescriptor.h" -#import "RKPathMatcher.h" -#import "RKHTTPUtilities.h" -#import "RKResponseMapperOperation.h" -#import "RKMappingErrors.h" -#import "RKMIMETypeSerialization.h" -#import "RKDictionaryUtilities.h" +#import +#import +#import +#import +#import +#import +#import +#import +#import #ifdef _COREDATADEFINES_H #if __has_include("RKCoreData.h") #define RKCoreDataIncluded -#import "RKManagedObjectMappingOperationDataSource.h" +#import #endif #endif diff --git a/Code/Network/RKRoute.h b/Code/Network/RKRoute.h index 66f8f9100c..c283cd2064 100644 --- a/Code/Network/RKRoute.h +++ b/Code/Network/RKRoute.h @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKHTTPUtilities.h" +#import /** The `RKRoute` class models a single routable path pattern in use by the application. A route can be combined with an `NSURL` base URL and interpolated with an object to produce a new fully hydrated URL object. Routes are always instantiated with a path pattern and metadata to provide for the subsequent identification of the defined route. diff --git a/Code/Network/RKRoute.m b/Code/Network/RKRoute.m index 8dbc9ebbdd..23e61b9dd2 100644 --- a/Code/Network/RKRoute.m +++ b/Code/Network/RKRoute.m @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKRoute.h" +#import NSString *RKStringDescribingRequestMethod(RKRequestMethod method); NSString *RKStringDescribingRequestMethod(RKRequestMethod method) diff --git a/Code/Network/RKRouteSet.h b/Code/Network/RKRouteSet.h index 6cb3502774..6565705363 100644 --- a/Code/Network/RKRouteSet.h +++ b/Code/Network/RKRouteSet.h @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKRoute.h" +#import /** The `RKRouteSet` class provides for the storage and retrieval of `RKRoute` objects. Route objects are added and removed the route set to manipulate the routing table of the application. diff --git a/Code/Network/RKRouteSet.m b/Code/Network/RKRouteSet.m index 1038b61517..879c8a386d 100644 --- a/Code/Network/RKRouteSet.m +++ b/Code/Network/RKRouteSet.m @@ -18,8 +18,8 @@ // limitations under the License. // -#import "RKRouteSet.h" -#import "RKPathMatcher.h" +#import +#import @interface RKRouteSet () diff --git a/Code/Network/RKRouter.h b/Code/Network/RKRouter.h index f8f7221ba7..e554d0d231 100644 --- a/Code/Network/RKRouter.h +++ b/Code/Network/RKRouter.h @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKHTTPUtilities.h" +#import @class RKRouteSet; @class RKRoute; diff --git a/Code/Network/RKRouter.m b/Code/Network/RKRouter.m index 2d5565f6d7..fd0d4943d6 100644 --- a/Code/Network/RKRouter.m +++ b/Code/Network/RKRouter.m @@ -18,10 +18,10 @@ // limitations under the License. // -#import "RKRouter.h" -#import "RKRouteSet.h" -#import "RKRoute.h" -#import "RKPathMatcher.h" +#import +#import +#import +#import #import @interface RKRouter () diff --git a/Code/ObjectMapping.h b/Code/ObjectMapping.h index 1ad0b8ceee..07f85e24d5 100644 --- a/Code/ObjectMapping.h +++ b/Code/ObjectMapping.h @@ -20,10 +20,10 @@ #import -#import "RKObjectMapping.h" -#import "RKAttributeMapping.h" -#import "RKRelationshipMapping.h" -#import "RKMappingResult.h" -#import "RKMapperOperation.h" -#import "RKDynamicMapping.h" -#import "RKErrorMessage.h" +#import +#import +#import +#import +#import +#import +#import diff --git a/Code/ObjectMapping/RKAttributeMapping.h b/Code/ObjectMapping/RKAttributeMapping.h index 6d08f968cf..ff1aff4e76 100644 --- a/Code/ObjectMapping/RKAttributeMapping.h +++ b/Code/ObjectMapping/RKAttributeMapping.h @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKPropertyMapping.h" +#import /** Instances of `RKAttributeMapping` define a transformation of data between an attribute value on source object and an attribute value on a destination object within an object mapping. diff --git a/Code/ObjectMapping/RKAttributeMapping.m b/Code/ObjectMapping/RKAttributeMapping.m index 6d83f06a46..a2b4d6f575 100644 --- a/Code/ObjectMapping/RKAttributeMapping.m +++ b/Code/ObjectMapping/RKAttributeMapping.m @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKAttributeMapping.h" +#import @interface RKPropertyMapping () @property (nonatomic, copy, readwrite) NSString *sourceKeyPath; diff --git a/Code/ObjectMapping/RKDynamicMapping.h b/Code/ObjectMapping/RKDynamicMapping.h index ba60aca730..e39d5a283d 100644 --- a/Code/ObjectMapping/RKDynamicMapping.h +++ b/Code/ObjectMapping/RKDynamicMapping.h @@ -18,8 +18,8 @@ // limitations under the License. // -#import "RKMapping.h" -#import "RKObjectMappingMatcher.h" +#import +#import /** The `RKDynamicMapping` class is an `RKMapping` subclass that provides an interface for deferring the decision about how a given object representation is to be mapped until run time. This enables many interesting mapping strategies, such as mapping similarly structured data differently and constructing object mappings at run time by examining the data being mapped. diff --git a/Code/ObjectMapping/RKDynamicMapping.m b/Code/ObjectMapping/RKDynamicMapping.m index f7138ba361..799e5b3dd2 100644 --- a/Code/ObjectMapping/RKDynamicMapping.m +++ b/Code/ObjectMapping/RKDynamicMapping.m @@ -18,9 +18,9 @@ // limitations under the License. // -#import "RKDynamicMapping.h" -#import "RKObjectMappingMatcher.h" -#import "RKLog.h" +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/ObjectMapping/RKErrorMessage.m b/Code/ObjectMapping/RKErrorMessage.m index 1a102c4aa7..e9dae5863d 100644 --- a/Code/ObjectMapping/RKErrorMessage.m +++ b/Code/ObjectMapping/RKErrorMessage.m @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKErrorMessage.h" +#import @implementation RKErrorMessage diff --git a/Code/ObjectMapping/RKHTTPUtilities.m b/Code/ObjectMapping/RKHTTPUtilities.m index 046a3edb99..58af357a43 100644 --- a/Code/ObjectMapping/RKHTTPUtilities.m +++ b/Code/ObjectMapping/RKHTTPUtilities.m @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKHTTPUtilities.h" +#import NSUInteger RKStatusCodeRangeLength = 100; diff --git a/Code/ObjectMapping/RKMapperOperation.h b/Code/ObjectMapping/RKMapperOperation.h index 94489d0301..0c25ca01e7 100644 --- a/Code/ObjectMapping/RKMapperOperation.h +++ b/Code/ObjectMapping/RKMapperOperation.h @@ -19,11 +19,11 @@ // #import -#import "RKObjectMapping.h" -#import "RKMappingOperation.h" -#import "RKMappingResult.h" -#import "RKMappingOperationDataSource.h" -#import "RKErrors.h" +#import +#import +#import +#import +#import @protocol RKMapperOperationDelegate; diff --git a/Code/ObjectMapping/RKMapperOperation.m b/Code/ObjectMapping/RKMapperOperation.m index c58cebc595..3df1fde23c 100644 --- a/Code/ObjectMapping/RKMapperOperation.m +++ b/Code/ObjectMapping/RKMapperOperation.m @@ -18,14 +18,14 @@ // limitations under the License. // -#import "RKMapperOperation.h" -#import "RKMapperOperation_Private.h" -#import "RKObjectMapping.h" -#import "RKObjectMappingOperationDataSource.h" -#import "RKMappingErrors.h" -#import "RKDynamicMapping.h" -#import "RKLog.h" -#import "RKDictionaryUtilities.h" +#import +#import +#import +#import +#import +#import +#import +#import NSString * const RKMappingErrorKeyPathErrorKey = @"keyPath"; diff --git a/Code/ObjectMapping/RKMapping.m b/Code/ObjectMapping/RKMapping.m index 9f60f3b9ed..73f11f6a6e 100644 --- a/Code/ObjectMapping/RKMapping.m +++ b/Code/ObjectMapping/RKMapping.m @@ -6,7 +6,7 @@ // Copyright (c) 2009-2012 RestKit. All rights reserved. // -#import "RKMapping.h" +#import @implementation RKMapping diff --git a/Code/ObjectMapping/RKMappingErrors.h b/Code/ObjectMapping/RKMappingErrors.h index 4636bcb803..b9ef3b9334 100644 --- a/Code/ObjectMapping/RKMappingErrors.h +++ b/Code/ObjectMapping/RKMappingErrors.h @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKErrors.h" +#import typedef NS_ENUM(NSInteger, RKMappingErrorCode) { RKMappingErrorNotFound = 1001, // No mapping found diff --git a/Code/ObjectMapping/RKMappingOperation.h b/Code/ObjectMapping/RKMappingOperation.h index 7c5d782052..886c4a6b4c 100644 --- a/Code/ObjectMapping/RKMappingOperation.h +++ b/Code/ObjectMapping/RKMappingOperation.h @@ -18,8 +18,8 @@ // limitations under the License. // -#import "RKObjectMapping.h" -#import "RKAttributeMapping.h" +#import +#import @class RKMappingOperation, RKDynamicMapping, RKConnectionDescription, RKMappingInfo; @protocol RKMappingOperationDataSource; diff --git a/Code/ObjectMapping/RKMappingOperation.m b/Code/ObjectMapping/RKMappingOperation.m index e87afcba2a..7b82cc907c 100644 --- a/Code/ObjectMapping/RKMappingOperation.m +++ b/Code/ObjectMapping/RKMappingOperation.m @@ -19,19 +19,19 @@ // #import -#import "RKMappingOperation.h" -#import "RKMappingErrors.h" -#import "RKPropertyInspector.h" -#import "RKAttributeMapping.h" -#import "RKRelationshipMapping.h" -#import "RKErrors.h" -#import "RKLog.h" -#import "RKMappingOperationDataSource.h" -#import "RKObjectMappingOperationDataSource.h" -#import "RKDynamicMapping.h" -#import "RKObjectUtilities.h" -#import "RKValueTransformers.h" -#import "RKDictionaryUtilities.h" +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/ObjectMapping/RKMappingResult.m b/Code/ObjectMapping/RKMappingResult.m index d3b7f5828d..49eef18537 100644 --- a/Code/ObjectMapping/RKMappingResult.m +++ b/Code/ObjectMapping/RKMappingResult.m @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKMappingResult.h" +#import @interface RKMappingResult () @property (nonatomic, strong) NSDictionary *keyPathToMappedObjects; diff --git a/Code/ObjectMapping/RKObjectMapping.h b/Code/ObjectMapping/RKObjectMapping.h index 9094c11f09..6482d869ac 100644 --- a/Code/ObjectMapping/RKObjectMapping.h +++ b/Code/ObjectMapping/RKObjectMapping.h @@ -18,8 +18,8 @@ // limitations under the License. // -#import "RKMacros.h" -#import "RKMapping.h" +#import +#import #import diff --git a/Code/ObjectMapping/RKObjectMapping.m b/Code/ObjectMapping/RKObjectMapping.m index 74243b4b75..daaa8c58c4 100644 --- a/Code/ObjectMapping/RKObjectMapping.m +++ b/Code/ObjectMapping/RKObjectMapping.m @@ -19,14 +19,14 @@ // #import -#import "RKObjectMapping.h" -#import "RKRelationshipMapping.h" -#import "RKPropertyInspector.h" -#import "RKLog.h" -#import "RKAttributeMapping.h" -#import "RKRelationshipMapping.h" -#import "RKValueTransformers.h" -#import "ISO8601DateFormatterValueTransformer.h" +#import +#import +#import +#import +#import +#import +#import +#import typedef NSString * (^RKSourceToDesinationKeyTransformationBlock)(RKObjectMapping *, NSString *); diff --git a/Code/ObjectMapping/RKObjectMappingMatcher.h b/Code/ObjectMapping/RKObjectMappingMatcher.h index 577550cd98..a00b66d05e 100644 --- a/Code/ObjectMapping/RKObjectMappingMatcher.h +++ b/Code/ObjectMapping/RKObjectMappingMatcher.h @@ -7,7 +7,7 @@ // #import -#import "RKObjectMapping.h" +#import /** The `RKObjectMappingMatcher` class provides an interface for encapsulating the selection of an object mapping based on runtime values. Matcher objects may be configured by key path and expected value or with a predicate object. diff --git a/Code/ObjectMapping/RKObjectMappingMatcher.m b/Code/ObjectMapping/RKObjectMappingMatcher.m index 3abfe3c859..6475b869db 100644 --- a/Code/ObjectMapping/RKObjectMappingMatcher.m +++ b/Code/ObjectMapping/RKObjectMappingMatcher.m @@ -6,8 +6,8 @@ // Copyright (c) 2009-2012 RestKit. All rights reserved. // -#import "RKObjectMappingMatcher.h" -#import "RKObjectUtilities.h" +#import +#import /////////////////////////////////////////////////////////////////////////////////////////////////// diff --git a/Code/ObjectMapping/RKObjectMappingOperationDataSource.h b/Code/ObjectMapping/RKObjectMappingOperationDataSource.h index 3daf2166f8..46b41f92dd 100644 --- a/Code/ObjectMapping/RKObjectMappingOperationDataSource.h +++ b/Code/ObjectMapping/RKObjectMappingOperationDataSource.h @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKMappingOperationDataSource.h" +#import /** The `RKObjectMappingOperationDataSource` class is an implementation of the `RKMappingOperationDataSource` protocol for use in performing object mappings that target plain old `NSObject` derived classes (as opposed to `NSManagedObject` derived persistent entities). diff --git a/Code/ObjectMapping/RKObjectMappingOperationDataSource.m b/Code/ObjectMapping/RKObjectMappingOperationDataSource.m index e8aba71f7f..5634df8f4c 100644 --- a/Code/ObjectMapping/RKObjectMappingOperationDataSource.m +++ b/Code/ObjectMapping/RKObjectMappingOperationDataSource.m @@ -18,9 +18,9 @@ // limitations under the License. // -#import "RKObjectMappingOperationDataSource.h" -#import "RKObjectMapping.h" -#import "RKMappingOperation.h" +#import +#import +#import @implementation RKObjectMappingOperationDataSource diff --git a/Code/ObjectMapping/RKObjectUtilities.m b/Code/ObjectMapping/RKObjectUtilities.m index 052335e75e..1324607c94 100644 --- a/Code/ObjectMapping/RKObjectUtilities.m +++ b/Code/ObjectMapping/RKObjectUtilities.m @@ -20,7 +20,7 @@ #import #import -#import "RKObjectUtilities.h" +#import BOOL RKObjectIsEqualToObject(id object, id anotherObject) { NSCAssert(object, @"Expected object not to be nil"); diff --git a/Code/ObjectMapping/RKPropertyInspector.m b/Code/ObjectMapping/RKPropertyInspector.m index 7106713582..0ea3dd51db 100644 --- a/Code/ObjectMapping/RKPropertyInspector.m +++ b/Code/ObjectMapping/RKPropertyInspector.m @@ -19,9 +19,9 @@ // #import -#import "RKPropertyInspector.h" -#import "RKLog.h" -#import "RKObjectUtilities.h" +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/ObjectMapping/RKPropertyMapping.m b/Code/ObjectMapping/RKPropertyMapping.m index 0fc2ca1128..f2d6c7d905 100644 --- a/Code/ObjectMapping/RKPropertyMapping.m +++ b/Code/ObjectMapping/RKPropertyMapping.m @@ -18,8 +18,8 @@ // limitations under the License. // -#import "RKPropertyMapping.h" -#import "RKObjectMapping.h" +#import +#import /** For consistency with URI Templates (and most web templating languages in general) we are transitioning diff --git a/Code/ObjectMapping/RKRelationshipMapping.h b/Code/ObjectMapping/RKRelationshipMapping.h index 5c81276af6..6d73bd0db0 100644 --- a/Code/ObjectMapping/RKRelationshipMapping.h +++ b/Code/ObjectMapping/RKRelationshipMapping.h @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKPropertyMapping.h" +#import @class RKMapping; diff --git a/Code/ObjectMapping/RKRelationshipMapping.m b/Code/ObjectMapping/RKRelationshipMapping.m index ae867c09ab..962d5e45e2 100644 --- a/Code/ObjectMapping/RKRelationshipMapping.m +++ b/Code/ObjectMapping/RKRelationshipMapping.m @@ -18,8 +18,8 @@ // limitations under the License. // -#import "RKRelationshipMapping.h" -#import "RKMapping.h" +#import +#import @interface RKPropertyMapping () @property (nonatomic, copy, readwrite) NSString *sourceKeyPath; diff --git a/Code/RestKit.h b/Code/RestKit.h index 30e1951360..d690812855 100644 --- a/Code/RestKit.h +++ b/Code/RestKit.h @@ -22,19 +22,19 @@ #define _RESTKIT_ #if __has_include("ObjectMapping.h") -#import "ObjectMapping.h" +#import #endif #if __has_include("Network.h") -#import "Network.h" +#import #endif #if __has_include("Support.h") -#import "Support.h" +#import #endif #if __has_include("RKCoreData.h") -#import "RKCoreData.h" +#import #endif /** diff --git a/Code/Search.h b/Code/Search.h index e7ac7da942..3883199370 100644 --- a/Code/Search.h +++ b/Code/Search.h @@ -18,9 +18,9 @@ // limitations under the License. // -#import "RKSearchPredicate.h" +#import #ifdef _COREDATADEFINES_H -#import "RKSearchIndexer.h" -#import "RKManagedObjectStore+RKSearchAdditions.h" +#import +#import #endif diff --git a/Code/Search/RKManagedObjectStore+RKSearchAdditions.h b/Code/Search/RKManagedObjectStore+RKSearchAdditions.h index 980ec4e768..38fce74ccd 100644 --- a/Code/Search/RKManagedObjectStore+RKSearchAdditions.h +++ b/Code/Search/RKManagedObjectStore+RKSearchAdditions.h @@ -18,8 +18,8 @@ // limitations under the License. // -#import "RKManagedObjectStore.h" -#import "RKSearchIndexer.h" +#import +#import /** The search additions category provides support for configuring search indexing for entities in a managed object store. diff --git a/Code/Search/RKManagedObjectStore+RKSearchAdditions.m b/Code/Search/RKManagedObjectStore+RKSearchAdditions.m index 45c6dbfd1b..06f7bedf87 100644 --- a/Code/Search/RKManagedObjectStore+RKSearchAdditions.m +++ b/Code/Search/RKManagedObjectStore+RKSearchAdditions.m @@ -19,8 +19,8 @@ // #import -#import "RKManagedObjectStore+RKSearchAdditions.h" -#import "RKSearchWordEntity.h" +#import +#import static char searchIndexerAssociationKey; diff --git a/Code/Search/RKSearchIndexer.m b/Code/Search/RKSearchIndexer.m index 87f7dbdca2..6fd39d8bb7 100644 --- a/Code/Search/RKSearchIndexer.m +++ b/Code/Search/RKSearchIndexer.m @@ -18,13 +18,13 @@ // limitations under the License. // -#import "RKSearchIndexer.h" -#import "RKSearchWordEntity.h" -#import "RKSearchWord.h" -#import "RKLog.h" -#import "RKStringTokenizer.h" -#import "NSManagedObjectContext+RKAdditions.h" -#import "RKObjectUtilities.h" +#import +#import +#import +#import +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/Search/RKSearchPredicate.m b/Code/Search/RKSearchPredicate.m index 37df4d9b62..57f6e48658 100644 --- a/Code/Search/RKSearchPredicate.m +++ b/Code/Search/RKSearchPredicate.m @@ -6,8 +6,8 @@ // Copyright (c) 2012 RestKit. All rights reserved. // -#import "RKSearchPredicate.h" -#import "RKStringTokenizer.h" +#import +#import @interface RKSearchPredicate() diff --git a/Code/Search/RKSearchWord.m b/Code/Search/RKSearchWord.m index 9853728ef2..a824eb9a8f 100644 --- a/Code/Search/RKSearchWord.m +++ b/Code/Search/RKSearchWord.m @@ -18,8 +18,8 @@ // limitations under the License. // -#import "RKSearchWord.h" -#import "RKLog.h" +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/Search/RKSearchWordEntity.m b/Code/Search/RKSearchWordEntity.m index 07265c3c5c..ed70a5e34e 100644 --- a/Code/Search/RKSearchWordEntity.m +++ b/Code/Search/RKSearchWordEntity.m @@ -6,7 +6,7 @@ // Copyright (c) 2012 RestKit. All rights reserved. // -#import "RKSearchWordEntity.h" +#import NSString * const RKSearchWordEntityName = @"RKSearchWord"; NSString * const RKSearchWordAttributeName = @"word"; diff --git a/Code/Support.h b/Code/Support.h index ba3e127477..2eb539a27e 100644 --- a/Code/Support.h +++ b/Code/Support.h @@ -19,13 +19,13 @@ // // Load shared support code -#import "RKErrors.h" -#import "RKMIMETypes.h" -#import "RKLog.h" -#import "RKDotNetDateFormatter.h" -#import "RKPathUtilities.h" -#import "RKDictionaryUtilities.h" -#import "RKURLEncodedSerialization.h" -#import "RKNSJSONSerialization.h" -#import "RKMIMETypeSerialization.h" -#import "RKStringTokenizer.h" +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import diff --git a/Code/Support/RKDictionaryUtilities.m b/Code/Support/RKDictionaryUtilities.m index 66b09cee27..dd0661a235 100644 --- a/Code/Support/RKDictionaryUtilities.m +++ b/Code/Support/RKDictionaryUtilities.m @@ -6,7 +6,7 @@ // Copyright (c) 2012 RestKit. All rights reserved. // -#import "RKDictionaryUtilities.h" +#import NSDictionary *RKDictionaryByMergingDictionaryWithDictionary(NSDictionary *dict1, NSDictionary *dict2) { diff --git a/Code/Support/RKDotNetDateFormatter.m b/Code/Support/RKDotNetDateFormatter.m index 11e2a53238..c43c278a6b 100644 --- a/Code/Support/RKDotNetDateFormatter.m +++ b/Code/Support/RKDotNetDateFormatter.m @@ -18,8 +18,8 @@ // limitations under the License. // -#import "RKDotNetDateFormatter.h" -#import "RKLog.h" +#import +#import static BOOL RKDotNetDateFormatterIsValidRange(NSRange rangeOfMatch) { diff --git a/Code/Support/RKErrors.m b/Code/Support/RKErrors.m index ae9a1541d4..9f094a0c29 100644 --- a/Code/Support/RKErrors.m +++ b/Code/Support/RKErrors.m @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKErrors.h" +#import NSString * const RKErrorDomain = @"org.restkit.RestKit.ErrorDomain"; diff --git a/Code/Support/RKLog.m b/Code/Support/RKLog.m index c89639a32e..a991f24d5e 100644 --- a/Code/Support/RKLog.m +++ b/Code/Support/RKLog.m @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKLog.h" +#import @interface RKNSLogLogger : NSObject @end @@ -27,8 +27,8 @@ @interface RKNSLogLogger : NSObject #import "LCLNSLogger_RK.h" #define RKLOG_CLASS LCLNSLogger_RK -#elif __has_include("RKLumberjackLogger.h") && __has_include() - #import "RKLumberjackLogger.h" +#elif __has_include() + #import #define RKLOG_CLASS RKLumberjackLogger #else diff --git a/Code/Support/RKMIMETypeSerialization.h b/Code/Support/RKMIMETypeSerialization.h index 071869afd1..4ef7213486 100644 --- a/Code/Support/RKMIMETypeSerialization.h +++ b/Code/Support/RKMIMETypeSerialization.h @@ -18,8 +18,8 @@ // limitations under the License. // -#import "RKMIMETypes.h" -#import "RKSerialization.h" +#import +#import /** The `RKMIMETypeSerialization` class provides support for the registration of classes conforming to the `RKSerialization` protocol by MIME Type and the serialization and deserialization of content by MIME Type. Serialization implementations may be registered by an exact string match (i.e. 'application/json' for a JSON serialization implementation) or by regular expression to match MIME Type by pattern. diff --git a/Code/Support/RKMIMETypeSerialization.m b/Code/Support/RKMIMETypeSerialization.m index 2e3bf562a8..ba9fbe53e7 100644 --- a/Code/Support/RKMIMETypeSerialization.m +++ b/Code/Support/RKMIMETypeSerialization.m @@ -18,12 +18,12 @@ // limitations under the License. // -#import "RKMIMETypeSerialization.h" -#import "RKErrors.h" -#import "RKSerialization.h" -#import "RKLog.h" -#import "RKURLEncodedSerialization.h" -#import "RKNSJSONSerialization.h" +#import +#import +#import +#import +#import +#import // Define logging component #undef RKLogComponent diff --git a/Code/Support/RKMIMETypes.m b/Code/Support/RKMIMETypes.m index c22ff5fbc9..fe256d51f3 100644 --- a/Code/Support/RKMIMETypes.m +++ b/Code/Support/RKMIMETypes.m @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKMIMETypes.h" +#import NSString * const RKMIMETypeJSON = @"application/json"; NSString * const RKMIMETypeFormURLEncoded = @"application/x-www-form-urlencoded"; diff --git a/Code/Support/RKNSJSONSerialization.h b/Code/Support/RKNSJSONSerialization.h index 598e250304..8670141446 100644 --- a/Code/Support/RKNSJSONSerialization.h +++ b/Code/Support/RKNSJSONSerialization.h @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKSerialization.h" +#import /** The `RKNSJSONSerialization` class conforms to the `RKSerialization` protocol and provides support for the serialization and deserialization of data in the JSON format using the Apple provided `NSJSONSerialization` class. This is the default JSON implementation for RestKit. diff --git a/Code/Support/RKNSJSONSerialization.m b/Code/Support/RKNSJSONSerialization.m index 3b277ea260..baa48d2a22 100644 --- a/Code/Support/RKNSJSONSerialization.m +++ b/Code/Support/RKNSJSONSerialization.m @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKNSJSONSerialization.h" +#import @implementation RKNSJSONSerialization diff --git a/Code/Support/RKOperationStateMachine.m b/Code/Support/RKOperationStateMachine.m index 33bb1abe28..967de0f2d6 100644 --- a/Code/Support/RKOperationStateMachine.m +++ b/Code/Support/RKOperationStateMachine.m @@ -18,8 +18,8 @@ // limitations under the License. // -#import "TransitionKit.h" -#import "RKOperationStateMachine.h" +#import +#import NSString *const RKOperationFailureException = @"RKOperationFailureException"; diff --git a/Code/Support/RKPathUtilities.m b/Code/Support/RKPathUtilities.m index 373657a544..b7757e175a 100644 --- a/Code/Support/RKPathUtilities.m +++ b/Code/Support/RKPathUtilities.m @@ -14,8 +14,8 @@ #endif #import #import -#import "RKPathUtilities.h" -#import "RKLog.h" +#import +#import NSString *RKExecutableName(void); diff --git a/Code/Support/RKStringTokenizer.m b/Code/Support/RKStringTokenizer.m index 48e36449c1..b8ccd86b47 100644 --- a/Code/Support/RKStringTokenizer.m +++ b/Code/Support/RKStringTokenizer.m @@ -6,7 +6,7 @@ // Copyright (c) 2012 RestKit. All rights reserved. // -#import "RKStringTokenizer.h" +#import @implementation RKStringTokenizer diff --git a/Code/Support/RKURLEncodedSerialization.h b/Code/Support/RKURLEncodedSerialization.h index 3c109d2c51..0b41fccdd9 100644 --- a/Code/Support/RKURLEncodedSerialization.h +++ b/Code/Support/RKURLEncodedSerialization.h @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKSerialization.h" +#import /** The `RKURLEncodedSerialization` class conforms to the `RKSerialization` protocol and provides support for the serialization and deserialization of URL encoded data. URL encoding is used to replace certain characters in a string with equivalent percent escape sequences. The list of characters replaced by the implementation are designed as illegal URL characters by RFC 3986. URL encoded data is used for the submission of HTML forms with the MIME Type `application/x-www-form-urlencoded`. diff --git a/Code/Support/RKURLEncodedSerialization.m b/Code/Support/RKURLEncodedSerialization.m index 8a1d7ed9c6..88f135b17e 100644 --- a/Code/Support/RKURLEncodedSerialization.m +++ b/Code/Support/RKURLEncodedSerialization.m @@ -18,7 +18,7 @@ // limitations under the License. // -#import "RKURLEncodedSerialization.h" +#import #pragma mark - AFNetworking diff --git a/Code/Testing.h b/Code/Testing.h index a76696a158..b81708cff2 100644 --- a/Code/Testing.h +++ b/Code/Testing.h @@ -19,13 +19,13 @@ // -#import "RKTestFixture.h" -#import "RKTestNotificationObserver.h" -#import "RKTestFactory.h" -#import "RKTestHelpers.h" -#import "RKMappingTest.h" +#import +#import +#import +#import +#import #ifdef _COREDATADEFINES_H -#import "RKConnectionTestExpectation.h" +#import #endif diff --git a/Code/Testing/RKBenchmark.m b/Code/Testing/RKBenchmark.m index 844e06c706..8584a272c1 100644 --- a/Code/Testing/RKBenchmark.m +++ b/Code/Testing/RKBenchmark.m @@ -7,7 +7,7 @@ // Copyleft 2009. Some rights reserved. // -#import "RKBenchmark.h" +#import @interface RKBenchmark () @property (nonatomic, assign, readwrite) CFAbsoluteTime startTime; diff --git a/Code/Testing/RKConnectionTestExpectation.m b/Code/Testing/RKConnectionTestExpectation.m index 7f86eb7f4e..42dbfc34ce 100644 --- a/Code/Testing/RKConnectionTestExpectation.m +++ b/Code/Testing/RKConnectionTestExpectation.m @@ -20,8 +20,8 @@ #ifdef _COREDATADEFINES_H -#import "RKConnectionTestExpectation.h" -#import "RKObjectUtilities.h" +#import +#import @interface RKConnectionTestExpectation () @property (nonatomic, copy, readwrite) NSString *relationshipName; diff --git a/Code/Testing/RKMappingTest.h b/Code/Testing/RKMappingTest.h index 737588459e..0e18e61b42 100644 --- a/Code/Testing/RKMappingTest.h +++ b/Code/Testing/RKMappingTest.h @@ -19,8 +19,8 @@ // #import -#import "RKMappingOperation.h" -#import "RKPropertyMappingTestExpectation.h" +#import +#import @protocol RKMappingOperationDataSource, RKManagedObjectCaching; diff --git a/Code/Testing/RKMappingTest.m b/Code/Testing/RKMappingTest.m index 231f5fb631..587fd6e944 100644 --- a/Code/Testing/RKMappingTest.m +++ b/Code/Testing/RKMappingTest.m @@ -18,22 +18,22 @@ // limitations under the License. // -#import "RKMappingTest.h" -#import "RKObjectMappingOperationDataSource.h" -#import "RKRelationshipMapping.h" -#import "RKErrors.h" -#import "RKObjectUtilities.h" -#import "RKLog.h" +#import +#import +#import +#import +#import +#import // Core Data #ifdef _COREDATADEFINES_H #if __has_include("RKCoreData.h") #define RKCoreDataIncluded -#import "RKEntityMapping.h" -#import "RKConnectionDescription.h" -#import "RKConnectionTestExpectation.h" -#import "RKFetchRequestManagedObjectCache.h" -#import "RKManagedObjectMappingOperationDataSource.h" +#import +#import +#import +#import +#import #endif #endif diff --git a/Code/Testing/RKPropertyMappingTestExpectation.m b/Code/Testing/RKPropertyMappingTestExpectation.m index 8023f57426..86f796d6ef 100644 --- a/Code/Testing/RKPropertyMappingTestExpectation.m +++ b/Code/Testing/RKPropertyMappingTestExpectation.m @@ -18,8 +18,8 @@ // limitations under the License. // -#import "RKPropertyMappingTestExpectation.h" -#import "RKPropertyMapping.h" +#import +#import @interface RKPropertyMappingTestExpectation () @property (nonatomic, copy, readwrite) NSString *sourceKeyPath; diff --git a/Code/Testing/RKTestFactory.m b/Code/Testing/RKTestFactory.m index c3eb6c59e8..533df090f0 100644 --- a/Code/Testing/RKTestFactory.m +++ b/Code/Testing/RKTestFactory.m @@ -19,17 +19,17 @@ // #import "AFHTTPClient.h" -#import "RKTestFactory.h" -#import "RKLog.h" -#import "RKObjectManager.h" -#import "RKPathUtilities.h" -#import "RKMIMETypeSerialization.h" -#import "RKObjectRequestOperation.h" +#import +#import +#import +#import +#import +#import #ifdef _COREDATADEFINES_H #if __has_include("RKCoreData.h") #define RKCoreDataIncluded -#import "RKManagedObjectStore.h" +#import #endif #endif diff --git a/Code/Testing/RKTestFixture.m b/Code/Testing/RKTestFixture.m index 920fd6c653..c2bc6262eb 100644 --- a/Code/Testing/RKTestFixture.m +++ b/Code/Testing/RKTestFixture.m @@ -18,10 +18,10 @@ // limitations under the License. // -#import "RKTestFixture.h" -#import "RKLog.h" -#import "RKPathUtilities.h" -#import "RKMIMETypeSerialization.h" +#import +#import +#import +#import static NSBundle *fixtureBundle = nil; diff --git a/Code/Testing/RKTestHelpers.h b/Code/Testing/RKTestHelpers.h index 0c924ce165..bab4e252b4 100644 --- a/Code/Testing/RKTestHelpers.h +++ b/Code/Testing/RKTestHelpers.h @@ -19,7 +19,7 @@ // #import -#import "RKHTTPUtilities.h" +#import #ifdef _COREDATADEFINES_H #if __has_include("RKCoreData.h") diff --git a/Code/Testing/RKTestHelpers.m b/Code/Testing/RKTestHelpers.m index 3884fbafd2..f30d5bd3e3 100644 --- a/Code/Testing/RKTestHelpers.m +++ b/Code/Testing/RKTestHelpers.m @@ -18,18 +18,18 @@ // limitations under the License. // -#import "RKTestHelpers.h" -#import "RKObjectManager.h" -#import "RKRoute.h" -#import "RKPathUtilities.h" -#import "RKLog.h" +#import +#import +#import +#import +#import #import "SOCKit.h" -#import "RKRouteSet.h" +#import #ifdef _COREDATADEFINES_H #if __has_include("RKCoreData.h") #define RKCoreDataIncluded -#import "RKManagedObjectRequestOperation.h" +#import #endif #endif diff --git a/Code/Testing/RKTestNotificationObserver.m b/Code/Testing/RKTestNotificationObserver.m index d5a531ba41..71ea78e343 100644 --- a/Code/Testing/RKTestNotificationObserver.m +++ b/Code/Testing/RKTestNotificationObserver.m @@ -6,7 +6,7 @@ // Copyright (c) 2009-2012 RestKit. All rights reserved. // -#import "RKTestNotificationObserver.h" +#import @interface RKTestNotificationObserver () @property (nonatomic, assign, getter = isObserverAdded) BOOL observerAdded; From 28e3ce80007875d5e0a63530bdeba9603df2a9ba Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Thu, 24 Sep 2015 17:45:12 -0500 Subject: [PATCH 79/94] Sort all imports --- Code/CocoaLumberjack/RKLumberjackLogger.m | 2 +- Code/CoreData.h | 16 +++++++------- Code/CoreData/NSManagedObject+RKAdditions.m | 2 +- .../NSManagedObjectContext+RKAdditions.m | 2 +- Code/CoreData/RKEntityByAttributeCache.m | 6 ++--- Code/CoreData/RKEntityCache.m | 2 +- Code/CoreData/RKEntityMapping.h | 2 +- Code/CoreData/RKEntityMapping.m | 6 ++--- .../RKFetchRequestManagedObjectCache.m | 4 ++-- Code/CoreData/RKInMemoryManagedObjectCache.m | 4 ++-- Code/CoreData/RKManagedObjectImporter.m | 8 +++---- ...KManagedObjectMappingOperationDataSource.m | 20 ++++++++--------- Code/CoreData/RKManagedObjectStore.m | 12 +++++----- Code/CoreData/RKPropertyInspector+CoreData.m | 4 ++-- .../RKRelationshipConnectionOperation.m | 6 ++--- Code/Network.h | 12 +++++----- Code/Network/RKHTTPRequestOperation.m | 4 ++-- .../Network/RKManagedObjectRequestOperation.h | 2 +- .../Network/RKManagedObjectRequestOperation.m | 12 +++++----- Code/Network/RKObjectManager.h | 2 +- Code/Network/RKObjectManager.m | 22 +++++++++---------- Code/Network/RKObjectParameterization.m | 16 +++++++------- Code/Network/RKObjectRequestOperation.h | 2 +- Code/Network/RKObjectRequestOperation.m | 8 +++---- Code/Network/RKPaginator.h | 2 +- Code/Network/RKPaginator.m | 6 ++--- Code/Network/RKPathMatcher.m | 4 ++-- Code/Network/RKRequestDescriptor.m | 2 +- Code/Network/RKResponseMapperOperation.h | 2 +- Code/Network/RKResponseMapperOperation.m | 10 ++++----- Code/Network/RKRouteSet.m | 2 +- Code/Network/RKRouter.m | 6 ++--- Code/ObjectMapping.h | 8 +++---- Code/ObjectMapping/RKMapperOperation.h | 4 ++-- Code/ObjectMapping/RKMapperOperation.m | 6 ++--- Code/ObjectMapping/RKMappingOperation.h | 2 +- Code/ObjectMapping/RKMappingOperation.m | 18 +++++++-------- Code/ObjectMapping/RKObjectMapping.h | 2 +- Code/ObjectMapping/RKObjectMapping.m | 9 ++++---- .../RKObjectMappingOperationDataSource.m | 4 ++-- Code/ObjectMapping/RKObjectUtilities.m | 2 +- Code/ObjectMapping/RKPropertyInspector.m | 4 ++-- Code/ObjectMapping/RKPropertyMapping.m | 2 +- Code/ObjectMapping/RKRelationshipMapping.m | 2 +- Code/Search.h | 2 +- .../RKManagedObjectStore+RKSearchAdditions.m | 2 +- Code/Search/RKSearchIndexer.m | 6 ++--- Code/Support.h | 12 +++++----- Code/Support/RKMIMETypeSerialization.m | 6 ++--- Code/Support/RKOperationStateMachine.m | 2 +- Code/Support/RKPathUtilities.m | 4 ++-- Code/Testing.h | 6 ++--- Code/Testing/RKConnectionTestExpectation.m | 2 +- Code/Testing/RKMappingTest.m | 8 +++---- .../RKPropertyMappingTestExpectation.m | 2 +- Code/Testing/RKTestFactory.m | 8 +++---- Code/Testing/RKTestFixture.m | 4 ++-- Code/Testing/RKTestHelpers.m | 8 +++---- 58 files changed, 172 insertions(+), 173 deletions(-) diff --git a/Code/CocoaLumberjack/RKLumberjackLogger.m b/Code/CocoaLumberjack/RKLumberjackLogger.m index e0e3f13dfc..0e2828f2e4 100644 --- a/Code/CocoaLumberjack/RKLumberjackLogger.m +++ b/Code/CocoaLumberjack/RKLumberjackLogger.m @@ -7,8 +7,8 @@ // #if __has_include() -#import #import +#import @implementation RKLumberjackLogger diff --git a/Code/CoreData.h b/Code/CoreData.h index ed12a379f4..247d919ae1 100644 --- a/Code/CoreData.h +++ b/Code/CoreData.h @@ -19,15 +19,15 @@ // #import -#import -#import -#import -#import #import -#import -#import #import +#import +#import +#import +#import +#import +#import -#import -#import #import +#import +#import diff --git a/Code/CoreData/NSManagedObject+RKAdditions.m b/Code/CoreData/NSManagedObject+RKAdditions.m index 178ccabdf0..d98a0922c2 100644 --- a/Code/CoreData/NSManagedObject+RKAdditions.m +++ b/Code/CoreData/NSManagedObject+RKAdditions.m @@ -8,8 +8,8 @@ #import #import -#import #import +#import @implementation NSManagedObject (RKAdditions) diff --git a/Code/CoreData/NSManagedObjectContext+RKAdditions.m b/Code/CoreData/NSManagedObjectContext+RKAdditions.m index a0ec7f5ad0..48e1677eac 100644 --- a/Code/CoreData/NSManagedObjectContext+RKAdditions.m +++ b/Code/CoreData/NSManagedObjectContext+RKAdditions.m @@ -18,9 +18,9 @@ // limitations under the License. // -#import #import #import +#import @implementation NSManagedObjectContext (RKAdditions) diff --git a/Code/CoreData/RKEntityByAttributeCache.m b/Code/CoreData/RKEntityByAttributeCache.m index 54ce2626b3..5176d66dfe 100644 --- a/Code/CoreData/RKEntityByAttributeCache.m +++ b/Code/CoreData/RKEntityByAttributeCache.m @@ -22,12 +22,12 @@ #import #endif +#import #import -#import -#import #import -#import #import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/CoreData/RKEntityCache.m b/Code/CoreData/RKEntityCache.m index d5f1279d65..501d4648ed 100644 --- a/Code/CoreData/RKEntityCache.m +++ b/Code/CoreData/RKEntityCache.m @@ -18,8 +18,8 @@ // limitations under the License. // -#import #import +#import @interface RKEntityCache () @property (nonatomic, strong) NSMutableSet *attributeCaches; diff --git a/Code/CoreData/RKEntityMapping.h b/Code/CoreData/RKEntityMapping.h index 6fb4db6d83..e727bcd537 100644 --- a/Code/CoreData/RKEntityMapping.h +++ b/Code/CoreData/RKEntityMapping.h @@ -19,8 +19,8 @@ // #import -#import #import +#import #import @class RKManagedObjectStore; diff --git a/Code/CoreData/RKEntityMapping.m b/Code/CoreData/RKEntityMapping.m index 0bcccb9716..e69de9964c 100644 --- a/Code/CoreData/RKEntityMapping.m +++ b/Code/CoreData/RKEntityMapping.m @@ -20,11 +20,11 @@ #import #import -#import #import -#import -#import +#import #import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/CoreData/RKFetchRequestManagedObjectCache.m b/Code/CoreData/RKFetchRequestManagedObjectCache.m index 5e370824ee..b4ac67a8d8 100644 --- a/Code/CoreData/RKFetchRequestManagedObjectCache.m +++ b/Code/CoreData/RKFetchRequestManagedObjectCache.m @@ -19,10 +19,10 @@ // #import -#import -#import #import #import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/CoreData/RKInMemoryManagedObjectCache.m b/Code/CoreData/RKInMemoryManagedObjectCache.m index 1655c432ee..d79537e867 100644 --- a/Code/CoreData/RKInMemoryManagedObjectCache.m +++ b/Code/CoreData/RKInMemoryManagedObjectCache.m @@ -18,10 +18,10 @@ // limitations under the License. // -#import +#import #import +#import #import -#import // Set Logging Component #undef RKLogComponent diff --git a/Code/CoreData/RKManagedObjectImporter.m b/Code/CoreData/RKManagedObjectImporter.m index c9c1cb88d2..5bd8af6bb4 100644 --- a/Code/CoreData/RKManagedObjectImporter.m +++ b/Code/CoreData/RKManagedObjectImporter.m @@ -22,14 +22,14 @@ #import #endif +#import +#import #import -#import #import -#import -#import +#import +#import #import #import -#import // Set Logging Component #undef RKLogComponent diff --git a/Code/CoreData/RKManagedObjectMappingOperationDataSource.m b/Code/CoreData/RKManagedObjectMappingOperationDataSource.m index d4b2699167..0e020f3521 100644 --- a/Code/CoreData/RKManagedObjectMappingOperationDataSource.m +++ b/Code/CoreData/RKManagedObjectMappingOperationDataSource.m @@ -18,21 +18,21 @@ // limitations under the License. // -#import -#import -#import +#import +#import #import -#import -#import -#import -#import #import +#import +#import #import #import -#import -#import +#import +#import +#import #import -#import +#import +#import +#import extern NSString * const RKObjectMappingNestingAttributeKeyName; diff --git a/Code/CoreData/RKManagedObjectStore.m b/Code/CoreData/RKManagedObjectStore.m index a5464714c6..d2d7655456 100644 --- a/Code/CoreData/RKManagedObjectStore.m +++ b/Code/CoreData/RKManagedObjectStore.m @@ -18,15 +18,15 @@ // limitations under the License. // -#import +#import +#import +#import #import -#import -#import #import +#import +#import #import -#import -#import -#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/CoreData/RKPropertyInspector+CoreData.m b/Code/CoreData/RKPropertyInspector+CoreData.m index a37c1c5cb3..cb9f1285f4 100644 --- a/Code/CoreData/RKPropertyInspector+CoreData.m +++ b/Code/CoreData/RKPropertyInspector+CoreData.m @@ -19,11 +19,11 @@ // #import -#import #import -#import #import +#import #import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/CoreData/RKRelationshipConnectionOperation.m b/Code/CoreData/RKRelationshipConnectionOperation.m index a7a3b7c39c..f5104cb372 100644 --- a/Code/CoreData/RKRelationshipConnectionOperation.m +++ b/Code/CoreData/RKRelationshipConnectionOperation.m @@ -19,14 +19,14 @@ // #import -#import #import #import -#import #import +#import #import -#import #import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/Network.h b/Code/Network.h index c2d2afc7b7..6cdaa758db 100644 --- a/Code/Network.h +++ b/Code/Network.h @@ -18,16 +18,16 @@ // limitations under the License. // +#import +#import +#import +#import +#import +#import #import #import #import -#import -#import -#import #import -#import -#import -#import #ifdef _COREDATADEFINES_H #import diff --git a/Code/Network/RKHTTPRequestOperation.m b/Code/Network/RKHTTPRequestOperation.m index 60f20337f1..ba7c3e31f6 100644 --- a/Code/Network/RKHTTPRequestOperation.m +++ b/Code/Network/RKHTTPRequestOperation.m @@ -18,10 +18,10 @@ // limitations under the License. // -#import -#import #import "lcl_RK.h" +#import #import +#import #import extern NSString * const RKErrorDomain; diff --git a/Code/Network/RKManagedObjectRequestOperation.h b/Code/Network/RKManagedObjectRequestOperation.h index 7f8d05e960..4c7e669da7 100644 --- a/Code/Network/RKManagedObjectRequestOperation.h +++ b/Code/Network/RKManagedObjectRequestOperation.h @@ -21,8 +21,8 @@ #ifdef _COREDATADEFINES_H #if __has_include("RKManagedObjectCaching.h") -#import #import +#import /** `RKManagedObjectRequestOperation` is a subclass of `RKObjectRequestOperation` that implements object mapping on the response body of an `NSHTTPResponse` loaded via an `RKHTTPRequestOperation` in which the mapping targets `NSManagedObject` objects managed by Core Data. diff --git a/Code/Network/RKManagedObjectRequestOperation.m b/Code/Network/RKManagedObjectRequestOperation.m index fb35980d48..dc01594a32 100644 --- a/Code/Network/RKManagedObjectRequestOperation.m +++ b/Code/Network/RKManagedObjectRequestOperation.m @@ -21,18 +21,18 @@ #ifdef _COREDATADEFINES_H #if __has_include("RKManagedObjectCaching.h") +#import +#import #import -#import -#import -#import #import -#import -#import +#import +#import #import +#import // Graph visitor -#import #import +#import #import #import diff --git a/Code/Network/RKObjectManager.h b/Code/Network/RKObjectManager.h index 450051946a..d343ef10cc 100644 --- a/Code/Network/RKObjectManager.h +++ b/Code/Network/RKObjectManager.h @@ -18,8 +18,8 @@ // limitations under the License. // -#import #import +#import #import #import diff --git a/Code/Network/RKObjectManager.m b/Code/Network/RKObjectManager.m index dc08014647..354d629a55 100644 --- a/Code/Network/RKObjectManager.m +++ b/Code/Network/RKObjectManager.m @@ -18,24 +18,24 @@ // limitations under the License. // -#import #import #import +#import +#import +#import #import #import +#import +#import +#import +#import +#import +#import #import -#import #import #import -#import -#import -#import -#import -#import -#import -#import -#import -#import +#import +#import #ifdef _COREDATADEFINES_H # if __has_include("RKCoreData.h") diff --git a/Code/Network/RKObjectParameterization.m b/Code/Network/RKObjectParameterization.m index b91a75203d..067c67a7dd 100644 --- a/Code/Network/RKObjectParameterization.m +++ b/Code/Network/RKObjectParameterization.m @@ -18,17 +18,17 @@ // limitations under the License. // -#import -#import +#import #import -#import -#import -#import -#import -#import #import +#import +#import +#import #import -#import +#import +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/Network/RKObjectRequestOperation.h b/Code/Network/RKObjectRequestOperation.h index 5fac34aa6a..89ad4edf16 100644 --- a/Code/Network/RKObjectRequestOperation.h +++ b/Code/Network/RKObjectRequestOperation.h @@ -19,8 +19,8 @@ // #import -#import #import +#import /** The key for a Boolean NSNumber value that indicates if a `NSCachedURLResponse` stored in the `NSURLCache` has been object mapped to completion. This key is stored on the `userInfo` of the cached response, if any, just before an `RKObjectRequestOperation` transitions to the finished state. diff --git a/Code/Network/RKObjectRequestOperation.m b/Code/Network/RKObjectRequestOperation.m index f6abe262c4..634a6e73df 100644 --- a/Code/Network/RKObjectRequestOperation.m +++ b/Code/Network/RKObjectRequestOperation.m @@ -18,15 +18,15 @@ // limitations under the License. // -#import #import -#import #import -#import +#import #import -#import #import +#import +#import #import +#import #import diff --git a/Code/Network/RKPaginator.h b/Code/Network/RKPaginator.h index ad906f24e3..f53b722f6f 100644 --- a/Code/Network/RKPaginator.h +++ b/Code/Network/RKPaginator.h @@ -20,8 +20,8 @@ #import #import -#import #import +#import @protocol RKManagedObjectCaching; diff --git a/Code/Network/RKPaginator.m b/Code/Network/RKPaginator.m index 69593416f5..86a4700138 100644 --- a/Code/Network/RKPaginator.m +++ b/Code/Network/RKPaginator.m @@ -19,11 +19,11 @@ // #import -#import -#import -#import #import #import +#import +#import +#import #ifdef _COREDATADEFINES_H #if __has_include("RKCoreData.h") diff --git a/Code/Network/RKPathMatcher.m b/Code/Network/RKPathMatcher.m index 258ad63922..d75b62d9e5 100644 --- a/Code/Network/RKPathMatcher.m +++ b/Code/Network/RKPathMatcher.m @@ -19,9 +19,9 @@ // #import -#import -#import #import +#import +#import static NSString *RKEncodeURLString(NSString *unencodedString); extern NSDictionary *RKQueryParametersFromStringWithEncoding(NSString *string, NSStringEncoding stringEncoding); diff --git a/Code/Network/RKRequestDescriptor.m b/Code/Network/RKRequestDescriptor.m index dc61bf7a73..b00c0b7ca8 100644 --- a/Code/Network/RKRequestDescriptor.m +++ b/Code/Network/RKRequestDescriptor.m @@ -22,8 +22,8 @@ // #import -#import #import +#import static void RKAssertValidMappingForRequestDescriptor(RKMapping *mapping) { diff --git a/Code/Network/RKResponseMapperOperation.h b/Code/Network/RKResponseMapperOperation.h index 8c61868f5e..b45fab4571 100644 --- a/Code/Network/RKResponseMapperOperation.h +++ b/Code/Network/RKResponseMapperOperation.h @@ -18,8 +18,8 @@ // limitations under the License. // -#import #import +#import #import #ifdef _COREDATADEFINES_H diff --git a/Code/Network/RKResponseMapperOperation.m b/Code/Network/RKResponseMapperOperation.m index fd9803b312..e8b057f35c 100644 --- a/Code/Network/RKResponseMapperOperation.m +++ b/Code/Network/RKResponseMapperOperation.m @@ -18,15 +18,15 @@ // limitations under the License. // -#import -#import -#import #import -#import +#import #import +#import #import -#import +#import #import +#import +#import #ifdef _COREDATADEFINES_H #if __has_include("RKCoreData.h") diff --git a/Code/Network/RKRouteSet.m b/Code/Network/RKRouteSet.m index 879c8a386d..dc4dcb7891 100644 --- a/Code/Network/RKRouteSet.m +++ b/Code/Network/RKRouteSet.m @@ -18,8 +18,8 @@ // limitations under the License. // -#import #import +#import @interface RKRouteSet () diff --git a/Code/Network/RKRouter.m b/Code/Network/RKRouter.m index fd0d4943d6..aff6a40193 100644 --- a/Code/Network/RKRouter.m +++ b/Code/Network/RKRouter.m @@ -18,10 +18,10 @@ // limitations under the License. // -#import -#import -#import #import +#import +#import +#import #import @interface RKRouter () diff --git a/Code/ObjectMapping.h b/Code/ObjectMapping.h index 07f85e24d5..f9c5325ffe 100644 --- a/Code/ObjectMapping.h +++ b/Code/ObjectMapping.h @@ -20,10 +20,10 @@ #import -#import #import -#import -#import -#import #import #import +#import +#import +#import +#import diff --git a/Code/ObjectMapping/RKMapperOperation.h b/Code/ObjectMapping/RKMapperOperation.h index 0c25ca01e7..ac9bbd3dda 100644 --- a/Code/ObjectMapping/RKMapperOperation.h +++ b/Code/ObjectMapping/RKMapperOperation.h @@ -19,10 +19,10 @@ // #import -#import #import -#import #import +#import +#import #import @protocol RKMapperOperationDelegate; diff --git a/Code/ObjectMapping/RKMapperOperation.m b/Code/ObjectMapping/RKMapperOperation.m index 3df1fde23c..b4ebb8225d 100644 --- a/Code/ObjectMapping/RKMapperOperation.m +++ b/Code/ObjectMapping/RKMapperOperation.m @@ -18,14 +18,14 @@ // limitations under the License. // +#import #import #import +#import #import #import -#import -#import -#import #import +#import NSString * const RKMappingErrorKeyPathErrorKey = @"keyPath"; diff --git a/Code/ObjectMapping/RKMappingOperation.h b/Code/ObjectMapping/RKMappingOperation.h index 886c4a6b4c..a59cd9882d 100644 --- a/Code/ObjectMapping/RKMappingOperation.h +++ b/Code/ObjectMapping/RKMappingOperation.h @@ -18,8 +18,8 @@ // limitations under the License. // -#import #import +#import @class RKMappingOperation, RKDynamicMapping, RKConnectionDescription, RKMappingInfo; @protocol RKMappingOperationDataSource; diff --git a/Code/ObjectMapping/RKMappingOperation.m b/Code/ObjectMapping/RKMappingOperation.m index 7b82cc907c..d054166d98 100644 --- a/Code/ObjectMapping/RKMappingOperation.m +++ b/Code/ObjectMapping/RKMappingOperation.m @@ -18,20 +18,20 @@ // limitations under the License. // -#import -#import -#import -#import +#import #import -#import -#import -#import +#import +#import +#import #import #import -#import #import -#import +#import +#import #import +#import +#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/ObjectMapping/RKObjectMapping.h b/Code/ObjectMapping/RKObjectMapping.h index 6482d869ac..d77e61fb7c 100644 --- a/Code/ObjectMapping/RKObjectMapping.h +++ b/Code/ObjectMapping/RKObjectMapping.h @@ -18,8 +18,8 @@ // limitations under the License. // -#import #import +#import #import diff --git a/Code/ObjectMapping/RKObjectMapping.m b/Code/ObjectMapping/RKObjectMapping.m index daaa8c58c4..f28eeb39a3 100644 --- a/Code/ObjectMapping/RKObjectMapping.m +++ b/Code/ObjectMapping/RKObjectMapping.m @@ -19,14 +19,13 @@ // #import +#import +#import +#import #import -#import #import -#import -#import #import -#import -#import +#import typedef NSString * (^RKSourceToDesinationKeyTransformationBlock)(RKObjectMapping *, NSString *); diff --git a/Code/ObjectMapping/RKObjectMappingOperationDataSource.m b/Code/ObjectMapping/RKObjectMappingOperationDataSource.m index 5634df8f4c..01c6304ed4 100644 --- a/Code/ObjectMapping/RKObjectMappingOperationDataSource.m +++ b/Code/ObjectMapping/RKObjectMappingOperationDataSource.m @@ -18,9 +18,9 @@ // limitations under the License. // -#import -#import #import +#import +#import @implementation RKObjectMappingOperationDataSource diff --git a/Code/ObjectMapping/RKObjectUtilities.m b/Code/ObjectMapping/RKObjectUtilities.m index 1324607c94..65a5712965 100644 --- a/Code/ObjectMapping/RKObjectUtilities.m +++ b/Code/ObjectMapping/RKObjectUtilities.m @@ -18,9 +18,9 @@ // limitations under the License. // +#import #import #import -#import BOOL RKObjectIsEqualToObject(id object, id anotherObject) { NSCAssert(object, @"Expected object not to be nil"); diff --git a/Code/ObjectMapping/RKPropertyInspector.m b/Code/ObjectMapping/RKPropertyInspector.m index 0ea3dd51db..3ee197d169 100644 --- a/Code/ObjectMapping/RKPropertyInspector.m +++ b/Code/ObjectMapping/RKPropertyInspector.m @@ -18,10 +18,10 @@ // limitations under the License. // -#import +#import #import #import -#import +#import // Set Logging Component #undef RKLogComponent diff --git a/Code/ObjectMapping/RKPropertyMapping.m b/Code/ObjectMapping/RKPropertyMapping.m index f2d6c7d905..5002c8667e 100644 --- a/Code/ObjectMapping/RKPropertyMapping.m +++ b/Code/ObjectMapping/RKPropertyMapping.m @@ -18,8 +18,8 @@ // limitations under the License. // -#import #import +#import /** For consistency with URI Templates (and most web templating languages in general) we are transitioning diff --git a/Code/ObjectMapping/RKRelationshipMapping.m b/Code/ObjectMapping/RKRelationshipMapping.m index 962d5e45e2..fc407131a4 100644 --- a/Code/ObjectMapping/RKRelationshipMapping.m +++ b/Code/ObjectMapping/RKRelationshipMapping.m @@ -18,8 +18,8 @@ // limitations under the License. // -#import #import +#import @interface RKPropertyMapping () @property (nonatomic, copy, readwrite) NSString *sourceKeyPath; diff --git a/Code/Search.h b/Code/Search.h index 3883199370..d1a5510ceb 100644 --- a/Code/Search.h +++ b/Code/Search.h @@ -21,6 +21,6 @@ #import #ifdef _COREDATADEFINES_H -#import #import +#import #endif diff --git a/Code/Search/RKManagedObjectStore+RKSearchAdditions.m b/Code/Search/RKManagedObjectStore+RKSearchAdditions.m index 06f7bedf87..c455218a39 100644 --- a/Code/Search/RKManagedObjectStore+RKSearchAdditions.m +++ b/Code/Search/RKManagedObjectStore+RKSearchAdditions.m @@ -18,9 +18,9 @@ // limitations under the License. // -#import #import #import +#import static char searchIndexerAssociationKey; diff --git a/Code/Search/RKSearchIndexer.m b/Code/Search/RKSearchIndexer.m index 6fd39d8bb7..be86fcd537 100644 --- a/Code/Search/RKSearchIndexer.m +++ b/Code/Search/RKSearchIndexer.m @@ -18,13 +18,13 @@ // limitations under the License. // +#import +#import #import -#import #import +#import #import #import -#import -#import // Set Logging Component #undef RKLogComponent diff --git a/Code/Support.h b/Code/Support.h index 2eb539a27e..f901886bd9 100644 --- a/Code/Support.h +++ b/Code/Support.h @@ -19,13 +19,13 @@ // // Load shared support code +#import +#import #import -#import #import -#import -#import -#import -#import -#import #import +#import +#import +#import #import +#import diff --git a/Code/Support/RKMIMETypeSerialization.m b/Code/Support/RKMIMETypeSerialization.m index ba9fbe53e7..931b4e6133 100644 --- a/Code/Support/RKMIMETypeSerialization.m +++ b/Code/Support/RKMIMETypeSerialization.m @@ -18,12 +18,12 @@ // limitations under the License. // -#import #import -#import #import -#import +#import #import +#import +#import // Define logging component #undef RKLogComponent diff --git a/Code/Support/RKOperationStateMachine.m b/Code/Support/RKOperationStateMachine.m index 967de0f2d6..b090f3690d 100644 --- a/Code/Support/RKOperationStateMachine.m +++ b/Code/Support/RKOperationStateMachine.m @@ -18,8 +18,8 @@ // limitations under the License. // -#import #import +#import NSString *const RKOperationFailureException = @"RKOperationFailureException"; diff --git a/Code/Support/RKPathUtilities.m b/Code/Support/RKPathUtilities.m index b7757e175a..12ee04786d 100644 --- a/Code/Support/RKPathUtilities.m +++ b/Code/Support/RKPathUtilities.m @@ -13,9 +13,9 @@ #import #endif #import -#import -#import #import +#import +#import NSString *RKExecutableName(void); diff --git a/Code/Testing.h b/Code/Testing.h index b81708cff2..844762d2c6 100644 --- a/Code/Testing.h +++ b/Code/Testing.h @@ -19,11 +19,11 @@ // -#import -#import +#import #import +#import #import -#import +#import #ifdef _COREDATADEFINES_H #import diff --git a/Code/Testing/RKConnectionTestExpectation.m b/Code/Testing/RKConnectionTestExpectation.m index 42dbfc34ce..64a3e7471f 100644 --- a/Code/Testing/RKConnectionTestExpectation.m +++ b/Code/Testing/RKConnectionTestExpectation.m @@ -20,8 +20,8 @@ #ifdef _COREDATADEFINES_H -#import #import +#import @interface RKConnectionTestExpectation () @property (nonatomic, copy, readwrite) NSString *relationshipName; diff --git a/Code/Testing/RKMappingTest.m b/Code/Testing/RKMappingTest.m index 587fd6e944..65a666dfad 100644 --- a/Code/Testing/RKMappingTest.m +++ b/Code/Testing/RKMappingTest.m @@ -18,22 +18,22 @@ // limitations under the License. // -#import #import +#import #import #import -#import #import +#import // Core Data #ifdef _COREDATADEFINES_H #if __has_include("RKCoreData.h") #define RKCoreDataIncluded -#import #import -#import +#import #import #import +#import #endif #endif diff --git a/Code/Testing/RKPropertyMappingTestExpectation.m b/Code/Testing/RKPropertyMappingTestExpectation.m index 86f796d6ef..342cb40a5b 100644 --- a/Code/Testing/RKPropertyMappingTestExpectation.m +++ b/Code/Testing/RKPropertyMappingTestExpectation.m @@ -18,8 +18,8 @@ // limitations under the License. // -#import #import +#import @interface RKPropertyMappingTestExpectation () @property (nonatomic, copy, readwrite) NSString *sourceKeyPath; diff --git a/Code/Testing/RKTestFactory.m b/Code/Testing/RKTestFactory.m index 533df090f0..7fe0d01062 100644 --- a/Code/Testing/RKTestFactory.m +++ b/Code/Testing/RKTestFactory.m @@ -19,12 +19,12 @@ // #import "AFHTTPClient.h" -#import -#import #import -#import -#import #import +#import +#import +#import +#import #ifdef _COREDATADEFINES_H #if __has_include("RKCoreData.h") diff --git a/Code/Testing/RKTestFixture.m b/Code/Testing/RKTestFixture.m index c2bc6262eb..53f44bc0ad 100644 --- a/Code/Testing/RKTestFixture.m +++ b/Code/Testing/RKTestFixture.m @@ -18,10 +18,10 @@ // limitations under the License. // -#import #import -#import #import +#import +#import static NSBundle *fixtureBundle = nil; diff --git a/Code/Testing/RKTestHelpers.m b/Code/Testing/RKTestHelpers.m index f30d5bd3e3..5f1957e4d1 100644 --- a/Code/Testing/RKTestHelpers.m +++ b/Code/Testing/RKTestHelpers.m @@ -18,13 +18,13 @@ // limitations under the License. // -#import +#import "SOCKit.h" #import #import -#import -#import -#import "SOCKit.h" #import +#import +#import +#import #ifdef _COREDATADEFINES_H #if __has_include("RKCoreData.h") From 4c71591c721d2b1b34b17d80a7f51b99e3643300 Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Sat, 24 Oct 2015 14:49:10 -0500 Subject: [PATCH 80/94] [Gemfile] Point to CocoaPods branch --- Gemfile | 2 +- Gemfile.lock | 30 ++++++++++++++++++------------ 2 files changed, 19 insertions(+), 13 deletions(-) diff --git a/Gemfile b/Gemfile index a5b2ace934..33a7688380 100644 --- a/Gemfile +++ b/Gemfile @@ -4,6 +4,6 @@ gem 'rakeup', '~> 1.2.0' gem 'sinatra', '~> 1.4.0' gem 'sinatra-contrib', '~> 1.4.0' gem 'thin', '~> 1.5.0' -gem 'cocoapods', '~> 0.39.0' +gem 'cocoapods', github: 'CocoaPods/CocoaPods', branch: 'seg-frameworks-nested-headers' gem 'xctasks', '~> 0.5.0' gem 'xcpretty', '~> 0.1.6' diff --git a/Gemfile.lock b/Gemfile.lock index 529299f8ba..80cd0c5a33 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,14 +1,8 @@ -GEM - remote: https://rubygems.org/ +GIT + remote: git://github.com/CocoaPods/CocoaPods.git + revision: 0370e99b04d7be7128a2fb32a2f785123d7ff6f9 + branch: seg-frameworks-nested-headers specs: - activesupport (4.2.4) - i18n (~> 0.7) - json (~> 1.7, >= 1.7.7) - minitest (~> 5.1) - thread_safe (~> 0.3, >= 0.3.4) - tzinfo (~> 1.1) - backports (3.6.5) - claide (0.9.1) cocoapods (0.39.0) activesupport (>= 4.0.2) claide (~> 0.9.1) @@ -24,6 +18,18 @@ GEM molinillo (~> 0.4.0) nap (~> 1.0) xcodeproj (~> 0.28.2) + +GEM + remote: https://rubygems.org/ + specs: + activesupport (4.2.4) + i18n (~> 0.7) + json (~> 1.7, >= 1.7.7) + minitest (~> 5.1) + thread_safe (~> 0.3, >= 0.3.4) + tzinfo (~> 1.1) + backports (3.6.5) + claide (0.9.1) cocoapods-core (0.39.0) activesupport (>= 4.0.2) fuzzy_match (~> 2.0.4) @@ -84,7 +90,7 @@ GEM activesupport (>= 3) claide (~> 0.9.1) colored (~> 1.2) - xcpretty (0.1.10) + xcpretty (0.1.12) xctasks (0.5.0) nokogiri (~> 1.6, >= 1.6.3.1) rake (~> 10.0, >= 10.0.0) @@ -93,7 +99,7 @@ PLATFORMS ruby DEPENDENCIES - cocoapods (~> 0.39.0) + cocoapods! rakeup (~> 1.2.0) sinatra (~> 1.4.0) sinatra-contrib (~> 1.4.0) From 3521dec21f5e76fed27de10398a1a56ab7b7570f Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Sat, 24 Oct 2015 14:49:22 -0500 Subject: [PATCH 81/94] [Rakefile] Autostart server for ci task --- Rakefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Rakefile b/Rakefile index 82a4530c73..01c617cf96 100644 --- a/Rakefile +++ b/Rakefile @@ -169,7 +169,7 @@ task :lint do end desc 'Runs the CI suite' -task :ci => ['server:start', :test, 'test:building_without_core_data', :lint] +task :ci => ['server:autostart', :test, 'test:building_without_core_data', :lint] def title(title) cyan_title = "\033[0;36m#{title}\033[0m" From cf7c34b2e5bddf155295ba0f0023a6496bbee779 Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Sat, 24 Oct 2015 14:50:15 -0500 Subject: [PATCH 82/94] Ensure all headers are inside the header mapping dir --- Code/CocoaLumberjack/RKLumberjackLogger.m | 6 +++--- Code/Network/RKHTTPRequestOperation.m | 6 +++--- Code/Support/RKLog.h | 2 +- Code/Support/lcl_RK.h | 1 + Code/Support/lcl_RK.m | 1 + Code/Testing/RKTestFactory.m | 4 ++-- Code/Testing/RKTestHelpers.m | 18 +++++++++--------- .../RKSearchExample/RKSAppDelegate.h | 2 +- .../Classes/RKTwitterViewController.h | 2 +- RestKit.podspec | 3 ++- Vendor/LibComponentLogging/Core/lcl_RK.h | 9 ++++----- Vendor/LibComponentLogging/Core/lcl_RK.m | 13 ++++++------- 12 files changed, 34 insertions(+), 33 deletions(-) create mode 120000 Code/Support/lcl_RK.h create mode 120000 Code/Support/lcl_RK.m diff --git a/Code/CocoaLumberjack/RKLumberjackLogger.m b/Code/CocoaLumberjack/RKLumberjackLogger.m index 0e2828f2e4..18dd1356cb 100644 --- a/Code/CocoaLumberjack/RKLumberjackLogger.m +++ b/Code/CocoaLumberjack/RKLumberjackLogger.m @@ -24,7 +24,7 @@ + (DDLogLevel)ddLogLevelFromRKLogLevel:(_RKlcl_level_t)rkLevel case RKLogLevelDebug: return DDLogLevelDebug; case RKLogLevelTrace: return DDLogLevelVerbose; } - + return DDLogLevelDebug; } @@ -40,7 +40,7 @@ + (DDLogFlag)ddLogFlagFromRKLogLevel:(_RKlcl_level_t)rkLevel case RKLogLevelDebug: return DDLogFlagDebug; case RKLogLevelTrace: return DDLogFlagVerbose; } - + return DDLogFlagDebug; } @@ -51,7 +51,7 @@ + (_RKlcl_level_t)rkLogLevelFromDDLogLevel:(DDLogLevel)ddLogLevel if (ddLogLevel & DDLogFlagInfo) return RKLogLevelInfo; if (ddLogLevel & DDLogFlagWarning) return RKLogLevelWarning; if (ddLogLevel & DDLogFlagError) return RKLogLevelError; - + return RKLogLevelOff; } diff --git a/Code/Network/RKHTTPRequestOperation.m b/Code/Network/RKHTTPRequestOperation.m index ba7c3e31f6..69c1d6cd3b 100644 --- a/Code/Network/RKHTTPRequestOperation.m +++ b/Code/Network/RKHTTPRequestOperation.m @@ -18,11 +18,11 @@ // limitations under the License. // -#import "lcl_RK.h" #import #import #import #import +#import extern NSString * const RKErrorDomain; @@ -92,7 +92,7 @@ - (NSError *)error [userInfo setValue:[self.request URL] forKey:NSURLErrorFailingURLErrorKey]; [userInfo setValue:self.request forKey:AFNetworkingOperationFailingURLRequestErrorKey]; [userInfo setValue:self.response forKey:AFNetworkingOperationFailingURLResponseErrorKey]; - + if (![self hasAcceptableStatusCode]) { NSUInteger statusCode = ([self.response isKindOfClass:[NSHTTPURLResponse class]]) ? (NSUInteger)[self.response statusCode] : 200; [userInfo setValue:[NSString stringWithFormat:NSLocalizedString(@"Expected status code in (%@), got %d", nil), RKStringFromIndexSet(self.acceptableStatusCodes ?: [NSMutableIndexSet indexSet]), statusCode] forKey:NSLocalizedDescriptionKey]; @@ -104,7 +104,7 @@ - (NSError *)error } } } - + NSError *error = self.rkHTTPError ?: [super error]; [self.lock unlock]; return error; diff --git a/Code/Support/RKLog.h b/Code/Support/RKLog.h index da5de948f3..fc26861274 100644 --- a/Code/Support/RKLog.h +++ b/Code/Support/RKLog.h @@ -24,7 +24,7 @@ @see lcl_config_components_RK.h @see lcl_config_logger_RK.h */ -#import "lcl_RK.h" +#import /** * Protocol which classes can implement to determine how RestKit log messages actually get handled. diff --git a/Code/Support/lcl_RK.h b/Code/Support/lcl_RK.h new file mode 120000 index 0000000000..d33d5de37f --- /dev/null +++ b/Code/Support/lcl_RK.h @@ -0,0 +1 @@ +../../Vendor/LibComponentLogging/Core/lcl_RK.h \ No newline at end of file diff --git a/Code/Support/lcl_RK.m b/Code/Support/lcl_RK.m new file mode 120000 index 0000000000..23c8a00edf --- /dev/null +++ b/Code/Support/lcl_RK.m @@ -0,0 +1 @@ +../../Vendor/LibComponentLogging/Core/lcl_RK.m \ No newline at end of file diff --git a/Code/Testing/RKTestFactory.m b/Code/Testing/RKTestFactory.m index 7fe0d01062..0b96883265 100644 --- a/Code/Testing/RKTestFactory.m +++ b/Code/Testing/RKTestFactory.m @@ -18,7 +18,7 @@ // limitations under the License. // -#import "AFHTTPClient.h" +#import #import #import #import @@ -277,7 +277,7 @@ + (void)tearDown #ifdef RKCoreDataIncluded // Ensure the existing defaultStore is shut down [[NSNotificationCenter defaultCenter] removeObserver:[RKManagedObjectStore defaultStore]]; - + #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wundeclared-selector" if ([[RKManagedObjectStore defaultStore] respondsToSelector:@selector(stopIndexingPersistentStoreManagedObjectContext)]) { diff --git a/Code/Testing/RKTestHelpers.m b/Code/Testing/RKTestHelpers.m index 5f1957e4d1..daf7c58e29 100644 --- a/Code/Testing/RKTestHelpers.m +++ b/Code/Testing/RKTestHelpers.m @@ -18,13 +18,13 @@ // limitations under the License. // -#import "SOCKit.h" #import #import #import #import #import #import +#import #ifdef _COREDATADEFINES_H #if __has_include("RKCoreData.h") @@ -80,7 +80,7 @@ + (void)copyFetchRequestBlocksMatchingPathPattern:(NSString *)pathPattern onObjectManager:(RKObjectManager *)nilOrObjectManager { RKObjectManager *objectManager = nilOrObjectManager ?: [RKObjectManager sharedManager]; - + // Extract the dynamic portions of the path pattern to construct a set of parameters SOCPattern *pattern = [SOCPattern patternWithString:pathPattern]; NSArray *parameterNames = [pattern valueForKeyPath:@"parameters.string"]; @@ -89,7 +89,7 @@ + (void)copyFetchRequestBlocksMatchingPathPattern:(NSString *)pathPattern [stubbedParameters setValue:@"value" forKey:parameter]; } NSString *stubbedPathPattern = [pattern stringFromObject:stubbedParameters]; - + NSURL *URL = [NSURL URLWithString:stubbedPathPattern relativeToURL:objectManager.HTTPClient.baseURL]; NSAssert(URL, @"Failed to build URL from path pattern '%@' relative to base URL '%@'", pathPattern, objectManager.HTTPClient.baseURL); for (RKFetchRequestBlock block in objectManager.fetchRequestBlocks) { @@ -102,10 +102,10 @@ + (void)copyFetchRequestBlocksMatchingPathPattern:(NSString *)pathPattern if ([[URL path] isEqualToString:relativeString]) { return fetchRequest; } - + return nil; }]; - + break; } } @@ -122,16 +122,16 @@ + (NSCachedURLResponse *)cacheResponseForRequest:(NSURLRequest *)request withRes { NSParameterAssert(request); NSParameterAssert(responseData); - + NSHTTPURLResponse *response = [[NSHTTPURLResponse alloc] initWithURL:[request URL] statusCode:200 HTTPVersion:@"1.1" headerFields:nil]; NSAssert(response, @"Failed to build cached response"); NSCachedURLResponse *cachedResponse = [[NSCachedURLResponse alloc] initWithResponse:response data:responseData]; [[NSURLCache sharedURLCache] storeCachedResponse:cachedResponse forRequest:request]; - + // Verify that we can get the cached response back NSCachedURLResponse *__unused storedResponse = [[NSURLCache sharedURLCache] cachedResponseForRequest:request]; NSAssert(storedResponse, @"Expected to retrieve cached response for request '%@', instead got nil.", request); - + return cachedResponse; } @@ -140,7 +140,7 @@ + (NSCachedURLResponse *)cacheResponseForURL:(NSURL *)URL HTTPMethod:(NSString * NSParameterAssert(URL); NSParameterAssert(HTTPMethod); NSParameterAssert(responseData); - + NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:URL]; request.HTTPMethod = HTTPMethod; [request setAllHTTPHeaderFields:requestHeaders]; diff --git a/Examples/RKSearchExample/RKSearchExample/RKSAppDelegate.h b/Examples/RKSearchExample/RKSearchExample/RKSAppDelegate.h index aa9dcd696d..5bfbead775 100644 --- a/Examples/RKSearchExample/RKSearchExample/RKSAppDelegate.h +++ b/Examples/RKSearchExample/RKSearchExample/RKSAppDelegate.h @@ -6,8 +6,8 @@ // Copyright (c) 2012 Blake Watters. All rights reserved. // -#import #import +#import @interface RKSAppDelegate : UIResponder diff --git a/Examples/RKTwitter/Classes/RKTwitterViewController.h b/Examples/RKTwitter/Classes/RKTwitterViewController.h index 64fa598104..1a8e2cf732 100644 --- a/Examples/RKTwitter/Classes/RKTwitterViewController.h +++ b/Examples/RKTwitter/Classes/RKTwitterViewController.h @@ -6,8 +6,8 @@ // Copyright (c) 2009-2012 RestKit. All rights reserved. // -#import #import +#import @interface RKTwitterViewController : UIViewController { UITableView *_tableView; diff --git a/RestKit.podspec b/RestKit.podspec index a07930d31c..c81ffa42de 100644 --- a/RestKit.podspec +++ b/RestKit.podspec @@ -99,7 +99,8 @@ EOS end s.subspec 'Support' do |ss| - ss.source_files = 'Code/RestKit.h', 'Code/Support.h', 'Code/Support', 'Vendor/LibComponentLogging/Core' + ss.source_files = 'Code/RestKit.h', 'Code/Support.h', 'Code/Support' + ss.preserve_paths = 'Vendor/LibComponentLogging/Core' # Preserved because they are symlinked ss.dependency 'TransitionKit', '~> 2.2' end diff --git a/Vendor/LibComponentLogging/Core/lcl_RK.h b/Vendor/LibComponentLogging/Core/lcl_RK.h index 25ff99dcb7..63785eb9e1 100644 --- a/Vendor/LibComponentLogging/Core/lcl_RK.h +++ b/Vendor/LibComponentLogging/Core/lcl_RK.h @@ -31,7 +31,7 @@ #define _RKLCL_VERSION_BUILD 1 #define _RKLCL_VERSION_SUFFIX "" -#import "lcl_config_components_RK.h" +#import // // lcl -- LibComponentLogging, embedded, RestKit/RK @@ -112,7 +112,7 @@ enum _RKlcl_enum_level_t { RKlcl_vInfo, // informational message RKlcl_vDebug, // coarse-grained debugging information RKlcl_vTrace, // fine-grained debugging information - + _RKlcl_level_t_count, _RKlcl_level_t_first = 0, _RKlcl_level_t_last = _RKlcl_level_t_count-1 @@ -324,7 +324,7 @@ enum { // Include logging back-end and definition of _RKlcl_logger. -#import "lcl_config_logger_RK.h" +#import // For simple configurations where 'lcl_config_logger_RK.h' is empty, define a @@ -383,8 +383,7 @@ enum { // Include extensions. -#import "lcl_config_extensions_RK.h" +#import #endif // __RKLCL_H__ - diff --git a/Vendor/LibComponentLogging/Core/lcl_RK.m b/Vendor/LibComponentLogging/Core/lcl_RK.m index c8602967fb..847c34b1f8 100644 --- a/Vendor/LibComponentLogging/Core/lcl_RK.m +++ b/Vendor/LibComponentLogging/Core/lcl_RK.m @@ -23,7 +23,7 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. -#import "lcl_RK.h" +#import #include @@ -97,7 +97,7 @@ // Version. #define __RKlcl_version_to_string( _text) __RKlcl_version_to_string0(_text) #define __RKlcl_version_to_string0(_text) #_text -const char * const _RKlcl_version = __RKlcl_version_to_string(_RKLCL_VERSION_MAJOR) +const char * const _RKlcl_version = __RKlcl_version_to_string(_RKLCL_VERSION_MAJOR) "." __RKlcl_version_to_string(_RKLCL_VERSION_MINOR) "." __RKlcl_version_to_string(_RKLCL_VERSION_BUILD) "" _RKLCL_VERSION_SUFFIX; @@ -108,13 +108,13 @@ uint32_t RKlcl_configure_by_component(_RKlcl_component_t component, _RKlcl_level if (level > _RKlcl_level_t_last) { level = _RKlcl_level_t_last; } - + // configure the component if (component <= _RKlcl_component_t_last) { _RKlcl_component_level[component] = level; return 1; } - + return 0; } @@ -126,12 +126,12 @@ static uint32_t _RKlcl_configure_by_text(uint32_t count, const char * const *tex if (text == NULL || text[0] == '\0') { return 0; } - + // unsupported level, clip to last level if (level > _RKlcl_level_t_last) { level = _RKlcl_level_t_last; } - + // configure the components uint32_t num_configured = 0; size_t text_len = strlen(text); @@ -173,4 +173,3 @@ uint32_t RKlcl_configure_by_name(const char *name, _RKlcl_level_t level) { return _RKlcl_configure_by_text(_RKlcl_component_t_count, _RKlcl_component_name, _RKlcl_component_level, name, level); } - From da7d8b7a970079fea9f11d66ebdc387769d02c23 Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Sun, 1 Nov 2015 12:27:08 -0600 Subject: [PATCH 83/94] [Gemfile] Point to CocoaPods master --- Gemfile | 5 ++++- Gemfile.lock | 35 +++++++++++++++++++++++------------ Podfile.lock | 4 +++- 3 files changed, 30 insertions(+), 14 deletions(-) diff --git a/Gemfile b/Gemfile index 33a7688380..1756b7e756 100644 --- a/Gemfile +++ b/Gemfile @@ -4,6 +4,9 @@ gem 'rakeup', '~> 1.2.0' gem 'sinatra', '~> 1.4.0' gem 'sinatra-contrib', '~> 1.4.0' gem 'thin', '~> 1.5.0' -gem 'cocoapods', github: 'CocoaPods/CocoaPods', branch: 'seg-frameworks-nested-headers' gem 'xctasks', '~> 0.5.0' gem 'xcpretty', '~> 0.1.6' + +gem 'cocoapods', git: 'https://github.com/CocoaPods/CocoaPods' +gem 'cocoapods-core', git: 'https://github.com/CocoaPods/Core' +gem 'xcodeproj', git: 'https://github.com/CocoaPods/Xcodeproj' diff --git a/Gemfile.lock b/Gemfile.lock index 80cd0c5a33..4474b859ad 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,7 +1,6 @@ GIT - remote: git://github.com/CocoaPods/CocoaPods.git - revision: 0370e99b04d7be7128a2fb32a2f785123d7ff6f9 - branch: seg-frameworks-nested-headers + remote: https://github.com/CocoaPods/CocoaPods + revision: 6923c9784460f9cac5d51bebb90344c55d8a2ab7 specs: cocoapods (0.39.0) activesupport (>= 4.0.2) @@ -19,6 +18,24 @@ GIT nap (~> 1.0) xcodeproj (~> 0.28.2) +GIT + remote: https://github.com/CocoaPods/Core + revision: 6f85c4fcff81960c0983616082bc345763a15dc6 + specs: + cocoapods-core (0.39.0) + activesupport (>= 4.0.2) + fuzzy_match (~> 2.0.4) + nap (~> 1.0) + +GIT + remote: https://github.com/CocoaPods/Xcodeproj + revision: 7a3d0c6520d995353b7ec09c4585aebf43e6c613 + specs: + xcodeproj (0.28.2) + activesupport (>= 3) + claide (~> 0.9.1) + colored (~> 1.2) + GEM remote: https://rubygems.org/ specs: @@ -30,10 +47,6 @@ GEM tzinfo (~> 1.1) backports (3.6.5) claide (0.9.1) - cocoapods-core (0.39.0) - activesupport (>= 4.0.2) - fuzzy_match (~> 2.0.4) - nap (~> 1.0) cocoapods-downloader (0.9.3) cocoapods-plugins (0.4.2) nap @@ -51,7 +64,7 @@ GEM i18n (0.7.0) json (1.8.3) mini_portile (0.6.2) - minitest (5.8.1) + minitest (5.8.2) molinillo (0.4.0) multi_json (1.11.2) nap (1.0.0) @@ -86,10 +99,6 @@ GEM tilt (2.0.1) tzinfo (1.2.2) thread_safe (~> 0.1) - xcodeproj (0.28.2) - activesupport (>= 3) - claide (~> 0.9.1) - colored (~> 1.2) xcpretty (0.1.12) xctasks (0.5.0) nokogiri (~> 1.6, >= 1.6.3.1) @@ -100,10 +109,12 @@ PLATFORMS DEPENDENCIES cocoapods! + cocoapods-core! rakeup (~> 1.2.0) sinatra (~> 1.4.0) sinatra-contrib (~> 1.4.0) thin (~> 1.5.0) + xcodeproj! xcpretty (~> 0.1.6) xctasks (~> 0.5.0) diff --git a/Podfile.lock b/Podfile.lock index fdbaa5dbed..db8b94aded 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -70,11 +70,13 @@ SPEC CHECKSUMS: ISO8601DateFormatterValueTransformer: 52da467d6ec899d6aedda8e48280ac92e8ee97e6 OCHamcrest: e19857683e4eefab64b878668eac04c2f4567118 OCMock: a6a7dc0e3997fb9f35d99f72528698ebf60d64f2 - RestKit: 6a1ceadec4fb2bfdffbcbe60b706d37444679e5b + RestKit: 4149b1e118cb8e16a6e268d9ae53bc7465268813 RKCLLocationValueTransformer: 2cf0ea0fb7cd4bc70c56834fb92abc717c66f982 RKValueTransformers: 66ac5e4f077fdbe3496e792d89eeff4c3eb67701 SOCKit: c7376ac262bea9115b8f749358f762522a47d392 Specta: 15a276a6343867b426d5ed135d5aa4d04123a573 TransitionKit: 9ceccda4cd0cdc0a05ef85eb235e5a3292c3c250 +PODFILE CHECKSUM: 8e16e876b7a816e2b58525f31c6e1a9085616065 + COCOAPODS: 0.39.0 From 35446c732192cb9f70fabc841e0e671f84c40e99 Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Thu, 12 Nov 2015 12:22:24 -0600 Subject: [PATCH 84/94] Fix import path for lumberjack --- Code/CocoaLumberjack/RKLumberjackLogger.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/CocoaLumberjack/RKLumberjackLogger.m b/Code/CocoaLumberjack/RKLumberjackLogger.m index 18dd1356cb..5e349a2daa 100644 --- a/Code/CocoaLumberjack/RKLumberjackLogger.m +++ b/Code/CocoaLumberjack/RKLumberjackLogger.m @@ -8,7 +8,7 @@ #if __has_include() #import -#import +#import @implementation RKLumberjackLogger From 1ba6e0eb76bb2393bd93384e29cf90b553a1b40c Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Thu, 12 Nov 2015 12:44:30 -0600 Subject: [PATCH 85/94] [Rakefile] Allow warnings when linting pod --- Rakefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Rakefile b/Rakefile index 01c617cf96..4603f59e7b 100644 --- a/Rakefile +++ b/Rakefile @@ -164,8 +164,8 @@ end task :lint do title 'Linting pod' - run('bundle exec pod lib lint') - run('bundle exec pod lib lint --use-libraries') + run('bundle exec pod lib lint --allow-warnings ') + run('bundle exec pod lib lint --allow-warnings --use-libraries') end desc 'Runs the CI suite' From f28e429585fe867587b5c986e2bf2c5fad316a36 Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Thu, 12 Nov 2015 13:00:45 -0600 Subject: [PATCH 86/94] Add CocoaLumberjack to podfile --- Podfile | 3 ++- Podfile.lock | 6 +++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/Podfile b/Podfile index 2277a10625..574faf356d 100644 --- a/Podfile +++ b/Podfile @@ -14,8 +14,9 @@ end def import_pods pod 'RestKit', :path => '.' - pod 'RestKit/Testing', :path => '.' + pod 'RestKit/CocoaLumberjack', :path => '.' pod 'RestKit/Search', :path => '.' + pod 'RestKit/Testing', :path => '.' pod 'Specta', '0.2.1' pod 'OCMock', '2.2.4' diff --git a/Podfile.lock b/Podfile.lock index db8b94aded..a39081b79b 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -15,6 +15,9 @@ PODS: - OCMock (2.2.4) - RestKit (0.25.0): - RestKit/Core (= 0.25.0) + - RestKit/CocoaLumberjack (0.25.0): + - CocoaLumberjack + - RestKit/Support - RestKit/Core (0.25.0): - RestKit/CoreData - RestKit/Network @@ -51,6 +54,7 @@ DEPENDENCIES: - OCHamcrest (= 3.0.1) - OCMock (= 2.2.4) - RestKit (from `.`) + - RestKit/CocoaLumberjack (from `.`) - RestKit/Search (from `.`) - RestKit/Testing (from `.`) - RKCLLocationValueTransformer (~> 1.1.0) @@ -77,6 +81,6 @@ SPEC CHECKSUMS: Specta: 15a276a6343867b426d5ed135d5aa4d04123a573 TransitionKit: 9ceccda4cd0cdc0a05ef85eb235e5a3292c3c250 -PODFILE CHECKSUM: 8e16e876b7a816e2b58525f31c6e1a9085616065 +PODFILE CHECKSUM: 91f6f04d66d133ff760630c4003e5a332894bb0f COCOAPODS: 0.39.0 From d93587b7997e2196ed471663ff87ece92e08f301 Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Thu, 12 Nov 2015 19:43:34 -0600 Subject: [PATCH 87/94] [Rakefile] Add a release task --- Rakefile | 131 +++++++++++++++++++++++++++++++----------------- RestKit.podspec | 2 +- 2 files changed, 86 insertions(+), 47 deletions(-) diff --git a/Rakefile b/Rakefile index 4603f59e7b..771399e727 100644 --- a/Rakefile +++ b/Rakefile @@ -15,7 +15,7 @@ XCTasks::TestTask.new(:test) do |t| t.workspace = 'RestKit.xcworkspace' t.schemes_dir = 'Tests/Schemes' t.runner = :xcpretty - t.actions = %w{test} + t.actions = %w(test) t.subtask(ios: 'RestKitTests') do |s| s.sdk = :iphonesimulator @@ -33,101 +33,101 @@ namespace :test do # Provides validation that RestKit continues to build without Core Data. This requires conditional compilation that is error prone task :building_without_core_data do title 'Testing without Core Data' - run("cd Examples/RKTwitter && pod install") - run("xctool -workspace Examples/RKTwitter/RKTwitter.xcworkspace -scheme RKTwitter -sdk iphonesimulator clean build ONLY_ACTIVE_ARCH=NO") + run('cd Examples/RKTwitter && pod install') + run('xctool -workspace Examples/RKTwitter/RKTwitter.xcworkspace -scheme RKTwitter -sdk iphonesimulator clean build ONLY_ACTIVE_ARCH=NO') end end -task :default => ["server:autostart", :test, "server:autostop"] +task default: ['server:autostart', :test, 'server:autostop'] def restkit_version - @restkit_version ||= ENV['VERSION'] || File.read("VERSION").chomp + @restkit_version ||= ENV['VERSION'] || File.read('VERSION').chomp end def apple_doc_command - "/usr/local/bin/appledoc -o Docs/API -p RestKit -v #{restkit_version} -c \"RestKit\" " + - "--company-id org.restkit --warn-undocumented-object --warn-undocumented-member --warn-empty-description --warn-unknown-directive " + - "--warn-invalid-crossref --warn-missing-arg --no-repeat-first-par " + "/usr/local/bin/appledoc -o Docs/API -p RestKit -v #{restkit_version} -c \"RestKit\" " \ + '--company-id org.restkit --warn-undocumented-object --warn-undocumented-member --warn-empty-description --warn-unknown-directive ' \ + '--warn-invalid-crossref --warn-missing-arg --no-repeat-first-par ' end def run(command, min_exit_status = 0) puts "Executing: `#{command}`" - sh(command) + system(command) if $?.exitstatus > min_exit_status puts "[!] Failed with exit code #{$?.exitstatus} while running: `#{command}`" exit($?.exitstatus) end - return $?.exitstatus + $?.exitstatus end -desc "Build RestKit for iOS and Mac OS X" +desc 'Build RestKit for iOS and Mac OS X' task :build do title 'Building RestKit' - run("xcodebuild -workspace RestKit.xcworkspace -scheme RestKit -sdk iphonesimulator5.0 clean build") - run("xcodebuild -workspace RestKit.xcworkspace -scheme RestKit -sdk iphoneos clean build") - run("xcodebuild -workspace RestKit.xcworkspace -scheme RestKit -sdk macosx10.6 clean build") + run('xcodebuild -workspace RestKit.xcworkspace -scheme RestKit -sdk iphonesimulator5.0 clean build') + run('xcodebuild -workspace RestKit.xcworkspace -scheme RestKit -sdk iphoneos clean build') + run('xcodebuild -workspace RestKit.xcworkspace -scheme RestKit -sdk macosx10.6 clean build') end -desc "Generate documentation via appledoc" -task :docs => 'docs:generate' +desc 'Generate documentation via appledoc' +task docs: 'docs:generate' namespace :appledoc do task :check do - unless File.exists?('/usr/local/bin/appledoc') - puts "appledoc not found at /usr/local/bin/appledoc: Install via homebrew and try again: `brew install --HEAD appledoc`" + unless File.exist?('/usr/local/bin/appledoc') + puts 'appledoc not found at /usr/local/bin/appledoc: Install via homebrew and try again: `brew install --HEAD appledoc`' exit 1 end end end namespace :docs do - task :generate => 'appledoc:check' do + task generate: 'appledoc:check' do command = apple_doc_command << " --no-create-docset --keep-intermediate-files --create-html `find Code/ -name '*.h'`" run(command, 1) - puts "Generated HTML documentation at Docs/API/html" + puts 'Generated HTML documentation at Docs/API/html' end - desc "Check that documentation can be built from the source code via appledoc successfully." - task :check => 'appledoc:check' do + desc 'Check that documentation can be built from the source code via appledoc successfully.' + task check: 'appledoc:check' do command = apple_doc_command << " --no-create-html --verbose 5 `find Code/ -name '*.h'`" exitstatus = run(command, 1) if exitstatus == 0 - puts "appledoc generation completed successfully!" + puts 'appledoc generation completed successfully!' elsif exitstatus == 1 - puts "appledoc generation produced warnings" + puts 'appledoc generation produced warnings' elsif exitstatus == 2 - puts "! appledoc generation encountered an error" + puts '! appledoc generation encountered an error' exit(exitstatus) else - puts "!! appledoc generation failed with a fatal error" + puts '!! appledoc generation failed with a fatal error' end exit(exitstatus) end - desc "Generate & install a docset into Xcode from the current sources" - task :install => 'appledoc:check' do + desc 'Generate & install a docset into Xcode from the current sources' + task install: 'appledoc:check' do command = apple_doc_command << " --install-docset `find Code/ -name '*.h'`" run(command, 1) end - desc "Build and publish the documentation set to the remote server (using rsync over SSH)" - task :publish, :version, :destination, :publish_feed do |t, args| - args.with_defaults(:version => File.read("VERSION").chomp, :destination => "restkit.org:/var/www/public/restkit.org/public/api/", :publish_feed => 'true') + desc 'Build and publish the documentation set to the remote server (using rsync over SSH)' + task :publish, :version, :destination, :publish_feed do |_t, args| + args.with_defaults(version: File.read('VERSION').chomp, destination: 'restkit.org:/var/www/public/restkit.org/public/api/', publish_feed: 'true') version = args[:version] destination = args[:destination] puts "Generating RestKit docset for version #{version}..." command = apple_doc_command << - " --keep-intermediate-files" << - " --docset-feed-name \"RestKit #{version} Documentation\"" << - " --docset-feed-url http://restkit.org/api/%DOCSETATOMFILENAME" << - " --docset-package-url http://restkit.org/api/%DOCSETPACKAGEFILENAME --publish-docset --verbose 3 `find Code/ -name '*.h'`" + ' --keep-intermediate-files' \ + " --docset-feed-name \"RestKit #{version} Documentation\"" \ + ' --docset-feed-url http://restkit.org/api/%DOCSETATOMFILENAME' \ + " --docset-package-url http://restkit.org/api/%DOCSETPACKAGEFILENAME --publish-docset --verbose 3 `find Code/ -name '*.h'`" run(command, 1) puts "Uploading docset to #{destination}..." versioned_destination = File.join(destination, version) command = "rsync -rvpPe ssh --delete Docs/API/html/ #{versioned_destination}" run(command) - should_publish_feed = %{yes true 1}.include?(args[:publish_feed].downcase) + should_publish_feed = %(yes true 1).include?(args[:publish_feed].downcase) if $?.exitstatus == 0 && should_publish_feed command = "rsync -rvpPe ssh Docs/API/publish/* #{destination}" run(command) @@ -136,11 +136,11 @@ namespace :docs do end namespace :build do - desc "Build all Example projects to ensure they are building properly" + desc 'Build all Example projects to ensure they are building properly' task :examples do - ios_sdks = %w{iphonesimulator5.0 iphonesimulator6.0} - osx_sdks = %w{macosx} - osx_projects = %w{RKMacOSX} + ios_sdks = %w(iphonesimulator5.0 iphonesimulator6.0) + osx_sdks = %w(macosx) + osx_projects = %w(RKMacOSX) examples_path = File.join(File.expand_path(File.dirname(__FILE__)), 'Examples') example_projects = `find #{examples_path} -name '*.xcodeproj'`.split("\n") @@ -157,9 +157,9 @@ namespace :build do end end -desc "Validate a branch is ready for merging by checking for common issues" -task :validate => ['build:examples', 'docs:check', :test] do - puts "Project state validated successfully. Proceed with merge." +desc 'Validate a branch is ready for merging by checking for common issues' +task validate: ['build:examples', 'docs:check', :test] do + puts 'Project state validated successfully. Proceed with merge.' end task :lint do @@ -169,13 +169,52 @@ task :lint do end desc 'Runs the CI suite' -task :ci => ['server:autostart', :test, 'test:building_without_core_data', :lint] +task ci: ['server:autostart', :test, 'test:building_without_core_data', :lint] + +desc 'Make a new release of RestKit' +task :release do + tag = "v#{restkit_version}" + if `git tag`.strip.split("\n").include?(tag) + error "A tag for version `#{tag}` already exists." + end + if `git symbolic-ref HEAD 2>/dev/null`.strip.split('/').last !~ /(\Adevelopment)|(-stable)\Z/ + error 'You need to be on `development` or a `stable` branch in order to do a release.' + end + + diff_lines = `git diff --name-only`.strip.split("\n") + if diff_lines.size == 0 + errors << 'Change the version number of the pod yourself' + end + diff_lines.delete('Podfile.lock') + unless diff_lines == %w(VERSION) + error = 'Only change the version and the Podfile.lock files' + error << "\n- " + diff_lines.join("\n- ") + error(error) + end + + title 'Running tests' + Rake::Task['ci'].invoke + + sh "git checkout -b release/#{restkit_version}" + sh "git commit -am 'Release #{tag}'" + sh "git tag '#{tag}'" + sh 'git checkout master' + sh "git merge --no-ff `#{tag}`" + sh 'git push' + sh 'git checkout development' + sh "git merge --no-ff `#{tag}`" + sh 'git push --tags' +end def title(title) cyan_title = "\033[0;36m#{title}\033[0m" puts - puts "-" * 80 + puts '-' * 80 puts cyan_title - puts "-" * 80 + puts '-' * 80 puts end + +def error(string) + fail "\033[0;31m[!] #{string}\e[0m" +end diff --git a/RestKit.podspec b/RestKit.podspec index c81ffa42de..e676088c49 100644 --- a/RestKit.podspec +++ b/RestKit.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'RestKit' - s.version = '0.25.0' + s.version = File.read(File.expand_path('../VERSION', __FILE__)).strip s.summary = 'RestKit is a framework for consuming and modeling RESTful web resources on iOS and OS X.' s.homepage = 'https://github.com/RestKit/RestKit' s.social_media_url = 'https://twitter.com/RestKit' From fc396b2c8203ec1db0dea6eb190289e3108d32ab Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Thu, 12 Nov 2015 22:45:12 -0600 Subject: [PATCH 88/94] [Rakefile] gsub the podspec version instead of reading from file --- Rakefile | 6 +++++- RestKit.podspec | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Rakefile b/Rakefile index 771399e727..e312392fb7 100644 --- a/Rakefile +++ b/Rakefile @@ -183,7 +183,7 @@ task :release do diff_lines = `git diff --name-only`.strip.split("\n") if diff_lines.size == 0 - errors << 'Change the version number of the pod yourself' + error 'Change the version number of the pod yourself' end diff_lines.delete('Podfile.lock') unless diff_lines == %w(VERSION) @@ -192,6 +192,10 @@ task :release do error(error) end + podspec = File.read('RestKit.podspec') + podspec.gsub!(/(s\.version\s*=\s*)'#{Gem::Version::VERSION_PATTERN}'/, "\\1'#{restkit_version}'") + File.open('RestKit.podspec', 'w') { |f| f << podspec } + title 'Running tests' Rake::Task['ci'].invoke diff --git a/RestKit.podspec b/RestKit.podspec index e676088c49..c81ffa42de 100644 --- a/RestKit.podspec +++ b/RestKit.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'RestKit' - s.version = File.read(File.expand_path('../VERSION', __FILE__)).strip + s.version = '0.25.0' s.summary = 'RestKit is a framework for consuming and modeling RESTful web resources on iOS and OS X.' s.homepage = 'https://github.com/RestKit/RestKit' s.social_media_url = 'https://twitter.com/RestKit' From c65fbf230ec41327aef5c42c95dfb207d096c5ef Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Thu, 12 Nov 2015 23:34:14 -0600 Subject: [PATCH 89/94] [Rakefile] Run pod install during release task --- Rakefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Rakefile b/Rakefile index e312392fb7..8e3b6f5968 100644 --- a/Rakefile +++ b/Rakefile @@ -196,6 +196,8 @@ task :release do podspec.gsub!(/(s\.version\s*=\s*)'#{Gem::Version::VERSION_PATTERN}'/, "\\1'#{restkit_version}'") File.open('RestKit.podspec', 'w') { |f| f << podspec } + sh "bundle exec pod install" + title 'Running tests' Rake::Task['ci'].invoke From 29a8502c457ecbc9e94300fa084ee8db29ab5596 Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Thu, 12 Nov 2015 23:45:01 -0600 Subject: [PATCH 90/94] [Rakefile] Push to CocoaPods during release --- Rakefile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Rakefile b/Rakefile index 8e3b6f5968..cc608e36f4 100644 --- a/Rakefile +++ b/Rakefile @@ -206,10 +206,12 @@ task :release do sh "git tag '#{tag}'" sh 'git checkout master' sh "git merge --no-ff `#{tag}`" - sh 'git push' + sh 'git push --tags' + sh "git checkout '#{tag}'" + sh "bundle exec pod trunk push" sh 'git checkout development' sh "git merge --no-ff `#{tag}`" - sh 'git push --tags' + sh 'git push' end def title(title) From e473ec8500c9442ab8e9e6d317f78376a961ee37 Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Fri, 13 Nov 2015 00:10:10 -0600 Subject: [PATCH 91/94] Release v0.26.0 --- Podfile.lock | 22 +++++++++++----------- RestKit.podspec | 2 +- VERSION | 2 +- 3 files changed, 13 insertions(+), 13 deletions(-) diff --git a/Podfile.lock b/Podfile.lock index a39081b79b..466734d586 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -13,31 +13,31 @@ PODS: - RKValueTransformers (~> 1.1.0) - OCHamcrest (3.0.1) - OCMock (2.2.4) - - RestKit (0.25.0): - - RestKit/Core (= 0.25.0) - - RestKit/CocoaLumberjack (0.25.0): + - RestKit (0.26.0): + - RestKit/Core (= 0.26.0) + - RestKit/CocoaLumberjack (0.26.0): - CocoaLumberjack - RestKit/Support - - RestKit/Core (0.25.0): + - RestKit/Core (0.26.0): - RestKit/CoreData - RestKit/Network - RestKit/ObjectMapping - - RestKit/CoreData (0.25.0): + - RestKit/CoreData (0.26.0): - RestKit/ObjectMapping - - RestKit/Network (0.25.0): + - RestKit/Network (0.26.0): - AFNetworking (~> 1.3.0) - RestKit/ObjectMapping - RestKit/Support - SOCKit - - RestKit/ObjectMapping (0.25.0): + - RestKit/ObjectMapping (0.26.0): - ISO8601DateFormatterValueTransformer (~> 0.6.1) - RestKit/Support - RKValueTransformers (~> 1.1.0) - - RestKit/Search (0.25.0): + - RestKit/Search (0.26.0): - RestKit/CoreData - - RestKit/Support (0.25.0): + - RestKit/Support (0.26.0): - TransitionKit (~> 2.2) - - RestKit/Testing (0.25.0): + - RestKit/Testing (0.26.0): - RestKit/Network - RKCLLocationValueTransformer (1.1.0): - RKValueTransformers (~> 1.1.0) @@ -74,7 +74,7 @@ SPEC CHECKSUMS: ISO8601DateFormatterValueTransformer: 52da467d6ec899d6aedda8e48280ac92e8ee97e6 OCHamcrest: e19857683e4eefab64b878668eac04c2f4567118 OCMock: a6a7dc0e3997fb9f35d99f72528698ebf60d64f2 - RestKit: 4149b1e118cb8e16a6e268d9ae53bc7465268813 + RestKit: 112fba5bd1f97598aac0db7981863d5fdc0263a2 RKCLLocationValueTransformer: 2cf0ea0fb7cd4bc70c56834fb92abc717c66f982 RKValueTransformers: 66ac5e4f077fdbe3496e792d89eeff4c3eb67701 SOCKit: c7376ac262bea9115b8f749358f762522a47d392 diff --git a/RestKit.podspec b/RestKit.podspec index c81ffa42de..9c4661313f 100644 --- a/RestKit.podspec +++ b/RestKit.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'RestKit' - s.version = '0.25.0' + s.version = '0.26.0' s.summary = 'RestKit is a framework for consuming and modeling RESTful web resources on iOS and OS X.' s.homepage = 'https://github.com/RestKit/RestKit' s.social_media_url = 'https://twitter.com/RestKit' diff --git a/VERSION b/VERSION index d21d277be5..4e8f395fa5 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.25.0 +0.26.0 From 29b5699282e10e7292cb43ae5b749c85ff5a844f Mon Sep 17 00:00:00 2001 From: Curtis Mak Date: Fri, 12 Feb 2016 18:02:07 -0800 Subject: [PATCH 92/94] Update version for Restkit podspec --- RestKit.podspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/RestKit.podspec b/RestKit.podspec index 802176f7ef..346c095451 100644 --- a/RestKit.podspec +++ b/RestKit.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'RestKit' - s.version = '0.24.1' + s.version = '0.24.2' s.summary = 'RestKit is a framework for consuming and modeling RESTful web resources on iOS and OS X.' s.homepage = 'https://github.com/RestKit/RestKit' s.social_media_url = 'https://twitter.com/RestKit' From c93c55725afc3c5a7cc83a1d4b97c842e51e80f4 Mon Sep 17 00:00:00 2001 From: Curtis Mak Date: Mon, 15 Feb 2016 19:36:36 -0800 Subject: [PATCH 93/94] Add back csrf check --- Code/Network/RKObjectRequestOperation.m | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Code/Network/RKObjectRequestOperation.m b/Code/Network/RKObjectRequestOperation.m index 8fbeda8320..ef81e1d615 100644 --- a/Code/Network/RKObjectRequestOperation.m +++ b/Code/Network/RKObjectRequestOperation.m @@ -478,6 +478,9 @@ - (void)setCompletionBlockWithSuccess:(void (^)(RKObjectRequestOperation *operat } else { if (success) { dispatch_async(self.successCallbackQueue ?: dispatch_get_main_queue(), ^{ + NSDictionary *responseDict=[NSJSONSerialization JSONObjectWithData:self.HTTPRequestOperation.responseData options:NSJSONReadingMutableLeaves error:nil]; + NSNotification *notification=[NSNotification notificationWithName:@"com.molescope.csrf" object:nil userInfo:responseDict]; + [[NSNotificationQueue defaultQueue] enqueueNotification:notification postingStyle:NSPostWhenIdle coalesceMask:NSNotificationCoalescingOnName forModes:nil]; success(self, self.mappingResult); }); } From c33d7fbdd9f6d32712fa7c4ebbe2ab1933cd3e38 Mon Sep 17 00:00:00 2001 From: YevgenStarikov <124806754+YevgenStarikov@users.noreply.github.com> Date: Thu, 12 Oct 2023 11:55:27 -0700 Subject: [PATCH 94/94] Update RKManagedObjectStore.m Fixing the following NEW error: "this class is not key value coding-compliant for the key @count" for iOS 10+ --- Code/CoreData/RKManagedObjectStore.m | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/Code/CoreData/RKManagedObjectStore.m b/Code/CoreData/RKManagedObjectStore.m index d2d7655456..d5c98af955 100644 --- a/Code/CoreData/RKManagedObjectStore.m +++ b/Code/CoreData/RKManagedObjectStore.m @@ -52,10 +52,15 @@ static BOOL RKIsManagedObjectContextDescendentOfContext(NSManagedObjectContext * static NSSet *RKSetOfManagedObjectIDsFromManagedObjectContextDidSaveNotification(NSNotification *notification) { - NSUInteger count = [[[notification.userInfo allValues] valueForKeyPath:@"@sum.@count"] unsignedIntegerValue]; - NSMutableSet *objectIDs = [NSMutableSet setWithCapacity:count]; + // fixing the following NEW error: "this class is not key value coding-compliant for the key @count" for iOS 10+ + // NSUInteger count = [[[notification.userInfo allValues] valueForKeyPath:@"@sum.@count"] unsignedIntegerValue]; + // NSMutableSet *objectIDs = [NSMutableSet setWithCapacity:count]; + + NSLog([notification.userInfo allValues]); + NSMutableSet *objectIDs =[NSMutableSet new]; for (NSSet *objects in [notification.userInfo allValues]) { - [objectIDs unionSet:[objects valueForKey:@"objectID"]]; + if ([objects isKindOfClass:NSSet.class]) + [objectIDs unionSet:[objects valueForKey:@"objectID"]]; } return objectIDs; }
Object Mapping
Object Mapping
RKObjectMapping Encapsulates configuration for transforming object representations as expressed by key-value coding keypaths.