├── .gitignore
├── Other Sources
├── Cheddar.xcdatamodeld
│ ├── .xccurrentversion
│ ├── Cheddar.xcdatamodel
│ │ └── contents
│ └── Cheddar 2.xcdatamodel
│ │ └── contents
└── CheddarKit-Prefix.pch
├── CheddarKit
├── NSDictionary+CheddarKit.h
├── NSString+CheddarKit.h
├── NSDictionary+CheddarKit.m
├── CDKPushController.h
├── CheddarKit.h
├── CDKTag.h
├── CDKRemoteManagedObject.h
├── CDKList.h
├── CDKDefines.m
├── CDKRemoteManagedObject.m
├── CDKUser.h
├── CDKTask.h
├── CDKDefines.h
├── CDKTag.m
├── NSString+CheddarKit.m
├── CDKHTTPClient.h
├── CDKUser.m
├── CDKTask.m
├── CDKList.m
├── CDKPushController.m
└── CDKHTTPClient.m
├── .gitmodules
├── Readme.markdown
├── LICENSE
└── CheddarKit.xcodeproj
└── project.pbxproj
/.gitignore:
--------------------------------------------------------------------------------
1 | .DS_Store
2 | *xcuserdata/
3 | *build/
4 | *.mode1v3
5 | *.pbxuser
6 | *.xcworkspace
7 | *.moved-aside/
8 | DerivedData
9 |
--------------------------------------------------------------------------------
/Other Sources/Cheddar.xcdatamodeld/.xccurrentversion:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | _XCCurrentVersionName
6 | Cheddar 2.xcdatamodel
7 |
8 |
9 |
--------------------------------------------------------------------------------
/Other Sources/CheddarKit-Prefix.pch:
--------------------------------------------------------------------------------
1 | //
2 | // CheddarKit-Prefix.pch
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 11/30/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #ifdef __OBJC__
10 | #import
11 | #import
12 | #endif
13 |
--------------------------------------------------------------------------------
/CheddarKit/NSDictionary+CheddarKit.h:
--------------------------------------------------------------------------------
1 | //
2 | // NSDictionary+CheddarKit.h
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 6/4/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | @interface NSDictionary (CheddarKit)
12 |
13 | - (id)safeObjectForKey:(id)key;
14 |
15 | @end
16 |
--------------------------------------------------------------------------------
/CheddarKit/NSString+CheddarKit.h:
--------------------------------------------------------------------------------
1 | //
2 | // NSString+CheddarKit.h
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 6/10/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | @interface NSString (CheddarKit)
12 |
13 | - (NSRange)composedRangeWithRange:(NSRange)range;
14 | - (NSString *)composedSubstringWithRange:(NSRange)range;
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/CheddarKit/NSDictionary+CheddarKit.m:
--------------------------------------------------------------------------------
1 | //
2 | // NSDictionary+CheddarKit.m
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 6/4/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "NSDictionary+CheddarKit.h"
10 |
11 | @implementation NSDictionary (CheddarKit)
12 |
13 |
14 | - (id)safeObjectForKey:(id)key {
15 | id value = [self valueForKey:key];
16 | if (value == [NSNull null]) {
17 | return nil;
18 | }
19 | return value;
20 | }
21 |
22 | @end
23 |
--------------------------------------------------------------------------------
/.gitmodules:
--------------------------------------------------------------------------------
1 | [submodule "CheddarKit/Vendor/SSKeychain"]
2 | path = CheddarKit/Vendor/SSKeychain
3 | url = https://github.com/soffes/sskeychain.git
4 | [submodule "CheddarKit/Vendor/SSDataKit"]
5 | path = CheddarKit/Vendor/SSDataKit
6 | url = https://github.com/soffes/ssdatakit.git
7 | [submodule "CheddarKit/Vendor/Bully"]
8 | path = CheddarKit/Vendor/Bully
9 | url = https://github.com/soffes/bully.git
10 | [submodule "CheddarKit/Vendor/AFNetworking"]
11 | path = CheddarKit/Vendor/AFNetworking
12 | url = https://github.com/AFNetworking/AFNetworking.git
13 |
--------------------------------------------------------------------------------
/CheddarKit/CDKPushController.h:
--------------------------------------------------------------------------------
1 | //
2 | // CDKPushController.h
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 4/9/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | @class BLYClient;
12 | @class BLYChannel;
13 |
14 | @interface CDKPushController : NSObject
15 |
16 | @property (nonatomic, strong, readonly) BLYClient *client;
17 | @property (nonatomic, strong, readonly) BLYChannel *userChannel;
18 |
19 | + (CDKPushController *)sharedController;
20 | + (void)setDevelopmentModeEnabled:(BOOL)enabled;
21 |
22 | @end
23 |
--------------------------------------------------------------------------------
/CheddarKit/CheddarKit.h:
--------------------------------------------------------------------------------
1 | //
2 | // CheddarKit.h
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 7/24/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | // Models
12 | #import
13 | #import
14 | #import
15 | #import
16 |
17 | // Networking
18 | #import
19 | #import
20 |
21 | // Categories
22 | #import
23 | #import
24 |
25 | // Vendor
26 | #import
27 | #import
28 |
--------------------------------------------------------------------------------
/Readme.markdown:
--------------------------------------------------------------------------------
1 | # CheddarKit
2 |
3 | **Important:** CheddarKit is no longer maintained by Nothing Magical. It has been [sold](http://sam.roon.io/parting-ways-with-cheddar). Going forward, Cheddar is no longe open source since the new owner has choosen to keep it private. This will remain as an archive of the previous version that was open source. Everything should still work. Thank you to everyone for your support as I built Cheddar. Seriously. Thank you.
4 |
5 | ---
6 |
7 | CheddarKit is an iOS static library and OS X framework. It handles all of the Core Data, networking, and push interactions of Cheddar for all of our Objective-C based applications.
8 |
9 | ## License
10 |
11 | CheddarKit is released under the [MIT license](https://github.com/nothingmagical/cheddarkit/blob/master/LICENSE).
12 |
--------------------------------------------------------------------------------
/CheddarKit/CDKTag.h:
--------------------------------------------------------------------------------
1 | //
2 | // CDKTag.h
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 4/12/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "SSDataKit.h"
10 |
11 | @class CDKTask;
12 |
13 | @interface CDKTag : SSRemoteManagedObject
14 |
15 | @property (nonatomic, strong) NSString *name;
16 | @property (nonatomic, strong) NSSet *tasks;
17 |
18 | + (CDKTag *)existingTagWithName:(NSString *)name;
19 | + (CDKTag *)existingTagWithName:(NSString *)name context:(NSManagedObjectContext *)context;
20 |
21 | @end
22 |
23 |
24 | @interface CDKTag (CoreDataGeneratedAccessors)
25 | - (void)addTasksObject:(CDKTask *)value;
26 | - (void)removeTasksObject:(CDKTask *)value;
27 | - (void)addTasks:(NSSet *)values;
28 | - (void)removeTasks:(NSSet *)values;
29 | @end
30 |
--------------------------------------------------------------------------------
/CheddarKit/CDKRemoteManagedObject.h:
--------------------------------------------------------------------------------
1 | //
2 | // CDKRemoteManagedObject.h
3 | // Cheddar
4 | //
5 | // Created by Sam Soffes on 6/24/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "SSDataKit.h"
10 |
11 | @class AFJSONRequestOperation;
12 |
13 | @interface CDKRemoteManagedObject : SSRemoteManagedObject
14 |
15 | - (void)create;
16 | - (void)createWithSuccess:(void(^)(void))success failure:(void(^)(AFJSONRequestOperation *remoteOperation, NSError *error))failure;
17 |
18 | - (void)update;
19 | - (void)updateWithSuccess:(void(^)(void))success failure:(void(^)(AFJSONRequestOperation *remoteOperation, NSError *error))failure;
20 |
21 | + (void)sortWithObjects:(NSArray *)objects;
22 | + (void)sortWithObjects:(NSArray *)objects success:(void(^)(void))success failure:(void(^)(AFJSONRequestOperation *remoteOperation, NSError *error))failure;
23 |
24 | @end
25 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | Copyright (c) 2012 Nothing Magical
2 |
3 | Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
4 |
5 | The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
6 |
7 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
8 |
--------------------------------------------------------------------------------
/CheddarKit/CDKList.h:
--------------------------------------------------------------------------------
1 | //
2 | // CDKList.h
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 4/5/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "CDKRemoteManagedObject.h"
10 |
11 | @class CDKTask;
12 |
13 | @interface CDKList : CDKRemoteManagedObject
14 |
15 | @property (nonatomic, strong) NSDate *archivedAt;
16 | @property (nonatomic, strong) NSNumber *position;
17 | @property (nonatomic, strong) NSString *title;
18 | @property (nonatomic, strong) NSString *slug;
19 | @property (nonatomic, strong) NSSet *tasks;
20 | @property (nonatomic, strong) NSManagedObject *user;
21 |
22 | - (NSInteger)highestPosition;
23 | - (NSArray *)sortedTasks;
24 | - (NSArray *)sortedActiveTasks;
25 | - (NSArray *)sortedCompletedActiveTasks;
26 |
27 | - (void)archiveAllTasks;
28 | - (void)archiveCompletedTasks;
29 |
30 | @end
31 |
32 |
33 | @interface CDKList (CoreDataGeneratedAccessors)
34 | - (void)addTasksObject:(CDKTask *)value;
35 | - (void)removeTasksObject:(CDKTask *)value;
36 | - (void)addTasks:(NSSet *)values;
37 | - (void)removeTasks:(NSSet *)values;
38 | @end
39 |
--------------------------------------------------------------------------------
/CheddarKit/CDKDefines.m:
--------------------------------------------------------------------------------
1 | //
2 | // CDKDefines.m
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 3/30/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "CDKDefines.h"
10 |
11 | #pragma mark - API
12 |
13 | NSString *const kCDKAPIScheme = @"https";
14 | NSString *const kCDKAPIHost = @"api.cheddarapp.com";
15 | NSString *const kCDKPusherAPIKey = @"675f10a650f18b4eb0a8";
16 |
17 | NSString *const kCDKDevelopmentAPIScheme = @"http";
18 | NSString *const kCDKDevelopmentAPIHost = @"localhost:5000";
19 | NSString *const kCDKDevelopmentPusherAPIKey = @"a02cb793e9d5fb919023";
20 |
21 |
22 | #pragma mark - User Defaults Keys
23 |
24 | NSString *const kCDKCurrentUserIDKey = @"CHCurrentUserID";
25 | NSString *const kCDKCurrentUsernameKey = @"CHCurrentUsername";
26 |
27 |
28 | #pragma mark - Misc
29 |
30 | NSString *const kCDKKeychainServiceName = @"Cheddar";
31 |
32 |
33 | #pragma mark - Notifications
34 |
35 | NSString *const kCDKListDidUpdateNotificationName = @"CDKListDidUpdateNotification";
36 | NSString *const kCDKPlusDidChangeNotificationName = @"CDKPlusDidChangeNotification";
37 | NSString *const kCDKUserUpdatedNotificationName = @"CDKUserUpdatedNotificationName";
38 |
--------------------------------------------------------------------------------
/CheddarKit/CDKRemoteManagedObject.m:
--------------------------------------------------------------------------------
1 | //
2 | // CDKRemoteManagedObject.m
3 | // Cheddar
4 | //
5 | // Created by Sam Soffes on 6/24/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "CDKRemoteManagedObject.h"
10 |
11 | @implementation CDKRemoteManagedObject
12 |
13 | - (void)create {
14 | [self createWithSuccess:nil failure:nil];
15 | }
16 |
17 |
18 | - (void)createWithSuccess:(void(^)(void))success failure:(void(^)(AFJSONRequestOperation *remoteOperation, NSError *error))failure {
19 | // Subclasses must override this method
20 | }
21 |
22 |
23 | - (void)update {
24 | [self updateWithSuccess:nil failure:nil];
25 | }
26 |
27 |
28 | - (void)updateWithSuccess:(void(^)(void))success failure:(void(^)(AFJSONRequestOperation *remoteOperation, NSError *error))failure {
29 | // Subclasses must override this method
30 | }
31 |
32 |
33 | + (void)sortWithObjects:(NSArray *)objects {
34 | [self sortWithObjects:objects success:nil failure:nil];
35 | }
36 |
37 |
38 | + (void)sortWithObjects:(NSArray *)objects success:(void(^)(void))success failure:(void(^)(AFJSONRequestOperation *remoteOperation, NSError *error))failure {
39 | // Subclasses must override this method
40 | }
41 |
42 | @end
43 |
--------------------------------------------------------------------------------
/CheddarKit/CDKUser.h:
--------------------------------------------------------------------------------
1 | //
2 | // CDKUser.h
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 4/5/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "SSDataKit.h"
10 |
11 | @class CDKList;
12 | @class CDKTask;
13 |
14 | extern NSString *const kCDKCurrentUserChangedNotificationName;
15 |
16 | @interface CDKUser : SSRemoteManagedObject
17 |
18 | @property (nonatomic, strong) NSString *firstName;
19 | @property (nonatomic, strong) NSString *lastName;
20 | @property (nonatomic, strong) NSString *username;
21 | @property (nonatomic, strong) NSString *email;
22 | @property (nonatomic, strong) NSNumber *hasPlus;
23 | @property (nonatomic, strong) NSSet *tasks;
24 | @property (nonatomic, strong) NSSet *lists;
25 | @property (nonatomic, strong) NSString *accessToken;
26 |
27 | + (CDKUser *)currentUser;
28 | + (void)setCurrentUser:(CDKUser *)user;
29 |
30 | @end
31 |
32 |
33 | @interface CDKUser (CoreDataGeneratedAccessors)
34 | - (void)addTasksObject:(CDKTask *)value;
35 | - (void)removeTasksObject:(CDKTask *)value;
36 | - (void)addTasks:(NSSet *)values;
37 | - (void)removeTasks:(NSSet *)values;
38 |
39 | - (void)addListsObject:(CDKList *)value;
40 | - (void)removeListsObject:(CDKList *)value;
41 | - (void)addLists:(NSSet *)values;
42 | - (void)removeLists:(NSSet *)values;
43 | @end
44 |
--------------------------------------------------------------------------------
/CheddarKit/CDKTask.h:
--------------------------------------------------------------------------------
1 | //
2 | // CDKTask.h
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 4/5/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "CDKRemoteManagedObject.h"
10 |
11 | @class CDKUser;
12 | @class CDKList;
13 | @class CDKTag;
14 | @class NSAttributedString;
15 | @class NSMutableAttributedString;
16 |
17 | @interface CDKTask : CDKRemoteManagedObject
18 |
19 | @property (nonatomic, strong) NSDate *archivedAt;
20 | @property (nonatomic, strong) NSString *text;
21 | @property (nonatomic, strong) NSString *displayText;
22 | @property (nonatomic, strong) NSDictionary *entities;
23 | @property (nonatomic, strong) NSNumber *position;
24 | @property (nonatomic, strong) NSDate *completedAt;
25 | @property (nonatomic, strong) CDKUser *user;
26 | @property (nonatomic, strong) CDKList *list;
27 | @property (nonatomic, strong) NSSet *tags;
28 | @property (nonatomic, assign, getter = isCompleted) BOOL completed;
29 |
30 | - (void)toggleCompleted;
31 | - (BOOL)hasTag:(CDKTag *)tag;
32 | - (BOOL)hasTags:(NSArray *)tags;
33 | - (void)moveToList:(CDKList *)list;
34 |
35 | @end
36 |
37 |
38 | @interface CDKTask (CoreDataGeneratedAccessors)
39 | - (void)addTagsObject:(CDKTag *)value;
40 | - (void)removeTagsObject:(CDKTag *)value;
41 | - (void)addTags:(NSSet *)values;
42 | - (void)removeTags:(NSSet *)values;
43 | @end
44 |
--------------------------------------------------------------------------------
/CheddarKit/CDKDefines.h:
--------------------------------------------------------------------------------
1 | //
2 | // CDKDefines.h
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 3/30/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | #ifndef CHDEFINES
12 | #define CHDEFINES
13 |
14 | // CDKDispatchRelease
15 | #if __IPHONE_OS_VERSION_MIN_REQUIRED >= 60000 || MAC_OS_X_VERSION_MIN_REQUIRED >= 1080
16 | #define CDKDispatchRelease(queue)
17 | #else
18 | #define CDKDispatchRelease(queue) dispatch_release(queue)
19 | #endif
20 |
21 | // Always use development on the simulator or Mac app (for now)
22 | #if !TARGET_IPHONE_SIMULATOR
23 | #define CHEDDAR_PRODUCTION_MODE 1
24 | #endif
25 |
26 | #pragma mark - API
27 |
28 | extern NSString *const kCDKAPIScheme;
29 | extern NSString *const kCDKAPIHost;
30 | extern NSString *const kCDKPusherAPIKey;
31 |
32 | extern NSString *const kCDKDevelopmentAPIScheme;
33 | extern NSString *const kCDKDevelopmentAPIHost;
34 | extern NSString *const kCDKDevelopmentPusherAPIKey;
35 |
36 |
37 | #pragma mark - User Defaults Keys
38 |
39 | extern NSString *const kCDKCurrentUserIDKey;
40 | extern NSString *const kCDKCurrentUsernameKey;
41 |
42 |
43 | #pragma mark - Misc
44 |
45 | extern NSString *const kCDKKeychainServiceName;
46 |
47 | #pragma mark - Notifications
48 |
49 | extern NSString *const kCDKListDidUpdateNotificationName;
50 | extern NSString *const kCDKPlusDidChangeNotificationName;
51 | extern NSString *const kCDKUserUpdatedNotificationName;
52 |
53 | #endif
54 |
--------------------------------------------------------------------------------
/CheddarKit/CDKTag.m:
--------------------------------------------------------------------------------
1 | //
2 | // CDKTag.m
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 4/12/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "CDKTag.h"
10 | #import "CDKTask.h"
11 |
12 | @implementation CDKTag
13 |
14 | @dynamic name;
15 | @dynamic tasks;
16 |
17 | + (NSString *)entityName {
18 | return @"Tag";
19 | }
20 |
21 |
22 | + (NSArray *)defaultSortDescriptors {
23 | return [NSArray arrayWithObjects:
24 | [NSSortDescriptor sortDescriptorWithKey:@"name" ascending:YES],
25 | [NSSortDescriptor sortDescriptorWithKey:@"remoteID" ascending:YES],
26 | nil];
27 | }
28 |
29 |
30 | - (void)unpackDictionary:(NSDictionary *)dictionary {
31 | [super unpackDictionary:dictionary];
32 | self.name = [dictionary objectForKey:@"name"];
33 | }
34 |
35 |
36 | - (BOOL)shouldUnpackDictionary:(NSDictionary *)dictionary {
37 | return YES;
38 | }
39 |
40 |
41 | + (CDKTag *)existingTagWithName:(NSString *)name {
42 | return [self existingTagWithName:name context:nil];
43 | }
44 |
45 |
46 | + (CDKTag *)existingTagWithName:(NSString *)name context:(NSManagedObjectContext *)context {
47 | // Default to the main context
48 | if (!context) {
49 | context = [self mainContext];
50 | }
51 |
52 | // Create the fetch request for the ID
53 | NSFetchRequest *fetchRequest = [[NSFetchRequest alloc] init];
54 | fetchRequest.entity = [self entityWithContext:context];
55 | fetchRequest.predicate = [NSPredicate predicateWithFormat:@"name = %@", name];
56 | fetchRequest.fetchLimit = 1;
57 |
58 | // Execute the fetch request
59 | NSArray *results = [context executeFetchRequest:fetchRequest error:nil];
60 |
61 | // If the object is not found, return nil
62 | if (results.count == 0) {
63 | return nil;
64 | }
65 |
66 | // Return the object
67 | return [results objectAtIndex:0];
68 | }
69 |
70 | @end
71 |
--------------------------------------------------------------------------------
/CheddarKit/NSString+CheddarKit.m:
--------------------------------------------------------------------------------
1 | //
2 | // NSString+CheddarKit.m
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 6/10/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "NSString+CheddarKit.h"
10 |
11 | @implementation NSString (CheddarKit)
12 |
13 | - (NSRange)composedRangeWithRange:(NSRange)range {
14 | // We're going to make a new range that takes into account surrogate unicode pairs (composed characters)
15 | __block NSRange adjustedRange = range;
16 |
17 | // Adjust the location
18 | [self enumerateSubstringsInRange:NSMakeRange(0, range.location + 1) options:NSStringEnumerationByComposedCharacterSequences usingBlock:^(NSString *substring, NSRange substringRange, NSRange enclosingRange, BOOL *stop) {
19 | // If they string the iterator found is greater than 1 in length, add that to range location.
20 | // This means that there is a composed character before where the range starts who's length is greater than 1.
21 | adjustedRange.location += substring.length - 1;
22 | }];
23 |
24 |
25 | // Adjust the length
26 | NSInteger length = self.length;
27 |
28 | // Count how many times we iterate so we only iterate over what we care about.
29 | __block NSInteger count = 0;
30 | [self enumerateSubstringsInRange:NSMakeRange(adjustedRange.location, length - adjustedRange.location) options:NSStringEnumerationByComposedCharacterSequences usingBlock:^(NSString *substring, NSRange substringRange, NSRange enclosingRange, BOOL *stop) {
31 | // If they string the iterator found is greater than 1 in length, add that to range length.
32 | // This means that there is a composed character inside of the range starts who's length is greater than 1.
33 | adjustedRange.length += substring.length - 1;
34 |
35 | // Add one to the count
36 | count++;
37 |
38 | // If we have iterated as many times as the original length, stop.
39 | if (range.length == count) {
40 | *stop = YES;
41 | }
42 | }];
43 |
44 | // Make sure we don't make an invalid range. This should never happen, but let's play it safe anyway.
45 | if (adjustedRange.location + adjustedRange.length > length) {
46 | adjustedRange.length = length - adjustedRange.location - 1;
47 | }
48 |
49 | // Return the adjusted range
50 | return adjustedRange;
51 | }
52 |
53 |
54 | - (NSString *)composedSubstringWithRange:(NSRange)range {
55 | // Return a substring using a composed range so surrogate unicode pairs (composed characters) count as 1 in the
56 | // range instead of however many unichars they actually are.
57 | return [self substringWithRange:[self composedRangeWithRange:range]];
58 | }
59 |
60 | @end
61 |
--------------------------------------------------------------------------------
/CheddarKit/CDKHTTPClient.h:
--------------------------------------------------------------------------------
1 | //
2 | // CDKHTTPClient.h
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 3/30/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "AFNetworking.h"
10 |
11 | typedef void (^CDKHTTPClientSuccess)(AFJSONRequestOperation *operation, id responseObject);
12 | typedef void (^CDKHTTPClientFailure)(AFJSONRequestOperation *operation, NSError *error);
13 |
14 | @class CDKUser;
15 | @class CDKList;
16 | @class CDKTask;
17 | @class BLYChannel;
18 |
19 | @interface CDKHTTPClient : AFHTTPClient
20 |
21 | + (CDKHTTPClient *)sharedClient;
22 | + (void)setDevelopmentModeEnabled:(BOOL)enabled;
23 | + (NSString *)apiVersion;
24 | - (void)setClientID:(NSString *)clientID secret:(NSString *)clientSecret;
25 |
26 | - (void)changeUser:(CDKUser *)user;
27 |
28 | // User
29 | - (void)signInWithLogin:(NSString *)login password:(NSString *)password success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
30 | - (void)signInWithAuthorizationCode:(NSString *)code success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
31 | - (void)signUpWithUsername:(NSString *)username email:(NSString *)email password:(NSString *)password success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
32 | - (void)updateCurrentUserWithSuccess:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
33 |
34 | // Lists
35 | - (void)getListsWithSuccess:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
36 | - (void)createList:(CDKList *)list success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
37 | - (void)updateList:(CDKList *)list success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
38 | - (void)sortLists:(NSArray *)lists success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
39 |
40 | // Tasks
41 | - (void)getTasksWithList:(CDKList *)list success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
42 | - (void)createTask:(CDKTask *)task success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
43 | - (void)updateTask:(CDKTask *)task success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
44 | - (void)sortTasks:(NSArray *)tasks inList:(CDKList *)list success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
45 | - (void)archiveAllTasksInList:(CDKList *)list success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
46 | - (void)archiveCompletedTasksInList:(CDKList *)list success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
47 | - (void)moveTask:(CDKTask *)task toList:(CDKList *)list success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure;
48 |
49 | @end
--------------------------------------------------------------------------------
/CheddarKit/CDKUser.m:
--------------------------------------------------------------------------------
1 | //
2 | // CDKUser.m
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 4/5/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "CDKUser.h"
10 | #import "CDKList.h"
11 | #import "CDKTask.h"
12 | #import "SSKeychain.h"
13 | #import "NSDictionary+CheddarKit.h"
14 | #import "CDKDefines.h"
15 |
16 | NSString *const kCDKCurrentUserChangedNotificationName = @"CHCurrentUserChangedNotification";
17 | static NSString *const kCDKUserIDKey = @"CDKUserID";
18 | static CDKUser *__currentUser = nil;
19 |
20 | @implementation CDKUser
21 |
22 | @dynamic firstName;
23 | @dynamic lastName;
24 | @dynamic username;
25 | @dynamic email;
26 | @dynamic tasks;
27 | @dynamic lists;
28 | @dynamic hasPlus;
29 | @synthesize accessToken = _accessToken;
30 |
31 |
32 | + (NSString *)entityName {
33 | return @"User";
34 | }
35 |
36 |
37 | + (CDKUser *)currentUser {
38 | if (!__currentUser) {
39 | NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults];
40 | NSNumber *userID = [userDefaults objectForKey:kCDKUserIDKey];
41 | if (!userID) {
42 | return nil;
43 | }
44 |
45 | NSError *error = nil;
46 | NSString *accessToken = [SSKeychain passwordForService:kCDKKeychainServiceName account:userID.description error:&error];
47 | if (!accessToken) {
48 | NSLog(@"[CheddarKit] Failed to get access token: %@", error);
49 | return nil;
50 | }
51 |
52 | __currentUser = [self existingObjectWithRemoteID:userID];
53 | __currentUser.accessToken = accessToken;
54 | }
55 | return __currentUser;
56 | }
57 |
58 |
59 | + (void)setCurrentUser:(CDKUser *)user {
60 | if (__currentUser) {
61 | [SSKeychain deletePasswordForService:kCDKKeychainServiceName account:__currentUser.remoteID.description];
62 | }
63 |
64 | NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults];
65 |
66 | if (!user.remoteID || !user.accessToken) {
67 | __currentUser = nil;
68 | [userDefaults removeObjectForKey:kCDKUserIDKey];
69 | } else {
70 | NSError *error = nil;
71 | [SSKeychain setPassword:user.accessToken forService:kCDKKeychainServiceName account:user.remoteID.description error:&error];
72 | if (error) {
73 | NSLog(@"[CheddarKit] Failed to save access token: %@", error);
74 | }
75 |
76 | __currentUser = user;
77 | [userDefaults setObject:user.remoteID forKey:kCDKUserIDKey];
78 | }
79 |
80 | [userDefaults synchronize];
81 | [[NSNotificationCenter defaultCenter] postNotificationName:kCDKCurrentUserChangedNotificationName object:user];
82 | }
83 |
84 |
85 | - (void)unpackDictionary:(NSDictionary *)dictionary {
86 | [super unpackDictionary:dictionary];
87 | self.firstName = [dictionary safeObjectForKey:@"first_name"];
88 | self.lastName = [dictionary safeObjectForKey:@"last_name"];
89 | self.username = [dictionary safeObjectForKey:@"username"];
90 | self.email = [dictionary safeObjectForKey:@"email"];
91 | self.hasPlus = [dictionary safeObjectForKey:@"has_plus"];
92 | }
93 |
94 | @end
95 |
--------------------------------------------------------------------------------
/Other Sources/Cheddar.xcdatamodeld/Cheddar.xcdatamodel/contents:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
--------------------------------------------------------------------------------
/Other Sources/Cheddar.xcdatamodeld/Cheddar 2.xcdatamodel/contents:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
--------------------------------------------------------------------------------
/CheddarKit/CDKTask.m:
--------------------------------------------------------------------------------
1 | //
2 | // CDKTask.m
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 4/5/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "CDKTask.h"
10 | #import "CDKUser.h"
11 | #import "CDKList.h"
12 | #import "CDKTag.h"
13 | #import "CDKHTTPClient.h"
14 | #import "NSString+CheddarKit.h"
15 |
16 | @implementation CDKTask
17 |
18 | @dynamic archivedAt;
19 | @dynamic text;
20 | @dynamic displayText;
21 | @synthesize entities;
22 | @dynamic position;
23 | @dynamic completedAt;
24 | @dynamic user;
25 | @dynamic list;
26 | @dynamic tags;
27 |
28 | - (void)setCompleted:(BOOL)completed {
29 | if (completed == [self isCompleted]) {
30 | return;
31 | }
32 |
33 | if (completed) {
34 | self.completedAt = [NSDate date];
35 | } else {
36 | self.completedAt = nil;
37 | }
38 |
39 | [self save];
40 | [self update];
41 | }
42 |
43 |
44 | - (BOOL)isCompleted {
45 | return self.completedAt != nil;
46 | }
47 |
48 |
49 | #pragma mark - SSManagedObject
50 |
51 | + (NSString *)entityName {
52 | return @"Task";
53 | }
54 |
55 |
56 | + (NSArray *)defaultSortDescriptors {
57 | return [NSArray arrayWithObjects:
58 | [NSSortDescriptor sortDescriptorWithKey:@"position" ascending:YES],
59 | [NSSortDescriptor sortDescriptorWithKey:@"remoteID" ascending:YES],
60 | nil];
61 | }
62 |
63 |
64 | #pragma mark - SSRemoteManagedObject
65 |
66 | - (void)unpackDictionary:(NSDictionary *)dictionary {
67 | [super unpackDictionary:dictionary];
68 | self.archivedAt = [[self class] parseDate:[dictionary objectForKey:@"archived_at"]];
69 | self.completedAt = [[self class] parseDate:[dictionary objectForKey:@"completed_at"]];
70 | self.position = [dictionary objectForKey:@"position"];
71 | self.text = [dictionary objectForKey:@"text"];
72 | self.displayText = [dictionary objectForKey:@"display_text"];
73 | self.entities = [dictionary objectForKey:@"entities"];
74 |
75 | if ([dictionary objectForKey:@"user"]) {
76 | self.user = [CDKUser objectWithDictionary:[dictionary objectForKey:@"user"] context:self.managedObjectContext];
77 | }
78 |
79 | NSNumber *listID = [dictionary objectForKey:@"list_id"];
80 | if (listID) {
81 | self.list = [CDKList objectWithRemoteID:listID context:self.managedObjectContext];
82 | }
83 |
84 | // Add tags
85 | NSMutableSet *tags = [[NSMutableSet alloc] init];
86 | for (NSDictionary *tagDictionary in [dictionary objectForKey:@"tags"]) {
87 | CDKTag *tag = [CDKTag objectWithDictionary:tagDictionary];
88 | [tags addObject:tag];
89 | }
90 | self.tags = tags;
91 | }
92 |
93 |
94 | - (BOOL)shouldUnpackDictionary:(NSDictionary *)dictionary {
95 | return YES;
96 | }
97 |
98 |
99 | #pragma mark - CDKRemoteManagedObject
100 |
101 | - (void)createWithSuccess:(void(^)(void))success failure:(void(^)(AFJSONRequestOperation *operation, NSError *error))failure {
102 | [[CDKHTTPClient sharedClient] createTask:self success:^(AFJSONRequestOperation *operation, id responseObject) {
103 | if (success) {
104 | success();
105 | }
106 | } failure:^(AFJSONRequestOperation *operation, NSError *error) {
107 | if (failure) {
108 | failure(operation, error);
109 | }
110 | }];
111 | }
112 |
113 |
114 | - (void)updateWithSuccess:(void(^)(void))success failure:(void(^)(AFJSONRequestOperation *operation, NSError *error))failure {
115 | [[CDKHTTPClient sharedClient] updateTask:self success:^(AFJSONRequestOperation *operation, id responseObject) {
116 | if (success) {
117 | success();
118 | }
119 | } failure:^(AFJSONRequestOperation *operation, NSError *error) {
120 | if (failure) {
121 | failure(operation, error);
122 | }
123 | }];
124 | }
125 |
126 |
127 | + (void)sortWithObjects:(NSArray *)objects success:(void(^)(void))success failure:(void(^)(AFJSONRequestOperation *operation, NSError *error))failure {
128 | CDKList *list = [(CDKTask *)[objects objectAtIndex:0] list];
129 | [[CDKHTTPClient sharedClient] sortTasks:objects inList:list success:^(AFJSONRequestOperation *operation, id responseObject) {
130 | if (success) {
131 | success();
132 | }
133 | } failure:^(AFJSONRequestOperation *operation, NSError *error) {
134 | if (failure) {
135 | failure(operation, error);
136 | }
137 | }];
138 | }
139 |
140 |
141 | #pragma mark - Task
142 |
143 | - (void)toggleCompleted {
144 | if (self.isCompleted) {
145 | self.completedAt = nil;
146 | } else {
147 | self.completedAt = [NSDate date];
148 | }
149 | [self save];
150 | [self update];
151 | }
152 |
153 |
154 | - (BOOL)hasTag:(CDKTag *)tag {
155 | // There has to be a better way to write this
156 | NSArray *names = [self.tags valueForKey:@"name"];
157 | NSString *tagName = [tag.name lowercaseString];
158 | for (NSString *name in names) {
159 | if ([[name lowercaseString] isEqualToString:tagName]) {
160 | return YES;
161 | }
162 | }
163 | return NO;
164 | }
165 |
166 |
167 | - (BOOL)hasTags:(NSArray *)tags {
168 | // There has to be a better way to write this
169 | for (CDKTag *tag in tags) {
170 | if (![self hasTag:tag]) {
171 | return NO;
172 | }
173 | }
174 | return YES;
175 | }
176 |
177 |
178 | - (void)moveToList:(CDKList *)list {
179 | CDKList *oldList = self.list;
180 | self.list = list;
181 | [self save];
182 |
183 | [[CDKHTTPClient sharedClient] moveTask:self toList:list success:nil failure:^(AFJSONRequestOperation *operation, NSError *error) {
184 | dispatch_async(dispatch_get_main_queue(), ^{
185 | self.list = oldList;
186 | [self save];
187 | });
188 | }];
189 | }
190 |
191 | @end
192 |
--------------------------------------------------------------------------------
/CheddarKit/CDKList.m:
--------------------------------------------------------------------------------
1 | //
2 | // CDKList.m
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 4/5/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "CDKList.h"
10 | #import "CDKTask.h"
11 | #import "CDKUser.h"
12 | #import "CDKHTTPClient.h"
13 |
14 | @implementation CDKList
15 |
16 | @dynamic archivedAt;
17 | @dynamic position;
18 | @dynamic title;
19 | @dynamic slug;
20 | @dynamic tasks;
21 | @dynamic user;
22 |
23 | #pragma mark - SSManagedObject
24 |
25 | + (NSString *)entityName {
26 | return @"List";
27 | }
28 |
29 |
30 | + (NSArray *)defaultSortDescriptors {
31 | return [NSArray arrayWithObjects:
32 | [NSSortDescriptor sortDescriptorWithKey:@"position" ascending:YES],
33 | [NSSortDescriptor sortDescriptorWithKey:@"remoteID" ascending:YES],
34 | nil];
35 | }
36 |
37 |
38 | #pragma mark - SSRemoteManagedObject
39 |
40 | - (void)unpackDictionary:(NSDictionary *)dictionary {
41 | [super unpackDictionary:dictionary];
42 | self.archivedAt = [[self class] parseDate:[dictionary objectForKey:@"archived_at"]];
43 | self.position = [dictionary objectForKey:@"position"];
44 | self.title = [dictionary objectForKey:@"title"];
45 | self.slug = [dictionary objectForKey:@"slug"];
46 |
47 | if ([dictionary objectForKey:@"user"]) {
48 | self.user = [CDKUser objectWithDictionary:[dictionary objectForKey:@"user"] context:self.managedObjectContext];
49 | }
50 |
51 | for (NSDictionary *taskDictionary in [dictionary objectForKey:@"tasks"]) {
52 | CDKTask *task = [CDKTask objectWithDictionary:taskDictionary context:self.managedObjectContext];
53 | task.list = self;
54 | }
55 | }
56 |
57 |
58 | - (BOOL)shouldUnpackDictionary:(NSDictionary *)dictionary {
59 | return YES;
60 | }
61 |
62 |
63 | #pragma mark - CDKRemoteManagedObject
64 |
65 | - (void)createWithSuccess:(void(^)(void))success failure:(void(^)(AFJSONRequestOperation *remoteOperation, NSError *error))failure {
66 | [[CDKHTTPClient sharedClient] createList:self success:^(AFJSONRequestOperation *operation, id responseObject) {
67 | if (success) {
68 | success();
69 | }
70 | } failure:^(AFJSONRequestOperation *operation, NSError *error) {
71 | if (failure) {
72 | failure(operation, error);
73 | }
74 | }];
75 | }
76 |
77 |
78 | - (void)updateWithSuccess:(void(^)(void))success failure:(void(^)(AFJSONRequestOperation *remoteOperation, NSError *error))failure {
79 | [[CDKHTTPClient sharedClient] updateList:self success:^(AFJSONRequestOperation *operation, id responseObject) {
80 | if (success) {
81 | success();
82 | }
83 | } failure:^(AFJSONRequestOperation *operation, NSError *error) {
84 | if (failure) {
85 | failure(operation, error);
86 | }
87 | }];
88 | }
89 |
90 |
91 | + (void)sortWithObjects:(NSArray *)objects success:(void(^)(void))success failure:(void(^)(AFJSONRequestOperation *remoteOperation, NSError *error))failure {
92 | [[CDKHTTPClient sharedClient] sortLists:objects success:^(AFJSONRequestOperation *operation, id responseObject) {
93 | if (success) {
94 | success();
95 | }
96 | } failure:^(AFJSONRequestOperation *operation, NSError *error) {
97 | if (failure) {
98 | failure(operation, error);
99 | }
100 | }];
101 | }
102 |
103 |
104 | #pragma mark - Sorting
105 |
106 | - (NSInteger)highestPosition {
107 | NSFetchRequest *fetchRequest = [[NSFetchRequest alloc] init];
108 | fetchRequest.entity = [CDKTask entityWithContext:self.managedObjectContext];
109 | fetchRequest.predicate = [NSPredicate predicateWithFormat:@"list = %@", self];
110 | fetchRequest.sortDescriptors = [NSArray arrayWithObject:[NSSortDescriptor sortDescriptorWithKey:@"position" ascending:NO]];
111 | fetchRequest.fetchLimit = 1;
112 | NSArray *results = [self.managedObjectContext executeFetchRequest:fetchRequest error:nil];
113 | if (results.count == 0) {
114 | return 0;
115 | }
116 | return [[(CDKList *)[results objectAtIndex:0] position] integerValue];
117 | }
118 |
119 |
120 | - (NSArray *)sortedTasks {
121 | NSFetchRequest *fetchRequest = [[NSFetchRequest alloc] init];
122 | fetchRequest.entity = [CDKTask entityWithContext:self.managedObjectContext];
123 | fetchRequest.predicate = [NSPredicate predicateWithFormat:@"list = %@", self];
124 | fetchRequest.sortDescriptors = [NSArray arrayWithObject:[NSSortDescriptor sortDescriptorWithKey:@"position" ascending:YES]];
125 | return [self.managedObjectContext executeFetchRequest:fetchRequest error:nil];
126 | }
127 |
128 |
129 | - (NSArray *)sortedActiveTasks {
130 | NSFetchRequest *fetchRequest = [[NSFetchRequest alloc] init];
131 | fetchRequest.entity = [CDKTask entityWithContext:self.managedObjectContext];
132 | fetchRequest.predicate = [NSPredicate predicateWithFormat:@"list = %@ AND archivedAt = nil", self];
133 | fetchRequest.sortDescriptors = [NSArray arrayWithObject:[NSSortDescriptor sortDescriptorWithKey:@"position" ascending:YES]];
134 | return [self.managedObjectContext executeFetchRequest:fetchRequest error:nil];
135 | }
136 |
137 |
138 | - (NSArray *)sortedCompletedActiveTasks {
139 | NSFetchRequest *fetchRequest = [[NSFetchRequest alloc] init];
140 | fetchRequest.entity = [CDKTask entityWithContext:self.managedObjectContext];
141 | fetchRequest.predicate = [NSPredicate predicateWithFormat:@"list = %@ AND archivedAt = nil AND completedAt != nil", self];
142 | fetchRequest.sortDescriptors = [NSArray arrayWithObject:[NSSortDescriptor sortDescriptorWithKey:@"position" ascending:YES]];
143 | return [self.managedObjectContext executeFetchRequest:fetchRequest error:nil];
144 | }
145 |
146 |
147 | - (void)archiveAllTasks {
148 | NSArray *tasks = self.sortedActiveTasks;
149 | if (tasks.count == 0) {
150 | return;
151 | }
152 |
153 | for (CDKTask *task in tasks) {
154 | task.archivedAt = [NSDate date];
155 | }
156 | [self.managedObjectContext save:nil];
157 |
158 | [[CDKHTTPClient sharedClient] archiveAllTasksInList:self success:nil failure:nil];
159 | }
160 |
161 |
162 | - (void)archiveCompletedTasks {
163 | NSArray *tasks = self.sortedCompletedActiveTasks;
164 | if (tasks.count == 0) {
165 | return;
166 | }
167 |
168 | for (CDKTask *task in tasks) {
169 | task.archivedAt = [NSDate date];
170 | }
171 | [self.managedObjectContext save:nil];
172 |
173 | [[CDKHTTPClient sharedClient] archiveCompletedTasksInList:self success:nil failure:nil];
174 | }
175 |
176 | @end
177 |
--------------------------------------------------------------------------------
/CheddarKit/CDKPushController.m:
--------------------------------------------------------------------------------
1 | //
2 | // CDKPushController.m
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 4/9/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "CDKPushController.h"
10 | #import "CDKList.h"
11 | #import "CDKTask.h"
12 | #import "CDKHTTPClient.h"
13 | #import "CDKUser.h"
14 | #import "CDKDefines.h"
15 | #import
16 | #import "Reachability.h"
17 |
18 | static BOOL __developmentMode = NO;
19 |
20 | @interface CDKPushController ()
21 | @property (nonatomic, strong, readwrite) BLYClient *client;
22 | @property (nonatomic, strong, readwrite) BLYChannel *userChannel;
23 | @property (nonatomic, strong) NSString *userID;
24 | - (void)_userChanged:(NSNotification *)notification;
25 | - (void)_appDidEnterBackground:(NSNotification *)notificaiton;
26 | - (void)_appDidBecomeActive:(NSNotification *)notification;
27 | - (void)_reachabilityChanged:(NSNotification *)notification;
28 | @end
29 |
30 | @implementation CDKPushController {
31 | Reachability *_reachability;
32 | }
33 |
34 | @synthesize client = _client;
35 | @synthesize userChannel = _userChannel;
36 | @synthesize userID = _userID;
37 |
38 | - (void)setUserID:(NSString *)userID {
39 | [self.userChannel unsubscribe];
40 | self.userChannel = nil;
41 |
42 | _userID = userID;
43 |
44 | if (!_userID) {
45 | return;
46 | }
47 |
48 | // Subscribe to user channel
49 | NSString *channelName = [NSString stringWithFormat:@"private-user-%@", _userID];
50 | self.userChannel = [self.client subscribeToChannelWithName:channelName authenticationBlock:^(BLYChannel *channel) {
51 | [[CDKHTTPClient sharedClient] postPath:@"/pusher/auth" parameters:channel.authenticationParameters success:^(AFHTTPRequestOperation *operation, id responseObject) {
52 | [channel subscribeWithAuthentication:responseObject];
53 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
54 | NSLog(@"Failed to authorize Pusher channel: %@", error);
55 | }];
56 | }];
57 |
58 | // Bind to list create
59 | [self.userChannel bindToEvent:@"list-create" block:^(id message) {
60 | CDKList *list = [CDKList objectWithDictionary:message];
61 | [list.managedObjectContext save:nil];
62 | }];
63 |
64 | // Bind to list update
65 | [self.userChannel bindToEvent:@"list-update" block:^(id message) {
66 | CDKList *list = [CDKList objectWithDictionary:message];
67 | [list save];
68 |
69 | [[NSNotificationCenter defaultCenter] postNotificationName:kCDKListDidUpdateNotificationName object:list.remoteID];
70 | }];
71 |
72 | // Bind to list reorder
73 | [self.userChannel bindToEvent:@"list-reorder" block:^(id message) {
74 | for (NSDictionary *dictionary in [message objectForKey:@"lists"]) {
75 | CDKList *list = [CDKList existingObjectWithRemoteID:[dictionary objectForKey:@"id"]];
76 | list.position = [dictionary objectForKey:@"position"];
77 | }
78 | [[CDKList mainContext] save:nil];
79 | }];
80 |
81 | // Bind to task create
82 | [self.userChannel bindToEvent:@"task-create" block:^(id message) {
83 | CDKList *list = [CDKList existingObjectWithRemoteID:[message objectForKey:@"list_id"]];
84 | if (!list) {
85 | return;
86 | }
87 |
88 | CDKTask *task = [CDKTask objectWithDictionary:message];
89 | task.list = list;
90 | [task save];
91 | }];
92 |
93 | // Bind to task update
94 | [self.userChannel bindToEvent:@"task-update" block:^(id message) {
95 | CDKList *list = [CDKList existingObjectWithRemoteID:[message objectForKey:@"list_id"]];
96 | if (!list) {
97 | return;
98 | }
99 |
100 | CDKTask *task = [CDKTask objectWithDictionary:message];
101 | task.list = list;
102 | [task save];
103 | }];
104 |
105 | // Bind to task reorder
106 | [self.userChannel bindToEvent:@"task-reorder" block:^(id message) {
107 | for (NSDictionary *dictionary in [message objectForKey:@"tasks"]) {
108 | CDKTask *task = [CDKTask existingObjectWithRemoteID:[dictionary objectForKey:@"id"]];
109 | task.position = [dictionary objectForKey:@"position"];
110 | }
111 | [[CDKTask mainContext] save:nil];
112 | }];
113 |
114 | // Bind to user update
115 | [self.userChannel bindToEvent:@"user-update" block:^(id message) {
116 | CDKUser *user = [CDKUser objectWithDictionary:message];
117 | [user save];
118 | [[NSNotificationCenter defaultCenter] postNotificationName:kCDKUserUpdatedNotificationName object:user userInfo:nil];
119 | }];
120 | }
121 |
122 |
123 | #pragma mark - Singleton
124 |
125 | + (CDKPushController *)sharedController {
126 | static CDKPushController *sharedController = nil;
127 | static dispatch_once_t onceToken;
128 | dispatch_once(&onceToken, ^{
129 | sharedController = [[self alloc] init];
130 | });
131 | return sharedController;
132 | }
133 |
134 |
135 | + (void)setDevelopmentModeEnabled:(BOOL)enabled {
136 | __developmentMode = enabled;
137 | }
138 |
139 |
140 | #pragma mark - NSObject
141 |
142 | - (id)init {
143 | if ((self = [super init])) {
144 | _client = [[BLYClient alloc] initWithAppKey:(__developmentMode ? kCDKDevelopmentPusherAPIKey : kCDKPusherAPIKey) delegate:self];
145 |
146 | self.userID = [CDKUser currentUser].remoteID.description;
147 |
148 | NSNotificationCenter *notificationCenter = [NSNotificationCenter defaultCenter];
149 | [notificationCenter addObserver:self selector:@selector(_userChanged:) name:kCDKCurrentUserChangedNotificationName object:nil];
150 |
151 | #if TARGET_OS_IPHONE
152 | [notificationCenter addObserver:self selector:@selector(_appDidEnterBackground:) name:UIApplicationDidEnterBackgroundNotification object:nil];
153 | [notificationCenter addObserver:self selector:@selector(_appDidBecomeActive:) name:UIApplicationDidBecomeActiveNotification object:nil];
154 | #endif
155 |
156 | _reachability = [Reachability reachabilityWithHostname:@"ws.pusherapp.com"];
157 | [_reachability startNotifier];
158 | [notificationCenter addObserver:self selector:@selector(_reachabilityChanged:) name:kReachabilityChangedNotification object:nil];
159 | }
160 | return self;
161 | }
162 |
163 |
164 | - (void)dealloc {
165 | [[NSNotificationCenter defaultCenter] removeObserver:self];
166 | [self.client disconnect];
167 | }
168 |
169 |
170 | #pragma mark - Private
171 |
172 | - (void)_userChanged:(NSNotification *)notification {
173 | self.userID = [CDKUser currentUser].remoteID.description;
174 | }
175 |
176 |
177 | - (void)_appDidEnterBackground:(NSNotification *)notificaiton {
178 | [self.client disconnect];
179 | }
180 |
181 |
182 | - (void)_appDidBecomeActive:(NSNotification *)notification {
183 | [self.client connect];
184 | }
185 |
186 |
187 | - (void)_reachabilityChanged:(NSNotification *)notification {
188 | if ([_reachability isReachable]) {
189 | [self.client connect];
190 | } else {
191 | [self.client disconnect];
192 | }
193 | }
194 |
195 |
196 | #pragma mark - BLYClientDelegate
197 |
198 | - (void)bullyClientDidConnect:(BLYClient *)client {
199 | [[CDKHTTPClient sharedClient] setDefaultHeader:@"X-Pusher-Socket-ID" value:client.socketID];
200 | }
201 |
202 |
203 | - (void)bullyClientDidDisconnect:(BLYClient *)client {
204 | if ([_reachability isReachable]) {
205 | [client connect];
206 | }
207 | }
208 |
209 | @end
210 |
--------------------------------------------------------------------------------
/CheddarKit/CDKHTTPClient.m:
--------------------------------------------------------------------------------
1 | //
2 | // CDKTTPClient.m
3 | // CheddarKit
4 | //
5 | // Created by Sam Soffes on 3/30/12.
6 | // Copyright (c) 2012 Nothing Magical. All rights reserved.
7 | //
8 |
9 | #import "CDKHTTPClient.h"
10 | #import "CDKList.h"
11 | #import "CDKTask.h"
12 | #import "CDKUser.h"
13 | #import "CDKDefines.h"
14 | #import
15 |
16 | static BOOL __developmentMode = NO;
17 |
18 | @interface CDKHTTPClient ()
19 | - (void)_userChanged:(NSNotification *)notification;
20 | @end
21 |
22 | @implementation CDKHTTPClient {
23 | dispatch_queue_t _callbackQueue;
24 | NSString *_clientID;
25 | NSString *_clientSecret;
26 | }
27 |
28 | #pragma mark - Singleton
29 |
30 | + (CDKHTTPClient *)sharedClient {
31 | static CDKHTTPClient *sharedClient = nil;
32 | static dispatch_once_t onceToken;
33 | dispatch_once(&onceToken, ^{
34 | sharedClient = [[self alloc] init];
35 | });
36 | return sharedClient;
37 | }
38 |
39 |
40 | + (void)setDevelopmentModeEnabled:(BOOL)enabled {
41 | __developmentMode = enabled;
42 | }
43 |
44 |
45 | + (NSString *)apiVersion {
46 | return @"v1";
47 | }
48 |
49 |
50 | #pragma mark - NSObject
51 |
52 | - (id)init {
53 | NSURL *base = nil;
54 | NSString *version = [[self class] apiVersion];
55 | if (__developmentMode) {
56 | base = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@/%@/", kCDKDevelopmentAPIScheme, kCDKDevelopmentAPIHost, version]];
57 | } else {
58 | base = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@/%@/", kCDKAPIScheme, kCDKAPIHost, version]];
59 | }
60 |
61 | if ((self = [super initWithBaseURL:base])) {
62 | // Use JSON
63 | [self registerHTTPOperationClass:[AFJSONRequestOperation class]];
64 | [self setDefaultHeader:@"Accept" value:@"application/json"];
65 |
66 | if ([CDKUser currentUser]) {
67 | [self changeUser:[CDKUser currentUser]];
68 | }
69 |
70 | [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(_userChanged:) name:kCDKCurrentUserChangedNotificationName object:nil];
71 | _callbackQueue = dispatch_queue_create("com.nothingmagical.cheddar.network-callback-queue", 0);
72 | }
73 | return self;
74 | }
75 |
76 |
77 | - (void)dealloc {
78 | CDKDispatchRelease(_callbackQueue);
79 | [[NSNotificationCenter defaultCenter] removeObserver:self];
80 | }
81 |
82 |
83 | #pragma mark - AFHTTPClient
84 |
85 | - (NSMutableURLRequest *)requestWithMethod:(NSString *)method path:(NSString *)path parameters:(NSDictionary *)parameters {
86 | NSMutableURLRequest *request = [super requestWithMethod:method path:path parameters:parameters];
87 | [request setCachePolicy:NSURLRequestReloadIgnoringCacheData];
88 | return request;
89 | }
90 |
91 |
92 | - (void)enqueueHTTPRequestOperation:(AFHTTPRequestOperation *)operation {
93 | operation.successCallbackQueue = _callbackQueue;
94 | operation.failureCallbackQueue = _callbackQueue;
95 | [super enqueueHTTPRequestOperation:operation];
96 | }
97 |
98 |
99 | #pragma mark - Client
100 |
101 | - (void)setClientID:(NSString *)clientID secret:(NSString *)clientSecret {
102 | _clientID = clientID;
103 | _clientSecret = clientSecret;
104 | }
105 |
106 |
107 | #pragma mark - User
108 |
109 | - (void)signInWithLogin:(NSString *)login password:(NSString *)password success:(void (^)(AFJSONRequestOperation *operation, id responseObject))success failure:(void (^)(AFJSONRequestOperation *operation, NSError *error))failure {
110 | NSDictionary *params = [NSDictionary dictionaryWithObjectsAndKeys:
111 | login, @"username",
112 | password, @"password",
113 | @"password", @"grant_type",
114 | nil];
115 |
116 | [self setAuthorizationHeaderWithUsername:_clientID password:_clientSecret];
117 | [self postPath:@"/oauth/token" parameters:params success:^(AFHTTPRequestOperation *operation, id responseObject) {
118 | __weak NSManagedObjectContext *context = [CDKUser mainContext];
119 | [context performBlockAndWait:^{
120 | NSDictionary *dictionary = (NSDictionary *)responseObject;
121 | CDKUser *user = [CDKUser objectWithDictionary:[dictionary objectForKey:@"user"]];
122 | user.accessToken = [dictionary objectForKey:@"access_token"];
123 | [user save];
124 |
125 | [self changeUser:user];
126 | [CDKUser setCurrentUser:user];
127 | }];
128 |
129 | if (success) {
130 | success((AFJSONRequestOperation *)operation, responseObject);
131 | }
132 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
133 | if (failure) {
134 | failure((AFJSONRequestOperation *)operation, error);
135 | }
136 | }];
137 | [self clearAuthorizationHeader];
138 | }
139 |
140 |
141 | - (void)signInWithAuthorizationCode:(NSString *)code success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure {
142 | NSDictionary *params = [NSDictionary dictionaryWithObjectsAndKeys:
143 | code, @"code",
144 | @"authorization_code", @"grant_type",
145 | nil];
146 |
147 | [self setAuthorizationHeaderWithUsername:_clientID password:_clientSecret];
148 | [self postPath:@"/oauth/token" parameters:params success:^(AFHTTPRequestOperation *operation, id responseObject) {
149 | __weak NSManagedObjectContext *context = [CDKUser mainContext];
150 | [context performBlockAndWait:^{
151 | NSDictionary *dictionary = (NSDictionary *)responseObject;
152 | CDKUser *user = [CDKUser objectWithDictionary:[dictionary objectForKey:@"user"]];
153 | user.accessToken = [dictionary objectForKey:@"access_token"];
154 | [user save];
155 |
156 | [self changeUser:user];
157 | [CDKUser setCurrentUser:user];
158 | }];
159 |
160 | if (success) {
161 | success((AFJSONRequestOperation *)operation, responseObject);
162 | }
163 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
164 | if (failure) {
165 | failure((AFJSONRequestOperation *)operation, error);
166 | }
167 | }];
168 | [self clearAuthorizationHeader];
169 | }
170 |
171 |
172 | - (void)signUpWithUsername:(NSString *)username email:(NSString *)email password:(NSString *)password success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure {
173 | NSDictionary *params = [NSDictionary dictionaryWithObjectsAndKeys:
174 | username, @"user[username]",
175 | email, @"user[email]",
176 | password, @"user[password]",
177 | nil];
178 |
179 | [self setAuthorizationHeaderWithUsername:_clientID password:_clientSecret];
180 | [self postPath:@"users" parameters:params success:^(AFHTTPRequestOperation *operation, id responseObject) {
181 | __weak NSManagedObjectContext *context = [CDKUser mainContext];
182 | [context performBlockAndWait:^{
183 | NSDictionary *dictionary = (NSDictionary *)responseObject;
184 | CDKUser *user = [CDKUser objectWithDictionary:dictionary];
185 | user.accessToken = [[dictionary objectForKey:@"access_token"] objectForKey:@"access_token"];
186 | [self changeUser:user];
187 | [CDKUser setCurrentUser:user];
188 | }];
189 |
190 | if (success) {
191 | success((AFJSONRequestOperation *)operation, responseObject);
192 | }
193 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
194 | if (failure) {
195 | failure((AFJSONRequestOperation *)operation, error);
196 | }
197 | }];
198 | [self clearAuthorizationHeader];
199 | }
200 |
201 |
202 | - (void)updateCurrentUserWithSuccess:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure {
203 | [self getPath:@"me" parameters:nil success:^(AFHTTPRequestOperation *operation, id responseObject) {
204 | __weak NSManagedObjectContext *context = [CDKUser mainContext];
205 | [context performBlockAndWait:^{
206 | CDKUser *currentUser = [CDKUser currentUser];
207 | [currentUser unpackDictionary:responseObject];
208 | [currentUser save];
209 | }];
210 |
211 | if (success) {
212 | success((AFJSONRequestOperation *)operation, responseObject);
213 | }
214 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
215 | if (failure) {
216 | failure((AFJSONRequestOperation *)operation, error);
217 | }
218 | }];
219 | }
220 |
221 |
222 | #pragma mark - Lists
223 |
224 | - (void)getListsWithSuccess:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure {
225 | [self getPath:@"lists" parameters:nil success:^(AFHTTPRequestOperation *operation, id responseObject) {
226 | __weak NSManagedObjectContext *context = [CDKList mainContext];
227 | [context performBlockAndWait:^{
228 | for (NSDictionary *dictionary in responseObject) {
229 | [CDKList objectWithDictionary:dictionary];
230 | }
231 | [context save:nil];
232 | }];
233 |
234 | if (success) {
235 | success((AFJSONRequestOperation *)operation, responseObject);
236 | }
237 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
238 | if (failure) {
239 | failure((AFJSONRequestOperation *)operation, error);
240 | }
241 | }];
242 | }
243 |
244 |
245 | - (void)createList:(CDKList *)list success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure {
246 | NSDictionary *params = [[NSDictionary alloc] initWithObjectsAndKeys:
247 | list.title, @"list[title]",
248 | nil];
249 |
250 | __weak NSManagedObjectContext *context = [CDKList mainContext];
251 | [self postPath:@"lists" parameters:params success:^(AFHTTPRequestOperation *operation, id responseObject) {
252 | [context performBlockAndWait:^{
253 | [list unpackDictionary:responseObject];
254 | [list save];
255 | }];
256 |
257 | if (success) {
258 | success((AFJSONRequestOperation *)operation, responseObject);
259 | }
260 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
261 | [context performBlockAndWait:^{
262 | [list delete];
263 | }];
264 |
265 | if (failure) {
266 | failure((AFJSONRequestOperation *)operation, error);
267 | }
268 | }];
269 | }
270 |
271 |
272 | - (void)updateList:(CDKList *)list success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure {
273 | NSString *path = [NSString stringWithFormat:@"lists/%@", list.remoteID];
274 | id archivedAt = list.archivedAt ? list.archivedAt : @"null";
275 | NSDictionary *params = [[NSDictionary alloc] initWithObjectsAndKeys:
276 | list.title, @"list[title]",
277 | archivedAt, @"list[archived_at]",
278 | nil];
279 |
280 | [self putPath:path parameters:params success:^(AFHTTPRequestOperation *operation, id responseObject) {
281 | __weak NSManagedObjectContext *context = [CDKList mainContext];
282 | [context performBlockAndWait:^{
283 | [list unpackDictionary:responseObject];
284 | [list save];
285 | }];
286 |
287 | if (success) {
288 | success((AFJSONRequestOperation *)operation, responseObject);
289 | }
290 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
291 | if (failure) {
292 | failure((AFJSONRequestOperation *)operation, error);
293 | }
294 | }];
295 | }
296 |
297 |
298 | - (void)sortLists:(NSArray *)lists success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure {
299 | NSMutableURLRequest *request = [self requestWithMethod:@"POST" path:@"lists/sort" parameters:nil];
300 | [request setValue:@"application/x-www-form-urlencoded" forHTTPHeaderField:@"Content-Type"];
301 |
302 | // Build the array of indexs
303 | NSMutableArray *components = [[NSMutableArray alloc] init];
304 | for (CDKList *list in lists) {
305 | [components addObject:[NSString stringWithFormat:@"list[]=%@", list.remoteID]];
306 | }
307 | request.HTTPBody = [[components componentsJoinedByString:@"&"] dataUsingEncoding:NSUTF8StringEncoding];
308 |
309 | AFJSONRequestOperation *operation = [[AFJSONRequestOperation alloc] initWithRequest:request];
310 | [operation setCompletionBlockWithSuccess:^(AFHTTPRequestOperation *operation, id responseObject) {
311 | if (success) {
312 | success((AFJSONRequestOperation *)operation, responseObject);
313 | }
314 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
315 | if (failure) {
316 | failure((AFJSONRequestOperation *)operation, error);
317 | }
318 | }];
319 | [self enqueueHTTPRequestOperation:operation];
320 | }
321 |
322 |
323 | #pragma mark - Tasks
324 |
325 | - (void)getTasksWithList:(CDKList *)list success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure {
326 | NSString *path = [NSString stringWithFormat:@"lists/%@/tasks?all=true", list.remoteID];
327 | [self getPath:path parameters:nil success:^(AFHTTPRequestOperation *operation, id responseObject) {
328 | __weak NSManagedObjectContext *context = [CDKTask mainContext];
329 | [context performBlockAndWait:^{
330 | for (NSDictionary *taskDictionary in responseObject) {
331 | CDKTask *task = [CDKTask objectWithDictionary:taskDictionary];
332 | task.list = list;
333 | }
334 | [context save:nil];
335 | }];
336 |
337 | if (success) {
338 | success((AFJSONRequestOperation *)operation, responseObject);
339 | }
340 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
341 | if (failure) {
342 | failure((AFJSONRequestOperation *)operation, error);
343 | }
344 | }];
345 | }
346 |
347 |
348 | - (void)createTask:(CDKTask *)task success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure {
349 | NSString *path = [NSString stringWithFormat:@"lists/%@/tasks", task.list.remoteID];
350 | NSDictionary *params = [[NSDictionary alloc] initWithObjectsAndKeys:
351 | task.text, @"task[text]",
352 | nil];
353 |
354 | __weak NSManagedObjectContext *context = [CDKTask mainContext];
355 | [self postPath:path parameters:params success:^(AFHTTPRequestOperation *operation, id responseObject) {
356 | [context performBlockAndWait:^{
357 | [task unpackDictionary:responseObject];
358 | [task save];
359 | }];
360 |
361 | if (success) {
362 | success((AFJSONRequestOperation *)operation, responseObject);
363 | }
364 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
365 | [context performBlockAndWait:^{
366 | [task delete];
367 | }];
368 |
369 | if (failure) {
370 | failure((AFJSONRequestOperation *)operation, error);
371 | }
372 | }];
373 | }
374 |
375 |
376 | - (void)updateTask:(CDKTask *)task success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure {
377 | NSString *path = [NSString stringWithFormat:@"tasks/%@", task.remoteID];
378 | id completedAt = task.completedAt ? task.completedAt : @"null";
379 | id archivedAt = task.archivedAt ? task.archivedAt : @"null";
380 | NSDictionary *params = [[NSDictionary alloc] initWithObjectsAndKeys:
381 | task.text, @"task[text]",
382 | completedAt, @"task[completed_at]",
383 | archivedAt, @"task[archived_at]",
384 | nil];
385 |
386 | [self putPath:path parameters:params success:^(AFHTTPRequestOperation *operation, id responseObject) {
387 | __weak NSManagedObjectContext *context = [CDKTask mainContext];
388 | [context performBlockAndWait:^{
389 | [task unpackDictionary:responseObject];
390 | [task save];
391 | }];
392 |
393 | if (success) {
394 | success((AFJSONRequestOperation *)operation, responseObject);
395 | }
396 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
397 | if (failure) {
398 | failure((AFJSONRequestOperation *)operation, error);
399 | }
400 | }];
401 | }
402 |
403 |
404 | - (void)sortTasks:(NSArray *)tasks inList:(CDKList *)list success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure {
405 | NSString *path = [NSString stringWithFormat:@"lists/%@/tasks/sort", list.remoteID];
406 | NSMutableURLRequest *request = [self requestWithMethod:@"POST" path:path parameters:nil];
407 | [request setValue:@"application/x-www-form-urlencoded" forHTTPHeaderField:@"Content-Type"];
408 |
409 | // Build the array of indexs
410 | NSMutableArray *components = [[NSMutableArray alloc] init];
411 | for (CDKTask *task in tasks) {
412 | [components addObject:[NSString stringWithFormat:@"task[]=%@", task.remoteID]];
413 | }
414 | request.HTTPBody = [[components componentsJoinedByString:@"&"] dataUsingEncoding:NSUTF8StringEncoding];
415 |
416 | AFJSONRequestOperation *operation = [[AFJSONRequestOperation alloc] initWithRequest:request];
417 | [operation setCompletionBlockWithSuccess:^(AFHTTPRequestOperation *operation, id responseObject) {
418 | if (success) {
419 | success((AFJSONRequestOperation *)operation, responseObject);
420 | }
421 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
422 | if (failure) {
423 | failure((AFJSONRequestOperation *)operation, error);
424 | }
425 | }];
426 | [self enqueueHTTPRequestOperation:operation];
427 | }
428 |
429 |
430 | - (void)archiveAllTasksInList:(CDKList *)list success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure {
431 | NSString *path = [NSString stringWithFormat:@"lists/%@/tasks/archive_all", list.remoteID];
432 | [self postPath:path parameters:nil success:^(AFHTTPRequestOperation *operation, id responseObject) {
433 | if (success) {
434 | success((AFJSONRequestOperation *)operation, responseObject);
435 | }
436 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
437 | if (failure) {
438 | failure((AFJSONRequestOperation *)operation, error);
439 | }
440 | }];
441 | }
442 |
443 |
444 | - (void)archiveCompletedTasksInList:(CDKList *)list success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure {
445 | NSString *path = [NSString stringWithFormat:@"lists/%@/tasks/archive_completed", list.remoteID];
446 | [self postPath:path parameters:nil success:^(AFHTTPRequestOperation *operation, id responseObject) {
447 | if (success) {
448 | success((AFJSONRequestOperation *)operation, responseObject);
449 | }
450 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
451 | if (failure) {
452 | failure((AFJSONRequestOperation *)operation, error);
453 | }
454 | }];
455 | }
456 |
457 |
458 | - (void)moveTask:(CDKTask *)task toList:(CDKList *)list success:(CDKHTTPClientSuccess)success failure:(CDKHTTPClientFailure)failure {
459 | NSString *path = [NSString stringWithFormat:@"tasks/%@/move", task.remoteID];
460 | NSDictionary *params = [[NSDictionary alloc] initWithObjectsAndKeys:
461 | list.remoteID, @"task[list_id]",
462 | nil];
463 | [self putPath:path parameters:params success:^(AFHTTPRequestOperation *operation, id responseObject) {
464 | __weak NSManagedObjectContext *context = [CDKTask mainContext];
465 | [context performBlockAndWait:^{
466 | [task unpackDictionary:responseObject];
467 | [task save];
468 | }];
469 |
470 | if (success) {
471 | success((AFJSONRequestOperation *)operation, responseObject);
472 | }
473 | } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
474 | if (failure) {
475 | failure((AFJSONRequestOperation *)operation, error);
476 | }
477 | }];
478 | }
479 |
480 |
481 | #pragma mark - Authentication
482 |
483 | - (void)_userChanged:(NSNotification *)notification {
484 | [self changeUser:[CDKUser currentUser]];
485 | }
486 |
487 |
488 | - (void)changeUser:(CDKUser *)user {
489 | if (user.accessToken) {
490 | [self setDefaultHeader:@"Authorization" value:[NSString stringWithFormat:@"Bearer %@", user.accessToken]];
491 | return;
492 | }
493 |
494 | [self clearAuthorizationHeader];
495 | }
496 |
497 | @end
498 |
--------------------------------------------------------------------------------
/CheddarKit.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 46;
7 | objects = {
8 |
9 | /* Begin PBXBuildFile section */
10 | 21CF86231669036B0052625D /* CDKDefines.h in Headers */ = {isa = PBXBuildFile; fileRef = B208C89915BF68430080705D /* CDKDefines.h */; };
11 | 21CF86241669036B0052625D /* CDKDefines.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C89A15BF68430080705D /* CDKDefines.m */; };
12 | 21CF86251669036B0052625D /* CDKRemoteManagedObject.h in Headers */ = {isa = PBXBuildFile; fileRef = B208C89615BF67C40080705D /* CDKRemoteManagedObject.h */; };
13 | 21CF86261669036B0052625D /* CDKRemoteManagedObject.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C89715BF67C40080705D /* CDKRemoteManagedObject.m */; };
14 | 21CF86271669036B0052625D /* CheddarKit.h in Headers */ = {isa = PBXBuildFile; fileRef = B244409B15BE540D00D4D4CA /* CheddarKit.h */; };
15 | 21CF86281669036B0052625D /* CDKHTTPClient.h in Headers */ = {isa = PBXBuildFile; fileRef = B208C5E115BF655F0080705D /* CDKHTTPClient.h */; };
16 | 21CF86291669036B0052625D /* CDKHTTPClient.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5E215BF655F0080705D /* CDKHTTPClient.m */; };
17 | 21CF862A1669036B0052625D /* CDKList.h in Headers */ = {isa = PBXBuildFile; fileRef = B208C5E315BF655F0080705D /* CDKList.h */; };
18 | 21CF862B1669036B0052625D /* CDKList.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5E415BF655F0080705D /* CDKList.m */; };
19 | 21CF862C1669036B0052625D /* CDKPushController.h in Headers */ = {isa = PBXBuildFile; fileRef = B208C5E515BF655F0080705D /* CDKPushController.h */; };
20 | 21CF862D1669036B0052625D /* CDKPushController.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5E615BF655F0080705D /* CDKPushController.m */; };
21 | 21CF862E1669036B0052625D /* CDKTag.h in Headers */ = {isa = PBXBuildFile; fileRef = B208C5E715BF655F0080705D /* CDKTag.h */; };
22 | 21CF862F1669036B0052625D /* CDKTag.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5E815BF655F0080705D /* CDKTag.m */; };
23 | 21CF86301669036B0052625D /* CDKTask.h in Headers */ = {isa = PBXBuildFile; fileRef = B208C5E915BF655F0080705D /* CDKTask.h */; };
24 | 21CF86311669036B0052625D /* CDKTask.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5EA15BF655F0080705D /* CDKTask.m */; };
25 | 21CF86321669036B0052625D /* CDKUser.h in Headers */ = {isa = PBXBuildFile; fileRef = B208C5EB15BF655F0080705D /* CDKUser.h */; };
26 | 21CF86331669036B0052625D /* CDKUser.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5EC15BF655F0080705D /* CDKUser.m */; };
27 | 21CF86341669036B0052625D /* NSDictionary+CheddarKit.h in Headers */ = {isa = PBXBuildFile; fileRef = B208C5ED15BF655F0080705D /* NSDictionary+CheddarKit.h */; };
28 | 21CF86351669036B0052625D /* NSDictionary+CheddarKit.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5EE15BF655F0080705D /* NSDictionary+CheddarKit.m */; };
29 | 21CF86361669036B0052625D /* NSString+CheddarKit.h in Headers */ = {isa = PBXBuildFile; fileRef = B208C5EF15BF655F0080705D /* NSString+CheddarKit.h */; };
30 | 21CF86371669036B0052625D /* NSString+CheddarKit.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5F015BF655F0080705D /* NSString+CheddarKit.m */; };
31 | 21CF8638166903760052625D /* AFHTTPClient.h in Headers */ = {isa = PBXBuildFile; fileRef = B2287E3916180591001E9E09 /* AFHTTPClient.h */; };
32 | 21CF8639166903760052625D /* AFHTTPClient.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E3A16180591001E9E09 /* AFHTTPClient.m */; };
33 | 21CF863A166903760052625D /* AFHTTPRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = B2287E3B16180591001E9E09 /* AFHTTPRequestOperation.h */; };
34 | 21CF863B166903760052625D /* AFHTTPRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E3C16180591001E9E09 /* AFHTTPRequestOperation.m */; };
35 | 21CF863C166903760052625D /* AFImageRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = B2287E3D16180591001E9E09 /* AFImageRequestOperation.h */; };
36 | 21CF863D166903760052625D /* AFImageRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E3E16180591001E9E09 /* AFImageRequestOperation.m */; };
37 | 21CF863E166903760052625D /* AFJSONRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = B2287E3F16180591001E9E09 /* AFJSONRequestOperation.h */; };
38 | 21CF863F166903760052625D /* AFJSONRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E4016180591001E9E09 /* AFJSONRequestOperation.m */; };
39 | 21CF8640166903760052625D /* AFNetworkActivityIndicatorManager.h in Headers */ = {isa = PBXBuildFile; fileRef = B2287E4116180591001E9E09 /* AFNetworkActivityIndicatorManager.h */; };
40 | 21CF8641166903760052625D /* AFNetworkActivityIndicatorManager.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E4216180591001E9E09 /* AFNetworkActivityIndicatorManager.m */; };
41 | 21CF8642166903760052625D /* AFNetworking.h in Headers */ = {isa = PBXBuildFile; fileRef = B2287E4316180591001E9E09 /* AFNetworking.h */; };
42 | 21CF8643166903760052625D /* AFPropertyListRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = B2287E4416180591001E9E09 /* AFPropertyListRequestOperation.h */; };
43 | 21CF8644166903760052625D /* AFPropertyListRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E4516180591001E9E09 /* AFPropertyListRequestOperation.m */; };
44 | 21CF8645166903760052625D /* AFURLConnectionOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = B2287E4616180591001E9E09 /* AFURLConnectionOperation.h */; };
45 | 21CF8646166903760052625D /* AFURLConnectionOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E4716180591001E9E09 /* AFURLConnectionOperation.m */; };
46 | 21CF8647166903760052625D /* AFXMLRequestOperation.h in Headers */ = {isa = PBXBuildFile; fileRef = B2287E4816180591001E9E09 /* AFXMLRequestOperation.h */; };
47 | 21CF8648166903760052625D /* AFXMLRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E4916180591001E9E09 /* AFXMLRequestOperation.m */; };
48 | 21CF86491669037A0052625D /* NSManagedObjectContext+SSDataKitAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = B28FD2A315BF6F3F00365CD6 /* NSManagedObjectContext+SSDataKitAdditions.h */; };
49 | 21CF864A1669037A0052625D /* NSManagedObjectContext+SSDataKitAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = B28FD2A415BF6F3F00365CD6 /* NSManagedObjectContext+SSDataKitAdditions.m */; };
50 | 21CF864B1669037A0052625D /* SSDataKit.h in Headers */ = {isa = PBXBuildFile; fileRef = B28FD2A615BF6F3F00365CD6 /* SSDataKit.h */; };
51 | 21CF86521669037A0052625D /* SSManagedObject.h in Headers */ = {isa = PBXBuildFile; fileRef = B28FD2AD15BF6F3F00365CD6 /* SSManagedObject.h */; };
52 | 21CF86531669037A0052625D /* SSManagedObject.m in Sources */ = {isa = PBXBuildFile; fileRef = B28FD2AE15BF6F3F00365CD6 /* SSManagedObject.m */; };
53 | 21CF86581669037A0052625D /* SSRemoteManagedObject.h in Headers */ = {isa = PBXBuildFile; fileRef = B28FD2B315BF6F3F00365CD6 /* SSRemoteManagedObject.h */; };
54 | 21CF86591669037A0052625D /* SSRemoteManagedObject.m in Sources */ = {isa = PBXBuildFile; fileRef = B28FD2B415BF6F3F00365CD6 /* SSRemoteManagedObject.m */; };
55 | 21CF865C1669037E0052625D /* SSKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = B208C7E615BF66AE0080705D /* SSKeychain.h */; };
56 | 21CF865D1669037E0052625D /* SSKeychain.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C7E715BF66AE0080705D /* SSKeychain.m */; };
57 | 21CF8677166905710052625D /* Cheddar.xcdatamodeld in Sources */ = {isa = PBXBuildFile; fileRef = 21CF8673166905710052625D /* Cheddar.xcdatamodeld */; };
58 | 21CF867B166906E80052625D /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 21CF867A166906E80052625D /* Cocoa.framework */; };
59 | 21CF867D166907200052625D /* CoreText.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 21CF867C166907200052625D /* CoreText.framework */; };
60 | 21CF867F166907270052625D /* CoreData.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 21CF867E166907270052625D /* CoreData.framework */; };
61 | 21CF86811669072C0052625D /* CFNetwork.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 21CF86801669072C0052625D /* CFNetwork.framework */; };
62 | 21CF8683166907300052625D /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 21CF86821669072F0052625D /* Security.framework */; };
63 | 21CF8685166908190052625D /* libBullyMac.a in Frameworks */ = {isa = PBXBuildFile; fileRef = B208C85315BF66AF0080705D /* libBullyMac.a */; };
64 | 21CF8687166908760052625D /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 21CF8686166908760052625D /* SystemConfiguration.framework */; };
65 | B208C5F115BF655F0080705D /* CDKHTTPClient.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5E215BF655F0080705D /* CDKHTTPClient.m */; };
66 | B208C5F215BF655F0080705D /* CDKList.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5E415BF655F0080705D /* CDKList.m */; };
67 | B208C5F315BF655F0080705D /* CDKPushController.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5E615BF655F0080705D /* CDKPushController.m */; };
68 | B208C5F415BF655F0080705D /* CDKTag.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5E815BF655F0080705D /* CDKTag.m */; };
69 | B208C5F515BF655F0080705D /* CDKTask.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5EA15BF655F0080705D /* CDKTask.m */; };
70 | B208C5F615BF655F0080705D /* CDKUser.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5EC15BF655F0080705D /* CDKUser.m */; };
71 | B208C5F715BF655F0080705D /* NSDictionary+CheddarKit.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5EE15BF655F0080705D /* NSDictionary+CheddarKit.m */; };
72 | B208C5F815BF655F0080705D /* NSString+CheddarKit.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C5F015BF655F0080705D /* NSString+CheddarKit.m */; };
73 | B208C84615BF66AF0080705D /* SSKeychain.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C7E715BF66AE0080705D /* SSKeychain.m */; };
74 | B208C87A15BF66F90080705D /* libBully.a in Frameworks */ = {isa = PBXBuildFile; fileRef = B208C85115BF66AF0080705D /* libBully.a */; };
75 | B208C89815BF67C40080705D /* CDKRemoteManagedObject.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C89715BF67C40080705D /* CDKRemoteManagedObject.m */; };
76 | B208C89B15BF68430080705D /* CDKDefines.m in Sources */ = {isa = PBXBuildFile; fileRef = B208C89A15BF68430080705D /* CDKDefines.m */; };
77 | B2287E7F16180591001E9E09 /* AFHTTPClient.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E3A16180591001E9E09 /* AFHTTPClient.m */; };
78 | B2287E8016180591001E9E09 /* AFHTTPRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E3C16180591001E9E09 /* AFHTTPRequestOperation.m */; };
79 | B2287E8116180591001E9E09 /* AFImageRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E3E16180591001E9E09 /* AFImageRequestOperation.m */; };
80 | B2287E8216180591001E9E09 /* AFJSONRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E4016180591001E9E09 /* AFJSONRequestOperation.m */; };
81 | B2287E8316180591001E9E09 /* AFNetworkActivityIndicatorManager.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E4216180591001E9E09 /* AFNetworkActivityIndicatorManager.m */; };
82 | B2287E8416180591001E9E09 /* AFPropertyListRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E4516180591001E9E09 /* AFPropertyListRequestOperation.m */; };
83 | B2287E8516180591001E9E09 /* AFURLConnectionOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E4716180591001E9E09 /* AFURLConnectionOperation.m */; };
84 | B2287E8616180591001E9E09 /* AFXMLRequestOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E4916180591001E9E09 /* AFXMLRequestOperation.m */; };
85 | B2287E8716180591001E9E09 /* UIImageView+AFNetworking.m in Sources */ = {isa = PBXBuildFile; fileRef = B2287E4B16180591001E9E09 /* UIImageView+AFNetworking.m */; };
86 | B28FD2B515BF6F3F00365CD6 /* NSManagedObjectContext+SSDataKitAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = B28FD2A415BF6F3F00365CD6 /* NSManagedObjectContext+SSDataKitAdditions.m */; };
87 | B28FD2B615BF6F3F00365CD6 /* SSFilterableFetchedResultsController.m in Sources */ = {isa = PBXBuildFile; fileRef = B28FD2A815BF6F3F00365CD6 /* SSFilterableFetchedResultsController.m */; };
88 | B28FD2B715BF6F3F00365CD6 /* SSFilteredResultsFilter.m in Sources */ = {isa = PBXBuildFile; fileRef = B28FD2AA15BF6F3F00365CD6 /* SSFilteredResultsFilter.m */; };
89 | B28FD2B815BF6F3F00365CD6 /* SSFilteredResultsSection.m in Sources */ = {isa = PBXBuildFile; fileRef = B28FD2AC15BF6F3F00365CD6 /* SSFilteredResultsSection.m */; };
90 | B28FD2B915BF6F3F00365CD6 /* SSManagedObject.m in Sources */ = {isa = PBXBuildFile; fileRef = B28FD2AE15BF6F3F00365CD6 /* SSManagedObject.m */; };
91 | B28FD2BA15BF6F3F00365CD6 /* SSManagedTableViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = B28FD2B015BF6F3F00365CD6 /* SSManagedTableViewController.m */; };
92 | B28FD2BB15BF6F3F00365CD6 /* SSManagedViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = B28FD2B215BF6F3F00365CD6 /* SSManagedViewController.m */; };
93 | B28FD2BC15BF6F3F00365CD6 /* SSRemoteManagedObject.m in Sources */ = {isa = PBXBuildFile; fileRef = B28FD2B415BF6F3F00365CD6 /* SSRemoteManagedObject.m */; };
94 | /* End PBXBuildFile section */
95 |
96 | /* Begin PBXContainerItemProxy section */
97 | 21CF8661166903940052625D /* PBXContainerItemProxy */ = {
98 | isa = PBXContainerItemProxy;
99 | containerPortal = B208C66D15BF66AE0080705D /* Bully.xcodeproj */;
100 | proxyType = 1;
101 | remoteGlobalIDString = B2EB6BBB15DB69FC0035AD92;
102 | remoteInfo = BullyMac;
103 | };
104 | B208C85015BF66AF0080705D /* PBXContainerItemProxy */ = {
105 | isa = PBXContainerItemProxy;
106 | containerPortal = B208C66D15BF66AE0080705D /* Bully.xcodeproj */;
107 | proxyType = 2;
108 | remoteGlobalIDString = B2587E4B1579E740009D7B44;
109 | remoteInfo = Bully;
110 | };
111 | B208C85215BF66AF0080705D /* PBXContainerItemProxy */ = {
112 | isa = PBXContainerItemProxy;
113 | containerPortal = B208C66D15BF66AE0080705D /* Bully.xcodeproj */;
114 | proxyType = 2;
115 | remoteGlobalIDString = B2FB4873158AF9B20067FB00;
116 | remoteInfo = BullyMac;
117 | };
118 | B208C87815BF66F10080705D /* PBXContainerItemProxy */ = {
119 | isa = PBXContainerItemProxy;
120 | containerPortal = B208C66D15BF66AE0080705D /* Bully.xcodeproj */;
121 | proxyType = 1;
122 | remoteGlobalIDString = B2587E4A1579E740009D7B44;
123 | remoteInfo = Bully;
124 | };
125 | /* End PBXContainerItemProxy section */
126 |
127 | /* Begin PBXCopyFilesBuildPhase section */
128 | B244408315BE53DC00D4D4CA /* CopyFiles */ = {
129 | isa = PBXCopyFilesBuildPhase;
130 | buildActionMask = 2147483647;
131 | dstPath = "include/${PRODUCT_NAME}";
132 | dstSubfolderSpec = 16;
133 | files = (
134 | );
135 | runOnlyForDeploymentPostprocessing = 0;
136 | };
137 | /* End PBXCopyFilesBuildPhase section */
138 |
139 | /* Begin PBXFileReference section */
140 | 21396B7C17728DA30040FCA2 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/CoreGraphics.framework; sourceTree = DEVELOPER_DIR; };
141 | 21396B7E17728DB20040FCA2 /* Quartz.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Quartz.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/Quartz.framework; sourceTree = DEVELOPER_DIR; };
142 | 21CF86141669035E0052625D /* libCheddarKitMac.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libCheddarKitMac.a; sourceTree = BUILT_PRODUCTS_DIR; };
143 | 21CF8674166905710052625D /* Cheddar 2.xcdatamodel */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcdatamodel; path = "Cheddar 2.xcdatamodel"; sourceTree = ""; };
144 | 21CF8675166905710052625D /* Cheddar.xcdatamodel */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcdatamodel; path = Cheddar.xcdatamodel; sourceTree = ""; };
145 | 21CF8678166905AC0052625D /* CheddarKit-Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CheddarKit-Prefix.pch"; sourceTree = ""; };
146 | 21CF867A166906E80052625D /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/System/Library/Frameworks/Cocoa.framework; sourceTree = DEVELOPER_DIR; };
147 | 21CF867C166907200052625D /* CoreText.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreText.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/System/Library/Frameworks/CoreText.framework; sourceTree = DEVELOPER_DIR; };
148 | 21CF867E166907270052625D /* CoreData.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreData.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/System/Library/Frameworks/CoreData.framework; sourceTree = DEVELOPER_DIR; };
149 | 21CF86801669072C0052625D /* CFNetwork.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CFNetwork.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/System/Library/Frameworks/CFNetwork.framework; sourceTree = DEVELOPER_DIR; };
150 | 21CF86821669072F0052625D /* Security.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Security.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/System/Library/Frameworks/Security.framework; sourceTree = DEVELOPER_DIR; };
151 | 21CF8686166908760052625D /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/System/Library/Frameworks/SystemConfiguration.framework; sourceTree = DEVELOPER_DIR; };
152 | B208C5E115BF655F0080705D /* CDKHTTPClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CDKHTTPClient.h; sourceTree = ""; };
153 | B208C5E215BF655F0080705D /* CDKHTTPClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CDKHTTPClient.m; sourceTree = ""; };
154 | B208C5E315BF655F0080705D /* CDKList.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CDKList.h; sourceTree = ""; };
155 | B208C5E415BF655F0080705D /* CDKList.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CDKList.m; sourceTree = ""; };
156 | B208C5E515BF655F0080705D /* CDKPushController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CDKPushController.h; sourceTree = ""; };
157 | B208C5E615BF655F0080705D /* CDKPushController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CDKPushController.m; sourceTree = ""; };
158 | B208C5E715BF655F0080705D /* CDKTag.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CDKTag.h; sourceTree = ""; };
159 | B208C5E815BF655F0080705D /* CDKTag.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CDKTag.m; sourceTree = ""; };
160 | B208C5E915BF655F0080705D /* CDKTask.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CDKTask.h; sourceTree = ""; };
161 | B208C5EA15BF655F0080705D /* CDKTask.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CDKTask.m; sourceTree = ""; };
162 | B208C5EB15BF655F0080705D /* CDKUser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CDKUser.h; sourceTree = ""; };
163 | B208C5EC15BF655F0080705D /* CDKUser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CDKUser.m; sourceTree = ""; };
164 | B208C5ED15BF655F0080705D /* NSDictionary+CheddarKit.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSDictionary+CheddarKit.h"; sourceTree = ""; };
165 | B208C5EE15BF655F0080705D /* NSDictionary+CheddarKit.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSDictionary+CheddarKit.m"; sourceTree = ""; };
166 | B208C5EF15BF655F0080705D /* NSString+CheddarKit.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSString+CheddarKit.h"; sourceTree = ""; };
167 | B208C5F015BF655F0080705D /* NSString+CheddarKit.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSString+CheddarKit.m"; sourceTree = ""; };
168 | B208C66D15BF66AE0080705D /* Bully.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; path = Bully.xcodeproj; sourceTree = ""; };
169 | B208C7E615BF66AE0080705D /* SSKeychain.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSKeychain.h; sourceTree = ""; };
170 | B208C7E715BF66AE0080705D /* SSKeychain.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SSKeychain.m; sourceTree = ""; };
171 | B208C89615BF67C40080705D /* CDKRemoteManagedObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CDKRemoteManagedObject.h; sourceTree = ""; };
172 | B208C89715BF67C40080705D /* CDKRemoteManagedObject.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CDKRemoteManagedObject.m; sourceTree = ""; };
173 | B208C89915BF68430080705D /* CDKDefines.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CDKDefines.h; sourceTree = ""; };
174 | B208C89A15BF68430080705D /* CDKDefines.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CDKDefines.m; sourceTree = ""; };
175 | B2287E3916180591001E9E09 /* AFHTTPClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFHTTPClient.h; sourceTree = ""; };
176 | B2287E3A16180591001E9E09 /* AFHTTPClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFHTTPClient.m; sourceTree = ""; };
177 | B2287E3B16180591001E9E09 /* AFHTTPRequestOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFHTTPRequestOperation.h; sourceTree = ""; };
178 | B2287E3C16180591001E9E09 /* AFHTTPRequestOperation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFHTTPRequestOperation.m; sourceTree = ""; };
179 | B2287E3D16180591001E9E09 /* AFImageRequestOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFImageRequestOperation.h; sourceTree = ""; };
180 | B2287E3E16180591001E9E09 /* AFImageRequestOperation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFImageRequestOperation.m; sourceTree = ""; };
181 | B2287E3F16180591001E9E09 /* AFJSONRequestOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFJSONRequestOperation.h; sourceTree = ""; };
182 | B2287E4016180591001E9E09 /* AFJSONRequestOperation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFJSONRequestOperation.m; sourceTree = ""; };
183 | B2287E4116180591001E9E09 /* AFNetworkActivityIndicatorManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFNetworkActivityIndicatorManager.h; sourceTree = ""; };
184 | B2287E4216180591001E9E09 /* AFNetworkActivityIndicatorManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFNetworkActivityIndicatorManager.m; sourceTree = ""; };
185 | B2287E4316180591001E9E09 /* AFNetworking.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFNetworking.h; sourceTree = ""; };
186 | B2287E4416180591001E9E09 /* AFPropertyListRequestOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFPropertyListRequestOperation.h; sourceTree = ""; };
187 | B2287E4516180591001E9E09 /* AFPropertyListRequestOperation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFPropertyListRequestOperation.m; sourceTree = ""; };
188 | B2287E4616180591001E9E09 /* AFURLConnectionOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFURLConnectionOperation.h; sourceTree = ""; };
189 | B2287E4716180591001E9E09 /* AFURLConnectionOperation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFURLConnectionOperation.m; sourceTree = ""; };
190 | B2287E4816180591001E9E09 /* AFXMLRequestOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AFXMLRequestOperation.h; sourceTree = ""; };
191 | B2287E4916180591001E9E09 /* AFXMLRequestOperation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AFXMLRequestOperation.m; sourceTree = ""; };
192 | B2287E4A16180591001E9E09 /* UIImageView+AFNetworking.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIImageView+AFNetworking.h"; sourceTree = ""; };
193 | B2287E4B16180591001E9E09 /* UIImageView+AFNetworking.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIImageView+AFNetworking.m"; sourceTree = ""; };
194 | B244408515BE53DC00D4D4CA /* libCheddarKit.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libCheddarKit.a; sourceTree = BUILT_PRODUCTS_DIR; };
195 | B244409B15BE540D00D4D4CA /* CheddarKit.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CheddarKit.h; sourceTree = ""; };
196 | B28FD2A315BF6F3F00365CD6 /* NSManagedObjectContext+SSDataKitAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSManagedObjectContext+SSDataKitAdditions.h"; sourceTree = ""; };
197 | B28FD2A415BF6F3F00365CD6 /* NSManagedObjectContext+SSDataKitAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSManagedObjectContext+SSDataKitAdditions.m"; sourceTree = ""; };
198 | B28FD2A615BF6F3F00365CD6 /* SSDataKit.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSDataKit.h; sourceTree = ""; };
199 | B28FD2A715BF6F3F00365CD6 /* SSFilterableFetchedResultsController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSFilterableFetchedResultsController.h; sourceTree = ""; };
200 | B28FD2A815BF6F3F00365CD6 /* SSFilterableFetchedResultsController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SSFilterableFetchedResultsController.m; sourceTree = ""; };
201 | B28FD2A915BF6F3F00365CD6 /* SSFilteredResultsFilter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSFilteredResultsFilter.h; sourceTree = ""; };
202 | B28FD2AA15BF6F3F00365CD6 /* SSFilteredResultsFilter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SSFilteredResultsFilter.m; sourceTree = ""; };
203 | B28FD2AB15BF6F3F00365CD6 /* SSFilteredResultsSection.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSFilteredResultsSection.h; sourceTree = ""; };
204 | B28FD2AC15BF6F3F00365CD6 /* SSFilteredResultsSection.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SSFilteredResultsSection.m; sourceTree = ""; };
205 | B28FD2AD15BF6F3F00365CD6 /* SSManagedObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSManagedObject.h; sourceTree = ""; };
206 | B28FD2AE15BF6F3F00365CD6 /* SSManagedObject.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SSManagedObject.m; sourceTree = ""; };
207 | B28FD2AF15BF6F3F00365CD6 /* SSManagedTableViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSManagedTableViewController.h; sourceTree = ""; };
208 | B28FD2B015BF6F3F00365CD6 /* SSManagedTableViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SSManagedTableViewController.m; sourceTree = ""; };
209 | B28FD2B115BF6F3F00365CD6 /* SSManagedViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSManagedViewController.h; sourceTree = ""; };
210 | B28FD2B215BF6F3F00365CD6 /* SSManagedViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SSManagedViewController.m; sourceTree = ""; };
211 | B28FD2B315BF6F3F00365CD6 /* SSRemoteManagedObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSRemoteManagedObject.h; sourceTree = ""; };
212 | B28FD2B415BF6F3F00365CD6 /* SSRemoteManagedObject.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SSRemoteManagedObject.m; sourceTree = ""; };
213 | /* End PBXFileReference section */
214 |
215 | /* Begin PBXFrameworksBuildPhase section */
216 | 21CF86111669035E0052625D /* Frameworks */ = {
217 | isa = PBXFrameworksBuildPhase;
218 | buildActionMask = 2147483647;
219 | files = (
220 | 21CF8687166908760052625D /* SystemConfiguration.framework in Frameworks */,
221 | 21CF8685166908190052625D /* libBullyMac.a in Frameworks */,
222 | 21CF8683166907300052625D /* Security.framework in Frameworks */,
223 | 21CF86811669072C0052625D /* CFNetwork.framework in Frameworks */,
224 | 21CF867F166907270052625D /* CoreData.framework in Frameworks */,
225 | 21CF867D166907200052625D /* CoreText.framework in Frameworks */,
226 | 21CF867B166906E80052625D /* Cocoa.framework in Frameworks */,
227 | );
228 | runOnlyForDeploymentPostprocessing = 0;
229 | };
230 | B244408215BE53DC00D4D4CA /* Frameworks */ = {
231 | isa = PBXFrameworksBuildPhase;
232 | buildActionMask = 2147483647;
233 | files = (
234 | B208C87A15BF66F90080705D /* libBully.a in Frameworks */,
235 | );
236 | runOnlyForDeploymentPostprocessing = 0;
237 | };
238 | /* End PBXFrameworksBuildPhase section */
239 |
240 | /* Begin PBXGroup section */
241 | 21CF8672166905710052625D /* Other Sources */ = {
242 | isa = PBXGroup;
243 | children = (
244 | 21CF8678166905AC0052625D /* CheddarKit-Prefix.pch */,
245 | 21CF8673166905710052625D /* Cheddar.xcdatamodeld */,
246 | );
247 | path = "Other Sources";
248 | sourceTree = "";
249 | };
250 | 21CF868B1669089D0052625D /* Frameworks */ = {
251 | isa = PBXGroup;
252 | children = (
253 | 21396B7E17728DB20040FCA2 /* Quartz.framework */,
254 | 21396B7C17728DA30040FCA2 /* CoreGraphics.framework */,
255 | 21CF8686166908760052625D /* SystemConfiguration.framework */,
256 | 21CF86821669072F0052625D /* Security.framework */,
257 | 21CF86801669072C0052625D /* CFNetwork.framework */,
258 | 21CF867E166907270052625D /* CoreData.framework */,
259 | 21CF867C166907200052625D /* CoreText.framework */,
260 | 21CF867A166906E80052625D /* Cocoa.framework */,
261 | );
262 | name = Frameworks;
263 | sourceTree = "";
264 | };
265 | B208C5FD15BF66AE0080705D /* Vendor */ = {
266 | isa = PBXGroup;
267 | children = (
268 | B2287E3716180591001E9E09 /* AFNetworking */,
269 | B28FD2A215BF6F3F00365CD6 /* SSDataKit */,
270 | B208C66115BF66AE0080705D /* Bully */,
271 | B208C7E015BF66AE0080705D /* SSKeychain */,
272 | );
273 | name = Vendor;
274 | path = CheddarKit/Vendor;
275 | sourceTree = "";
276 | };
277 | B208C66115BF66AE0080705D /* Bully */ = {
278 | isa = PBXGroup;
279 | children = (
280 | B208C66D15BF66AE0080705D /* Bully.xcodeproj */,
281 | );
282 | path = Bully;
283 | sourceTree = "";
284 | };
285 | B208C66E15BF66AE0080705D /* Products */ = {
286 | isa = PBXGroup;
287 | children = (
288 | B208C85115BF66AF0080705D /* libBully.a */,
289 | B208C85315BF66AF0080705D /* libBullyMac.a */,
290 | );
291 | name = Products;
292 | sourceTree = "";
293 | };
294 | B208C7E015BF66AE0080705D /* SSKeychain */ = {
295 | isa = PBXGroup;
296 | children = (
297 | B208C7E615BF66AE0080705D /* SSKeychain.h */,
298 | B208C7E715BF66AE0080705D /* SSKeychain.m */,
299 | );
300 | path = SSKeychain;
301 | sourceTree = "";
302 | };
303 | B2287E3716180591001E9E09 /* AFNetworking */ = {
304 | isa = PBXGroup;
305 | children = (
306 | B2287E3816180591001E9E09 /* AFNetworking */,
307 | );
308 | path = AFNetworking;
309 | sourceTree = "";
310 | };
311 | B2287E3816180591001E9E09 /* AFNetworking */ = {
312 | isa = PBXGroup;
313 | children = (
314 | B2287E3916180591001E9E09 /* AFHTTPClient.h */,
315 | B2287E3A16180591001E9E09 /* AFHTTPClient.m */,
316 | B2287E3B16180591001E9E09 /* AFHTTPRequestOperation.h */,
317 | B2287E3C16180591001E9E09 /* AFHTTPRequestOperation.m */,
318 | B2287E3D16180591001E9E09 /* AFImageRequestOperation.h */,
319 | B2287E3E16180591001E9E09 /* AFImageRequestOperation.m */,
320 | B2287E3F16180591001E9E09 /* AFJSONRequestOperation.h */,
321 | B2287E4016180591001E9E09 /* AFJSONRequestOperation.m */,
322 | B2287E4116180591001E9E09 /* AFNetworkActivityIndicatorManager.h */,
323 | B2287E4216180591001E9E09 /* AFNetworkActivityIndicatorManager.m */,
324 | B2287E4316180591001E9E09 /* AFNetworking.h */,
325 | B2287E4416180591001E9E09 /* AFPropertyListRequestOperation.h */,
326 | B2287E4516180591001E9E09 /* AFPropertyListRequestOperation.m */,
327 | B2287E4616180591001E9E09 /* AFURLConnectionOperation.h */,
328 | B2287E4716180591001E9E09 /* AFURLConnectionOperation.m */,
329 | B2287E4816180591001E9E09 /* AFXMLRequestOperation.h */,
330 | B2287E4916180591001E9E09 /* AFXMLRequestOperation.m */,
331 | B2287E4A16180591001E9E09 /* UIImageView+AFNetworking.h */,
332 | B2287E4B16180591001E9E09 /* UIImageView+AFNetworking.m */,
333 | );
334 | path = AFNetworking;
335 | sourceTree = "";
336 | };
337 | B244407A15BE53DC00D4D4CA = {
338 | isa = PBXGroup;
339 | children = (
340 | B244409A15BE540D00D4D4CA /* CheddarKit */,
341 | 21CF8672166905710052625D /* Other Sources */,
342 | B208C5FD15BF66AE0080705D /* Vendor */,
343 | 21CF868B1669089D0052625D /* Frameworks */,
344 | B244408615BE53DC00D4D4CA /* Products */,
345 | );
346 | sourceTree = "";
347 | };
348 | B244408615BE53DC00D4D4CA /* Products */ = {
349 | isa = PBXGroup;
350 | children = (
351 | B244408515BE53DC00D4D4CA /* libCheddarKit.a */,
352 | 21CF86141669035E0052625D /* libCheddarKitMac.a */,
353 | );
354 | name = Products;
355 | sourceTree = "";
356 | };
357 | B244409A15BE540D00D4D4CA /* CheddarKit */ = {
358 | isa = PBXGroup;
359 | children = (
360 | B208C89915BF68430080705D /* CDKDefines.h */,
361 | B208C89A15BF68430080705D /* CDKDefines.m */,
362 | B208C89615BF67C40080705D /* CDKRemoteManagedObject.h */,
363 | B208C89715BF67C40080705D /* CDKRemoteManagedObject.m */,
364 | B244409B15BE540D00D4D4CA /* CheddarKit.h */,
365 | B208C5E115BF655F0080705D /* CDKHTTPClient.h */,
366 | B208C5E215BF655F0080705D /* CDKHTTPClient.m */,
367 | B208C5E315BF655F0080705D /* CDKList.h */,
368 | B208C5E415BF655F0080705D /* CDKList.m */,
369 | B208C5E515BF655F0080705D /* CDKPushController.h */,
370 | B208C5E615BF655F0080705D /* CDKPushController.m */,
371 | B208C5E715BF655F0080705D /* CDKTag.h */,
372 | B208C5E815BF655F0080705D /* CDKTag.m */,
373 | B208C5E915BF655F0080705D /* CDKTask.h */,
374 | B208C5EA15BF655F0080705D /* CDKTask.m */,
375 | B208C5EB15BF655F0080705D /* CDKUser.h */,
376 | B208C5EC15BF655F0080705D /* CDKUser.m */,
377 | B208C5ED15BF655F0080705D /* NSDictionary+CheddarKit.h */,
378 | B208C5EE15BF655F0080705D /* NSDictionary+CheddarKit.m */,
379 | B208C5EF15BF655F0080705D /* NSString+CheddarKit.h */,
380 | B208C5F015BF655F0080705D /* NSString+CheddarKit.m */,
381 | );
382 | path = CheddarKit;
383 | sourceTree = "";
384 | };
385 | B28FD2A215BF6F3F00365CD6 /* SSDataKit */ = {
386 | isa = PBXGroup;
387 | children = (
388 | B28FD2A315BF6F3F00365CD6 /* NSManagedObjectContext+SSDataKitAdditions.h */,
389 | B28FD2A415BF6F3F00365CD6 /* NSManagedObjectContext+SSDataKitAdditions.m */,
390 | B28FD2A615BF6F3F00365CD6 /* SSDataKit.h */,
391 | B28FD2A715BF6F3F00365CD6 /* SSFilterableFetchedResultsController.h */,
392 | B28FD2A815BF6F3F00365CD6 /* SSFilterableFetchedResultsController.m */,
393 | B28FD2A915BF6F3F00365CD6 /* SSFilteredResultsFilter.h */,
394 | B28FD2AA15BF6F3F00365CD6 /* SSFilteredResultsFilter.m */,
395 | B28FD2AB15BF6F3F00365CD6 /* SSFilteredResultsSection.h */,
396 | B28FD2AC15BF6F3F00365CD6 /* SSFilteredResultsSection.m */,
397 | B28FD2AD15BF6F3F00365CD6 /* SSManagedObject.h */,
398 | B28FD2AE15BF6F3F00365CD6 /* SSManagedObject.m */,
399 | B28FD2AF15BF6F3F00365CD6 /* SSManagedTableViewController.h */,
400 | B28FD2B015BF6F3F00365CD6 /* SSManagedTableViewController.m */,
401 | B28FD2B115BF6F3F00365CD6 /* SSManagedViewController.h */,
402 | B28FD2B215BF6F3F00365CD6 /* SSManagedViewController.m */,
403 | B28FD2B315BF6F3F00365CD6 /* SSRemoteManagedObject.h */,
404 | B28FD2B415BF6F3F00365CD6 /* SSRemoteManagedObject.m */,
405 | );
406 | path = SSDataKit;
407 | sourceTree = "";
408 | };
409 | /* End PBXGroup section */
410 |
411 | /* Begin PBXHeadersBuildPhase section */
412 | 21CF86121669035E0052625D /* Headers */ = {
413 | isa = PBXHeadersBuildPhase;
414 | buildActionMask = 2147483647;
415 | files = (
416 | 21CF86231669036B0052625D /* CDKDefines.h in Headers */,
417 | 21CF86251669036B0052625D /* CDKRemoteManagedObject.h in Headers */,
418 | 21CF86271669036B0052625D /* CheddarKit.h in Headers */,
419 | 21CF86281669036B0052625D /* CDKHTTPClient.h in Headers */,
420 | 21CF862A1669036B0052625D /* CDKList.h in Headers */,
421 | 21CF862C1669036B0052625D /* CDKPushController.h in Headers */,
422 | 21CF862E1669036B0052625D /* CDKTag.h in Headers */,
423 | 21CF86301669036B0052625D /* CDKTask.h in Headers */,
424 | 21CF86321669036B0052625D /* CDKUser.h in Headers */,
425 | 21CF86341669036B0052625D /* NSDictionary+CheddarKit.h in Headers */,
426 | 21CF86361669036B0052625D /* NSString+CheddarKit.h in Headers */,
427 | 21CF8638166903760052625D /* AFHTTPClient.h in Headers */,
428 | 21CF863A166903760052625D /* AFHTTPRequestOperation.h in Headers */,
429 | 21CF863C166903760052625D /* AFImageRequestOperation.h in Headers */,
430 | 21CF863E166903760052625D /* AFJSONRequestOperation.h in Headers */,
431 | 21CF8640166903760052625D /* AFNetworkActivityIndicatorManager.h in Headers */,
432 | 21CF8642166903760052625D /* AFNetworking.h in Headers */,
433 | 21CF8643166903760052625D /* AFPropertyListRequestOperation.h in Headers */,
434 | 21CF8645166903760052625D /* AFURLConnectionOperation.h in Headers */,
435 | 21CF8647166903760052625D /* AFXMLRequestOperation.h in Headers */,
436 | 21CF86491669037A0052625D /* NSManagedObjectContext+SSDataKitAdditions.h in Headers */,
437 | 21CF864B1669037A0052625D /* SSDataKit.h in Headers */,
438 | 21CF86521669037A0052625D /* SSManagedObject.h in Headers */,
439 | 21CF86581669037A0052625D /* SSRemoteManagedObject.h in Headers */,
440 | 21CF865C1669037E0052625D /* SSKeychain.h in Headers */,
441 | );
442 | runOnlyForDeploymentPostprocessing = 0;
443 | };
444 | /* End PBXHeadersBuildPhase section */
445 |
446 | /* Begin PBXNativeTarget section */
447 | 21CF86131669035E0052625D /* CheddarKitMac */ = {
448 | isa = PBXNativeTarget;
449 | buildConfigurationList = 21CF86201669035E0052625D /* Build configuration list for PBXNativeTarget "CheddarKitMac" */;
450 | buildPhases = (
451 | 21CF86101669035E0052625D /* Sources */,
452 | 21CF86111669035E0052625D /* Frameworks */,
453 | 21CF86121669035E0052625D /* Headers */,
454 | );
455 | buildRules = (
456 | );
457 | dependencies = (
458 | 21CF8662166903940052625D /* PBXTargetDependency */,
459 | );
460 | name = CheddarKitMac;
461 | productName = CheddarKitMac;
462 | productReference = 21CF86141669035E0052625D /* libCheddarKitMac.a */;
463 | productType = "com.apple.product-type.library.static";
464 | };
465 | B244408415BE53DC00D4D4CA /* CheddarKit */ = {
466 | isa = PBXNativeTarget;
467 | buildConfigurationList = B244409315BE53DC00D4D4CA /* Build configuration list for PBXNativeTarget "CheddarKit" */;
468 | buildPhases = (
469 | B244408115BE53DC00D4D4CA /* Sources */,
470 | B244408215BE53DC00D4D4CA /* Frameworks */,
471 | B244408315BE53DC00D4D4CA /* CopyFiles */,
472 | );
473 | buildRules = (
474 | );
475 | dependencies = (
476 | B208C87915BF66F10080705D /* PBXTargetDependency */,
477 | );
478 | name = CheddarKit;
479 | productName = CheddarKit;
480 | productReference = B244408515BE53DC00D4D4CA /* libCheddarKit.a */;
481 | productType = "com.apple.product-type.library.static";
482 | };
483 | /* End PBXNativeTarget section */
484 |
485 | /* Begin PBXProject section */
486 | B244407C15BE53DC00D4D4CA /* Project object */ = {
487 | isa = PBXProject;
488 | attributes = {
489 | CLASSPREFIX = CDK;
490 | LastUpgradeCheck = 0500;
491 | ORGANIZATIONNAME = "Nothing Magical";
492 | };
493 | buildConfigurationList = B244407F15BE53DC00D4D4CA /* Build configuration list for PBXProject "CheddarKit" */;
494 | compatibilityVersion = "Xcode 3.2";
495 | developmentRegion = English;
496 | hasScannedForEncodings = 0;
497 | knownRegions = (
498 | en,
499 | );
500 | mainGroup = B244407A15BE53DC00D4D4CA;
501 | productRefGroup = B244408615BE53DC00D4D4CA /* Products */;
502 | projectDirPath = "";
503 | projectReferences = (
504 | {
505 | ProductGroup = B208C66E15BF66AE0080705D /* Products */;
506 | ProjectRef = B208C66D15BF66AE0080705D /* Bully.xcodeproj */;
507 | },
508 | );
509 | projectRoot = "";
510 | targets = (
511 | B244408415BE53DC00D4D4CA /* CheddarKit */,
512 | 21CF86131669035E0052625D /* CheddarKitMac */,
513 | );
514 | };
515 | /* End PBXProject section */
516 |
517 | /* Begin PBXReferenceProxy section */
518 | B208C85115BF66AF0080705D /* libBully.a */ = {
519 | isa = PBXReferenceProxy;
520 | fileType = archive.ar;
521 | path = libBully.a;
522 | remoteRef = B208C85015BF66AF0080705D /* PBXContainerItemProxy */;
523 | sourceTree = BUILT_PRODUCTS_DIR;
524 | };
525 | B208C85315BF66AF0080705D /* libBullyMac.a */ = {
526 | isa = PBXReferenceProxy;
527 | fileType = archive.ar;
528 | path = libBullyMac.a;
529 | remoteRef = B208C85215BF66AF0080705D /* PBXContainerItemProxy */;
530 | sourceTree = BUILT_PRODUCTS_DIR;
531 | };
532 | /* End PBXReferenceProxy section */
533 |
534 | /* Begin PBXSourcesBuildPhase section */
535 | 21CF86101669035E0052625D /* Sources */ = {
536 | isa = PBXSourcesBuildPhase;
537 | buildActionMask = 2147483647;
538 | files = (
539 | 21CF86241669036B0052625D /* CDKDefines.m in Sources */,
540 | 21CF86261669036B0052625D /* CDKRemoteManagedObject.m in Sources */,
541 | 21CF86291669036B0052625D /* CDKHTTPClient.m in Sources */,
542 | 21CF862B1669036B0052625D /* CDKList.m in Sources */,
543 | 21CF862D1669036B0052625D /* CDKPushController.m in Sources */,
544 | 21CF862F1669036B0052625D /* CDKTag.m in Sources */,
545 | 21CF86311669036B0052625D /* CDKTask.m in Sources */,
546 | 21CF86331669036B0052625D /* CDKUser.m in Sources */,
547 | 21CF86351669036B0052625D /* NSDictionary+CheddarKit.m in Sources */,
548 | 21CF86371669036B0052625D /* NSString+CheddarKit.m in Sources */,
549 | 21CF8639166903760052625D /* AFHTTPClient.m in Sources */,
550 | 21CF863B166903760052625D /* AFHTTPRequestOperation.m in Sources */,
551 | 21CF863D166903760052625D /* AFImageRequestOperation.m in Sources */,
552 | 21CF863F166903760052625D /* AFJSONRequestOperation.m in Sources */,
553 | 21CF8641166903760052625D /* AFNetworkActivityIndicatorManager.m in Sources */,
554 | 21CF8644166903760052625D /* AFPropertyListRequestOperation.m in Sources */,
555 | 21CF8646166903760052625D /* AFURLConnectionOperation.m in Sources */,
556 | 21CF8648166903760052625D /* AFXMLRequestOperation.m in Sources */,
557 | 21CF864A1669037A0052625D /* NSManagedObjectContext+SSDataKitAdditions.m in Sources */,
558 | 21CF86531669037A0052625D /* SSManagedObject.m in Sources */,
559 | 21CF86591669037A0052625D /* SSRemoteManagedObject.m in Sources */,
560 | 21CF865D1669037E0052625D /* SSKeychain.m in Sources */,
561 | );
562 | runOnlyForDeploymentPostprocessing = 0;
563 | };
564 | B244408115BE53DC00D4D4CA /* Sources */ = {
565 | isa = PBXSourcesBuildPhase;
566 | buildActionMask = 2147483647;
567 | files = (
568 | B208C5F115BF655F0080705D /* CDKHTTPClient.m in Sources */,
569 | B208C5F215BF655F0080705D /* CDKList.m in Sources */,
570 | B208C5F315BF655F0080705D /* CDKPushController.m in Sources */,
571 | B208C5F415BF655F0080705D /* CDKTag.m in Sources */,
572 | B208C5F515BF655F0080705D /* CDKTask.m in Sources */,
573 | B208C5F615BF655F0080705D /* CDKUser.m in Sources */,
574 | B208C5F715BF655F0080705D /* NSDictionary+CheddarKit.m in Sources */,
575 | B208C5F815BF655F0080705D /* NSString+CheddarKit.m in Sources */,
576 | B208C84615BF66AF0080705D /* SSKeychain.m in Sources */,
577 | B208C89815BF67C40080705D /* CDKRemoteManagedObject.m in Sources */,
578 | B208C89B15BF68430080705D /* CDKDefines.m in Sources */,
579 | B28FD2B515BF6F3F00365CD6 /* NSManagedObjectContext+SSDataKitAdditions.m in Sources */,
580 | B28FD2B615BF6F3F00365CD6 /* SSFilterableFetchedResultsController.m in Sources */,
581 | B28FD2B715BF6F3F00365CD6 /* SSFilteredResultsFilter.m in Sources */,
582 | B28FD2B815BF6F3F00365CD6 /* SSFilteredResultsSection.m in Sources */,
583 | B28FD2B915BF6F3F00365CD6 /* SSManagedObject.m in Sources */,
584 | B28FD2BA15BF6F3F00365CD6 /* SSManagedTableViewController.m in Sources */,
585 | B28FD2BB15BF6F3F00365CD6 /* SSManagedViewController.m in Sources */,
586 | B28FD2BC15BF6F3F00365CD6 /* SSRemoteManagedObject.m in Sources */,
587 | B2287E7F16180591001E9E09 /* AFHTTPClient.m in Sources */,
588 | B2287E8016180591001E9E09 /* AFHTTPRequestOperation.m in Sources */,
589 | B2287E8116180591001E9E09 /* AFImageRequestOperation.m in Sources */,
590 | B2287E8216180591001E9E09 /* AFJSONRequestOperation.m in Sources */,
591 | B2287E8316180591001E9E09 /* AFNetworkActivityIndicatorManager.m in Sources */,
592 | B2287E8416180591001E9E09 /* AFPropertyListRequestOperation.m in Sources */,
593 | B2287E8516180591001E9E09 /* AFURLConnectionOperation.m in Sources */,
594 | B2287E8616180591001E9E09 /* AFXMLRequestOperation.m in Sources */,
595 | B2287E8716180591001E9E09 /* UIImageView+AFNetworking.m in Sources */,
596 | 21CF8677166905710052625D /* Cheddar.xcdatamodeld in Sources */,
597 | );
598 | runOnlyForDeploymentPostprocessing = 0;
599 | };
600 | /* End PBXSourcesBuildPhase section */
601 |
602 | /* Begin PBXTargetDependency section */
603 | 21CF8662166903940052625D /* PBXTargetDependency */ = {
604 | isa = PBXTargetDependency;
605 | name = BullyMac;
606 | targetProxy = 21CF8661166903940052625D /* PBXContainerItemProxy */;
607 | };
608 | B208C87915BF66F10080705D /* PBXTargetDependency */ = {
609 | isa = PBXTargetDependency;
610 | name = Bully;
611 | targetProxy = B208C87815BF66F10080705D /* PBXContainerItemProxy */;
612 | };
613 | /* End PBXTargetDependency section */
614 |
615 | /* Begin XCBuildConfiguration section */
616 | 21CF86211669035E0052625D /* Debug */ = {
617 | isa = XCBuildConfiguration;
618 | buildSettings = {
619 | CLANG_WARN_EMPTY_BODY = YES;
620 | GCC_ENABLE_OBJC_EXCEPTIONS = YES;
621 | GCC_PRECOMPILE_PREFIX_HEADER = YES;
622 | GCC_PREFIX_HEADER = "Other Sources/CheddarKit-Prefix.pch";
623 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
624 | HEADER_SEARCH_PATHS = (
625 | "\"$(SRCROOT)/CheddarKit/Vendor/Bully\"/**",
626 | "\"$(SRCROOT)/CheddarKit/Vendor/SSDataKit\"",
627 | );
628 | ONLY_ACTIVE_ARCH = YES;
629 | OTHER_LDFLAGS = (
630 | "-ObjC",
631 | "-all_load",
632 | );
633 | PRODUCT_NAME = "$(TARGET_NAME)";
634 | SDKROOT = macosx;
635 | SKIP_INSTALL = YES;
636 | };
637 | name = Debug;
638 | };
639 | 21CF86221669035E0052625D /* Release */ = {
640 | isa = XCBuildConfiguration;
641 | buildSettings = {
642 | CLANG_WARN_EMPTY_BODY = YES;
643 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
644 | GCC_ENABLE_OBJC_EXCEPTIONS = YES;
645 | GCC_PRECOMPILE_PREFIX_HEADER = YES;
646 | GCC_PREFIX_HEADER = "Other Sources/CheddarKit-Prefix.pch";
647 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
648 | HEADER_SEARCH_PATHS = (
649 | "\"$(SRCROOT)/CheddarKit/Vendor/Bully\"/**",
650 | "\"$(SRCROOT)/CheddarKit/Vendor/SSDataKit\"",
651 | );
652 | OTHER_LDFLAGS = (
653 | "-ObjC",
654 | "-all_load",
655 | );
656 | PRODUCT_NAME = "$(TARGET_NAME)";
657 | SDKROOT = macosx;
658 | SKIP_INSTALL = YES;
659 | };
660 | name = Release;
661 | };
662 | B244409115BE53DC00D4D4CA /* Debug */ = {
663 | isa = XCBuildConfiguration;
664 | buildSettings = {
665 | ALWAYS_SEARCH_USER_PATHS = NO;
666 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
667 | CLANG_CXX_LIBRARY = "libc++";
668 | CLANG_ENABLE_OBJC_ARC = YES;
669 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
670 | COPY_PHASE_STRIP = NO;
671 | GCC_C_LANGUAGE_STANDARD = gnu99;
672 | GCC_DYNAMIC_NO_PIC = NO;
673 | GCC_OPTIMIZATION_LEVEL = 0;
674 | GCC_PREPROCESSOR_DEFINITIONS = (
675 | "DEBUG=1",
676 | "$(inherited)",
677 | );
678 | GCC_SYMBOLS_PRIVATE_EXTERN = NO;
679 | GCC_WARN_ABOUT_RETURN_TYPE = YES;
680 | GCC_WARN_UNINITIALIZED_AUTOS = YES;
681 | GCC_WARN_UNUSED_VARIABLE = YES;
682 | IPHONEOS_DEPLOYMENT_TARGET = 6.0;
683 | MACOSX_DEPLOYMENT_TARGET = 10.7;
684 | ONLY_ACTIVE_ARCH = YES;
685 | SDKROOT = iphoneos;
686 | };
687 | name = Debug;
688 | };
689 | B244409215BE53DC00D4D4CA /* Release */ = {
690 | isa = XCBuildConfiguration;
691 | buildSettings = {
692 | ALWAYS_SEARCH_USER_PATHS = NO;
693 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
694 | CLANG_CXX_LIBRARY = "libc++";
695 | CLANG_ENABLE_OBJC_ARC = YES;
696 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
697 | COPY_PHASE_STRIP = YES;
698 | GCC_C_LANGUAGE_STANDARD = gnu99;
699 | GCC_WARN_ABOUT_RETURN_TYPE = YES;
700 | GCC_WARN_UNINITIALIZED_AUTOS = YES;
701 | GCC_WARN_UNUSED_VARIABLE = YES;
702 | IPHONEOS_DEPLOYMENT_TARGET = 6.0;
703 | MACOSX_DEPLOYMENT_TARGET = 10.7;
704 | SDKROOT = iphoneos;
705 | VALIDATE_PRODUCT = YES;
706 | };
707 | name = Release;
708 | };
709 | B244409415BE53DC00D4D4CA /* Debug */ = {
710 | isa = XCBuildConfiguration;
711 | buildSettings = {
712 | DSTROOT = /tmp/CheddarKit.dst;
713 | HEADER_SEARCH_PATHS = (
714 | "\"$(SRCROOT)/CheddarKit/Vendor/Bully\"/**",
715 | "\"$(SRCROOT)/CheddarKit/Vendor/SSDataKit\"",
716 | );
717 | IPHONEOS_DEPLOYMENT_TARGET = 5.0;
718 | OTHER_LDFLAGS = "-ObjC";
719 | PRODUCT_NAME = "$(TARGET_NAME)";
720 | SKIP_INSTALL = YES;
721 | };
722 | name = Debug;
723 | };
724 | B244409515BE53DC00D4D4CA /* Release */ = {
725 | isa = XCBuildConfiguration;
726 | buildSettings = {
727 | DSTROOT = /tmp/CheddarKit.dst;
728 | HEADER_SEARCH_PATHS = (
729 | "\"$(SRCROOT)/CheddarKit/Vendor/Bully\"/**",
730 | "\"$(SRCROOT)/CheddarKit/Vendor/SSDataKit\"",
731 | );
732 | IPHONEOS_DEPLOYMENT_TARGET = 5.0;
733 | OTHER_LDFLAGS = "-ObjC";
734 | PRODUCT_NAME = "$(TARGET_NAME)";
735 | SKIP_INSTALL = YES;
736 | };
737 | name = Release;
738 | };
739 | /* End XCBuildConfiguration section */
740 |
741 | /* Begin XCConfigurationList section */
742 | 21CF86201669035E0052625D /* Build configuration list for PBXNativeTarget "CheddarKitMac" */ = {
743 | isa = XCConfigurationList;
744 | buildConfigurations = (
745 | 21CF86211669035E0052625D /* Debug */,
746 | 21CF86221669035E0052625D /* Release */,
747 | );
748 | defaultConfigurationIsVisible = 0;
749 | defaultConfigurationName = Release;
750 | };
751 | B244407F15BE53DC00D4D4CA /* Build configuration list for PBXProject "CheddarKit" */ = {
752 | isa = XCConfigurationList;
753 | buildConfigurations = (
754 | B244409115BE53DC00D4D4CA /* Debug */,
755 | B244409215BE53DC00D4D4CA /* Release */,
756 | );
757 | defaultConfigurationIsVisible = 0;
758 | defaultConfigurationName = Release;
759 | };
760 | B244409315BE53DC00D4D4CA /* Build configuration list for PBXNativeTarget "CheddarKit" */ = {
761 | isa = XCConfigurationList;
762 | buildConfigurations = (
763 | B244409415BE53DC00D4D4CA /* Debug */,
764 | B244409515BE53DC00D4D4CA /* Release */,
765 | );
766 | defaultConfigurationIsVisible = 0;
767 | defaultConfigurationName = Release;
768 | };
769 | /* End XCConfigurationList section */
770 |
771 | /* Begin XCVersionGroup section */
772 | 21CF8673166905710052625D /* Cheddar.xcdatamodeld */ = {
773 | isa = XCVersionGroup;
774 | children = (
775 | 21CF8674166905710052625D /* Cheddar 2.xcdatamodel */,
776 | 21CF8675166905710052625D /* Cheddar.xcdatamodel */,
777 | );
778 | currentVersion = 21CF8674166905710052625D /* Cheddar 2.xcdatamodel */;
779 | path = Cheddar.xcdatamodeld;
780 | sourceTree = "";
781 | versionGroupType = wrapper.xcdatamodel;
782 | };
783 | /* End XCVersionGroup section */
784 | };
785 | rootObject = B244407C15BE53DC00D4D4CA /* Project object */;
786 | }
787 |
--------------------------------------------------------------------------------