├── .DS_Store ├── Depend.xcodeproj ├── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcuserdata │ │ └── rafagonc.xcuserdatad │ │ ├── UserInterfaceState.xcuserstate │ │ └── WorkspaceSettings.xcsettings ├── xcuserdata │ └── rafagonc.xcuserdatad │ │ └── xcschemes │ │ ├── xcschememanagement.plist │ │ └── Depend.xcscheme └── project.pbxproj ├── DependTests ├── EXProtocol.h ├── EXInjectedSubclass.h ├── EXProtocolImplementation.m ├── EXProtocolImplementation.h ├── EXAnotherProtocolImplementation.h ├── EXAnotherProtocolImplementation.m ├── EXInjectedClass.m ├── EXInjectedSubclass.m ├── EXInjectedClass.h ├── Info.plist └── DependTests.m ├── Depend.xcworkspace └── contents.xcworkspacedata ├── DependProject ├── DependProject │ ├── ViewController.h │ ├── DPDatasource.h │ ├── DPRegister.h │ ├── DPDatasourceProtocol.h │ ├── DPSecondDatasource.h │ ├── AppDelegate.h │ ├── main.m │ ├── DPRegister.m │ ├── Images.xcassets │ │ └── AppIcon.appiconset │ │ │ └── Contents.json │ ├── DPDatasource.m │ ├── DPSecondDatasource.m │ ├── ViewController.m │ ├── Info.plist │ ├── AppDelegate.m │ └── Base.lproj │ │ ├── LaunchScreen.xib │ │ └── Main.storyboard ├── DependProjectTests │ ├── Info.plist │ └── DependProjectTests.m └── DependProject.xcodeproj │ └── project.pbxproj ├── Pod └── Classes │ ├── DPImplementationValue.h │ ├── DPInjector.h │ ├── DPCache.h │ ├── DPImplementationKey.h │ ├── DPInjectionPropertyDescriptor.h │ ├── DPInjectionDescriptor.m │ ├── DPImplementationKey.m │ ├── DPRegistry.h │ ├── DPInjectionDescriptor.h │ ├── DPCache.m │ ├── DPInjectionPropertyDescriptor.m │ ├── DPInjector.m │ └── DPRegistry.m ├── .gitignore ├── LICENSE ├── Depend.podspec └── README.md /.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rafagonc/Depend/HEAD/.DS_Store -------------------------------------------------------------------------------- /Depend.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /Depend.xcodeproj/project.xcworkspace/xcuserdata/rafagonc.xcuserdatad/UserInterfaceState.xcuserstate: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rafagonc/Depend/HEAD/Depend.xcodeproj/project.xcworkspace/xcuserdata/rafagonc.xcuserdatad/UserInterfaceState.xcuserstate -------------------------------------------------------------------------------- /DependTests/EXProtocol.h: -------------------------------------------------------------------------------- 1 | // 2 | // EXProtocol.h 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @protocol EXProtocol 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /DependTests/EXInjectedSubclass.h: -------------------------------------------------------------------------------- 1 | // 2 | // EXInjectedSubclass.h 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 10/27/15. 6 | // Copyright © 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import "EXInjectedClass.h" 10 | 11 | @interface EXInjectedSubclass : EXInjectedClass 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /Depend.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /DependTests/EXProtocolImplementation.m: -------------------------------------------------------------------------------- 1 | // 2 | // EXProtocolImplementation.m 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import "EXProtocolImplementation.h" 10 | 11 | @implementation EXProtocolImplementation 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /DependProject/DependProject/ViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // ViewController.h 3 | // DependProject 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonzalves. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface ViewController : UIViewController 12 | 13 | 14 | @end 15 | 16 | -------------------------------------------------------------------------------- /DependTests/EXProtocolImplementation.h: -------------------------------------------------------------------------------- 1 | // 2 | // EXProtocolImplementation.h 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface EXProtocolImplementation : NSObject 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /DependProject/DependProject/DPDatasource.h: -------------------------------------------------------------------------------- 1 | // 2 | // DPDatasource.h 3 | // DependProject 4 | // 5 | // Created by Rafael Gonzalves on 9/18/15. 6 | // Copyright (c) 2015 Rafael Gonzalves. All rights reserved. 7 | // 8 | 9 | #import "DPDatasourceProtocol.h" 10 | 11 | @interface DPDatasource : NSObject 12 | 13 | 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /DependTests/EXAnotherProtocolImplementation.h: -------------------------------------------------------------------------------- 1 | // 2 | // EXAnotherProtocolImplementation.h 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface EXAnotherProtocolImplementation : NSObject 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /DependProject/DependProject/DPRegister.h: -------------------------------------------------------------------------------- 1 | // 2 | // DPRegister.h 3 | // DependProject 4 | // 5 | // Created by Rafael Gonzalves on 9/18/15. 6 | // Copyright (c) 2015 Rafael Gonzalves. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface DPRegister : NSObject 12 | 13 | +(void)registerImplementations ; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /DependTests/EXAnotherProtocolImplementation.m: -------------------------------------------------------------------------------- 1 | // 2 | // EXAnotherProtocolImplementation.m 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import "EXAnotherProtocolImplementation.h" 10 | 11 | @implementation EXAnotherProtocolImplementation 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /DependProject/DependProject/DPDatasourceProtocol.h: -------------------------------------------------------------------------------- 1 | // 2 | // DPDatasourceProtocol.h 3 | // DependProject 4 | // 5 | // Created by Rafael Gonzalves on 9/18/15. 6 | // Copyright (c) 2015 Rafael Gonzalves. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @protocol DPDatasourceProtocol 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /DependProject/DependProject/DPSecondDatasource.h: -------------------------------------------------------------------------------- 1 | // 2 | // DPSecondDatasource.h 3 | // DependProject 4 | // 5 | // Created by Rafael Gonzalves on 9/18/15. 6 | // Copyright (c) 2015 Rafael Gonzalves. All rights reserved. 7 | // 8 | 9 | #import "DPDatasourceProtocol.h" 10 | 11 | @interface DPSecondDatasource : NSObject 12 | 13 | 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /DependProject/DependProject/AppDelegate.h: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.h 3 | // DependProject 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonzalves. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | 12 | @interface AppDelegate : UIResponder 13 | 14 | @property (strong, nonatomic) UIWindow *window; 15 | 16 | 17 | @end 18 | 19 | -------------------------------------------------------------------------------- /DependTests/EXInjectedClass.m: -------------------------------------------------------------------------------- 1 | // 2 | // InjectedExampleClass.m 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import "EXInjectedClass.h" 10 | 11 | @implementation EXInjectedClass 12 | 13 | -(instancetype)init { 14 | if (self = [super init]) { 15 | 16 | } return self; 17 | } 18 | 19 | 20 | @end 21 | -------------------------------------------------------------------------------- /DependProject/DependProject/main.m: -------------------------------------------------------------------------------- 1 | // 2 | // main.m 3 | // DependProject 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonzalves. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "AppDelegate.h" 11 | 12 | int main(int argc, char * argv[]) { 13 | @autoreleasepool { 14 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /DependTests/EXInjectedSubclass.m: -------------------------------------------------------------------------------- 1 | // 2 | // EXInjectedSubclass.m 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 10/27/15. 6 | // Copyright © 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import "EXInjectedSubclass.h" 10 | 11 | @implementation EXInjectedSubclass 12 | 13 | -(instancetype)init { 14 | if (self = [super init]) { 15 | NSLog(@"%@",self.anotherObject); 16 | } return self; 17 | } 18 | 19 | 20 | @end 21 | -------------------------------------------------------------------------------- /Depend.xcodeproj/project.xcworkspace/xcuserdata/rafagonc.xcuserdatad/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | HasAskedToTakeAutomaticSnapshotBeforeSignificantChanges 6 | 7 | SnapshotAutomaticallyBeforeSignificantChanges 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /DependTests/EXInjectedClass.h: -------------------------------------------------------------------------------- 1 | // 2 | // InjectedExampleClass.h 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "EXProtocol.h" 11 | 12 | @interface EXInjectedClass : NSObject 13 | 14 | @property (setter=injected:,readonly) id object; 15 | @property (setter=injected_another:,readonly) id anotherObject; 16 | 17 | 18 | @end 19 | -------------------------------------------------------------------------------- /Pod/Classes/DPImplementationValue.h: -------------------------------------------------------------------------------- 1 | // 2 | // DPImplementationValue.h 3 | // Depend 4 | // 5 | // Created by Banco Santander Brasil on 7/14/16. 6 | // Copyright © 2016 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface DPImplementationValue : NSObject 12 | 13 | -(instancetype)initWithImp:(id)imp andIsSingleton:(BOOL)isSingleton; 14 | 15 | @property (nonatomic,strong) id imp; 16 | @property (nonatomic,assign) BOOL isSingleton; 17 | 18 | @end 19 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Xcode 2 | # 3 | build/ 4 | *.pbxuser 5 | !default.pbxuser 6 | *.mode1v3 7 | !default.mode1v3 8 | *.mode2v3 9 | !default.mode2v3 10 | *.perspectivev3 11 | !default.perspectivev3 12 | xcuserdata 13 | *.xccheckout 14 | *.moved-aside 15 | DerivedData 16 | *.hmap 17 | *.ipa 18 | *.xcuserstate 19 | 20 | # CocoaPods 21 | # 22 | # We recommend against adding the Pods directory to your .gitignore. However 23 | # you should judge for yourself, the pros and cons are mentioned at: 24 | # http://guides.cocoapods.org/using/using-cocoapods.html#should-i-ignore-the-pods-directory-in-source-control 25 | # 26 | #Pods/ 27 | -------------------------------------------------------------------------------- /Depend.xcodeproj/xcuserdata/rafagonc.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | Depend.xcscheme 8 | 9 | orderHint 10 | 0 11 | 12 | 13 | SuppressBuildableAutocreation 14 | 15 | 2A2857621BAA4B6400AEE15C 16 | 17 | primary 18 | 19 | 20 | 2A28576D1BAA4B6400AEE15C 21 | 22 | primary 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /Pod/Classes/DPInjector.h: -------------------------------------------------------------------------------- 1 | // 2 | // Depend.h 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/16/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface DPInjector : NSObject 12 | /** 13 | * Swizzle all getter methods for injectable 14 | * properties, you should call this on 15 | * application:didFinishLauchingWithOptions: 16 | * on app delegate. Properties that are injected 17 | * get the getter IMP replaces with a generic 18 | * get/set with association objects. This is the only 19 | * way that the framework don't require any calls from 20 | * injectable classes 21 | * 22 | * @see Method Swizzling 23 | */ 24 | +(void)inject; 25 | 26 | @end 27 | -------------------------------------------------------------------------------- /DependProject/DependProject/DPRegister.m: -------------------------------------------------------------------------------- 1 | // 2 | // DPRegister.m 3 | // DependProject 4 | // 5 | // Created by Rafael Gonzalves on 9/18/15. 6 | // Copyright (c) 2015 Rafael Gonzalves. All rights reserved. 7 | // 8 | 9 | #import "DPRegister.h" 10 | #import "DPDatasourceProtocol.h" 11 | #import "DPSecondDatasource.h" 12 | #import "DPDatasource.h" 13 | #import "Depend/DPRegistry.h" 14 | 15 | @implementation DPRegister 16 | 17 | +(void)registerImplementations { 18 | [[DPRegistry sharedRegistry] registerImplementation:[DPDatasource class] forProtocol:@protocol(DPDatasourceProtocol) context:nil]; 19 | [[DPRegistry sharedRegistry] registerImplementation:[[DPSecondDatasource alloc] init] forProtocol:@protocol(DPDatasourceProtocol) context:@"second"]; 20 | } 21 | 22 | @end 23 | -------------------------------------------------------------------------------- /DependProject/DependProject/Images.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "size" : "29x29", 6 | "scale" : "2x" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "size" : "29x29", 11 | "scale" : "3x" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "size" : "40x40", 16 | "scale" : "2x" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "size" : "40x40", 21 | "scale" : "3x" 22 | }, 23 | { 24 | "idiom" : "iphone", 25 | "size" : "60x60", 26 | "scale" : "2x" 27 | }, 28 | { 29 | "idiom" : "iphone", 30 | "size" : "60x60", 31 | "scale" : "3x" 32 | } 33 | ], 34 | "info" : { 35 | "version" : 1, 36 | "author" : "xcode" 37 | } 38 | } -------------------------------------------------------------------------------- /DependTests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | br.com.goncalves.$(PRODUCT_NAME:rfc1034identifier) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | 24 | 25 | -------------------------------------------------------------------------------- /DependProject/DependProjectTests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | com.rafael.Goncalves.$(PRODUCT_NAME:rfc1034identifier) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | 24 | 25 | -------------------------------------------------------------------------------- /DependProject/DependProject/DPDatasource.m: -------------------------------------------------------------------------------- 1 | // 2 | // DPDatasource.m 3 | // DependProject 4 | // 5 | // Created by Rafael Gonzalves on 9/18/15. 6 | // Copyright (c) 2015 Rafael Gonzalves. All rights reserved. 7 | // 8 | 9 | #import "DPDatasource.h" 10 | 11 | @implementation DPDatasource 12 | 13 | -(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { 14 | return 1; 15 | } 16 | -(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { 17 | NSString *cellID = @"CellIndentification"; 18 | UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:cellID]; 19 | if (!cell) { 20 | cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:cellID]; 21 | } 22 | 23 | cell.textLabel.text = @"Enjoy loosely coupled architeture"; 24 | 25 | return cell; 26 | } 27 | 28 | @end 29 | -------------------------------------------------------------------------------- /DependProject/DependProject/DPSecondDatasource.m: -------------------------------------------------------------------------------- 1 | // 2 | // DPSecondDatasource.m 3 | // DependProject 4 | // 5 | // Created by Rafael Gonzalves on 9/18/15. 6 | // Copyright (c) 2015 Rafael Gonzalves. All rights reserved. 7 | // 8 | 9 | #import "DPSecondDatasource.h" 10 | 11 | @implementation DPSecondDatasource 12 | 13 | -(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { 14 | return 1; 15 | } 16 | -(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { 17 | NSString *cellID = @"CellIndentification"; 18 | UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:cellID]; 19 | if (!cell) { 20 | cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:cellID]; 21 | } 22 | 23 | cell.textLabel.text = @"Enjoy the another implementation too"; 24 | 25 | return cell; 26 | } 27 | 28 | 29 | @end 30 | -------------------------------------------------------------------------------- /Pod/Classes/DPCache.h: -------------------------------------------------------------------------------- 1 | // 2 | // DPCache.h 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/16/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @class DPInjectionDescriptor; 12 | 13 | @interface DPCache : NSObject 14 | /** 15 | * Create or just return and dictionary with 16 | * injectable class names as keys and DPInjectionDescriptor 17 | * as values. It is inside an dispatch_once so its done 18 | * just one time. Class that are detected as injectable has 19 | * a property with setter=inject[Anything]_[context]. 20 | * 21 | * @return an dictionary with injectable classes. 22 | * @see DPInjectionDescriptor 23 | */ 24 | +(NSDictionary *)injectClasses; 25 | /** 26 | * Gets from the dictionary the DPInjectionDescriptor 27 | * for the injectable class. 28 | * 29 | * @return injection descriptor. 30 | * @see DPInjectionDescriptor 31 | */ 32 | +(DPInjectionDescriptor *)descriptorWithClass:(Class)c; 33 | 34 | @end 35 | -------------------------------------------------------------------------------- /Pod/Classes/DPImplementationKey.h: -------------------------------------------------------------------------------- 1 | // 2 | // DPImplementation.h 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | /** 12 | * The custom dictionary key to find 13 | * the implementations. 14 | * TODO: isEqual: better implementation 15 | */ 16 | @interface DPImplementationKey : NSObject 17 | 18 | #pragma mark - constructor 19 | /** 20 | * Constructor receiving the info that 21 | * describes an injection 22 | */ 23 | -(instancetype)initWithProtocolName:(NSString *)protocolName andContext:(NSString *)context; 24 | 25 | #pragma mark - properties 26 | /** 27 | * Context specified after the _ (underline) in the 28 | * injection setter declaration. 29 | */ 30 | @property (nonatomic, copy, readonly) NSString * context; 31 | /** 32 | * The protocol name that the implementation 33 | * class conforms to. 34 | */ 35 | @property (nonatomic,strong, readonly) NSString * protocolName; 36 | 37 | 38 | 39 | @end 40 | -------------------------------------------------------------------------------- /DependProject/DependProjectTests/DependProjectTests.m: -------------------------------------------------------------------------------- 1 | // 2 | // DependProjectTests.m 3 | // DependProjectTests 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonzalves. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | 12 | @interface DependProjectTests : XCTestCase 13 | 14 | @end 15 | 16 | @implementation DependProjectTests 17 | 18 | - (void)setUp { 19 | [super setUp]; 20 | // Put setup code here. This method is called before the invocation of each test method in the class. 21 | } 22 | 23 | - (void)tearDown { 24 | // Put teardown code here. This method is called after the invocation of each test method in the class. 25 | [super tearDown]; 26 | } 27 | 28 | - (void)testExample { 29 | // This is an example of a functional test case. 30 | XCTAssert(YES, @"Pass"); 31 | } 32 | 33 | - (void)testPerformanceExample { 34 | // This is an example of a performance test case. 35 | [self measureBlock:^{ 36 | // Put the code you want to measure the time of here. 37 | }]; 38 | } 39 | 40 | @end 41 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2015 Rafael Gonçalves 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | 23 | -------------------------------------------------------------------------------- /DependProject/DependProject/ViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // ViewController.m 3 | // DependProject 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonzalves. All rights reserved. 7 | // 8 | 9 | #import "ViewController.h" 10 | #import "DPDatasourceProtocol.h" 11 | 12 | @interface ViewController () 13 | 14 | #pragma mark - ui 15 | @property (weak, nonatomic) IBOutlet UITableView *tableView; 16 | 17 | @property (setter=injected:, readonly) id datasource; 18 | 19 | //change contexts 20 | //@property (setter=injected_second:, readonly) id datasource; 21 | 22 | @end 23 | 24 | @implementation ViewController 25 | 26 | #pragma mark - lifecycle 27 | -(void)viewDidLoad { 28 | [super viewDidLoad]; 29 | self.tableView.dataSource = self.datasource; 30 | self.tableView.delegate = self.datasource; 31 | 32 | UIBarButtonItem *item = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemDone target:self action:@selector(done:)]; 33 | [self.navigationItem setRightBarButtonItem:item]; 34 | 35 | } 36 | 37 | #pragma mark - actions 38 | -(void)done:(UIBarButtonItem *)item { 39 | [self dismissViewControllerAnimated:YES completion:nil]; 40 | } 41 | 42 | #pragma mark - dealloc 43 | -(void)dealloc { 44 | NSLog(@"%@ - DEALLOC", NSStringFromClass(self.class)); 45 | } 46 | 47 | @end 48 | -------------------------------------------------------------------------------- /Pod/Classes/DPInjectionPropertyDescriptor.h: -------------------------------------------------------------------------------- 1 | // 2 | // DPInjectionPropertyDescriptor.h 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/16/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | 12 | /** 13 | * The purprose of this class is to extract 14 | * information from the objc_property_t 15 | * type into useful data. 16 | */ 17 | @interface DPInjectionPropertyDescriptor : NSObject 18 | 19 | #pragma mark - constructor 20 | /** 21 | * Constructor recieving a runtime property 22 | * declaration that are consumed by the 23 | * readonly properties 24 | */ 25 | -(instancetype)initWithProperty:(objc_property_t)property; 26 | 27 | #pragma mark - properties 28 | /** 29 | * Property name or the selector (same thing) 30 | */ 31 | @property (nonatomic,readonly) NSString * propertyName; 32 | /** 33 | * the selector specigied in the setter= 34 | * when the injection is declared! 35 | */ 36 | @property (nonatomic,readonly) SEL injectionSelector; 37 | /** 38 | * The context specified after the _ (underline) 39 | * in the setter= injection selector. 40 | */ 41 | @property (nonatomic,readonly) NSString * context; 42 | /** 43 | * The protocol name that the property conforms too. 44 | */ 45 | @property (nonatomic,readonly) NSString * protocolName; 46 | 47 | 48 | @end 49 | -------------------------------------------------------------------------------- /DependProject/DependProject/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | com.rafael.Goncalves.$(PRODUCT_NAME:rfc1034identifier) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | LSRequiresIPhoneOS 24 | 25 | UILaunchStoryboardName 26 | LaunchScreen 27 | UIMainStoryboardFile 28 | Main 29 | UIRequiredDeviceCapabilities 30 | 31 | armv7 32 | 33 | UISupportedInterfaceOrientations 34 | 35 | UIInterfaceOrientationPortrait 36 | UIInterfaceOrientationLandscapeLeft 37 | UIInterfaceOrientationLandscapeRight 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /Pod/Classes/DPInjectionDescriptor.m: -------------------------------------------------------------------------------- 1 | // 2 | // DPClassInjectionDescriptor.m 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/16/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import "DPInjectionDescriptor.h" 10 | #import "DPInjectionPropertyDescriptor.h" 11 | 12 | @interface DPInjectionDescriptor () 13 | 14 | @property (nonatomic,strong) NSMutableArray *mProperties; 15 | 16 | @end 17 | 18 | @implementation DPInjectionDescriptor 19 | 20 | #pragma mark - constructor 21 | -(instancetype)initWithClass:(__unsafe_unretained Class)c { 22 | if (self = [super init]) { 23 | _injectClass = c; 24 | _mProperties = [[NSMutableArray alloc] init]; 25 | } return self; 26 | } 27 | 28 | #pragma mark - getters 29 | -(NSArray *)properties { 30 | return [self.mProperties copy]; 31 | } 32 | -(NSArray *)propertiesNames { 33 | return [self.mProperties valueForKeyPath:@"@unionOfObjects.propertyName"]; 34 | } 35 | 36 | #pragma mark - adding 37 | -(void)addProperty:(objc_property_t)property { 38 | [self.mProperties addObject:[[DPInjectionPropertyDescriptor alloc] initWithProperty:property]]; 39 | } 40 | 41 | #pragma mark - retrieving 42 | -(DPInjectionPropertyDescriptor *)propertyDescriptorForSelector:(SEL)selector { 43 | return [[self.mProperties filteredArrayUsingPredicate:[NSPredicate predicateWithFormat:@"propertyName = %@", NSStringFromSelector(selector)]] firstObject]; 44 | } 45 | 46 | @end 47 | -------------------------------------------------------------------------------- /Pod/Classes/DPImplementationKey.m: -------------------------------------------------------------------------------- 1 | // 2 | // DPImplementation.m 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import "DPImplementationKey.h" 10 | 11 | @interface DPImplementationKey () 12 | 13 | 14 | @end 15 | 16 | @implementation DPImplementationKey 17 | 18 | #pragma mark - constructor 19 | -(instancetype)initWithProtocolName:(NSString *)protocolName andContext:(NSString *)context { 20 | if (self = [super init]) { 21 | _protocolName = protocolName; 22 | _context = context; 23 | } return self; 24 | } 25 | 26 | #pragma mark - equality 27 | -(BOOL)isEqual:(id)object { 28 | if (object == nil || [object isKindOfClass:[DPImplementationKey class]] == NO) return NO; 29 | DPImplementationKey *anotherImplementation = (DPImplementationKey *)object; 30 | if ([self.context isEqualToString:anotherImplementation.context] == NO) { 31 | if (self.context == nil && anotherImplementation.context == nil) { 32 | 33 | } else { 34 | return NO; 35 | } 36 | } 37 | if ([self.protocolName isEqualToString:anotherImplementation.protocolName] == NO) { 38 | return NO; 39 | } 40 | return YES; 41 | } 42 | -(NSUInteger)hash { 43 | return self.context.hash ^ self.protocolName.hash; 44 | } 45 | 46 | #pragma mark - NSCopying 47 | -(id)copyWithZone:(NSZone *)zone { 48 | DPImplementationKey *impKey = [[DPImplementationKey alloc] initWithProtocolName:[self.protocolName copy] andContext:[self.context copy]]; 49 | return impKey; 50 | } 51 | 52 | @end 53 | -------------------------------------------------------------------------------- /Pod/Classes/DPRegistry.h: -------------------------------------------------------------------------------- 1 | // 2 | // DPRegistry.h 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import 10 | /** 11 | * Singleton to hold all the implementation 12 | * registrations. 13 | */ 14 | @interface DPRegistry : NSObject 15 | 16 | #pragma mark - singleton 17 | +(DPRegistry *)sharedRegistry; 18 | 19 | #pragma mark - properties 20 | /** 21 | * All the implementation registrations: 22 | * DPImplementationKey as the key and 23 | * the implementation as value 24 | */ 25 | @property (nonatomic,readonly) NSDictionary *registrations; 26 | 27 | #pragma mark - methods 28 | /** 29 | * The method responsible for registering an implementation 30 | * the conforms to the protocol specified, this must be done in 31 | * the application:didFinishLaunchingWithOptions: method. The implementation 32 | * could be a class or a instance, if it is a class, the implementation method 33 | * will instantiate with the default constructor [[(Class)imp alloc] init], if 34 | * it is a method 35 | */ 36 | -(void)registerImplementation:(id)imp forProtocol:(Protocol *)protocol context:(NSString *)context; 37 | -(void)unregisterImplementationForProtocol:(Protocol *)protocol context:(NSString *)context; 38 | 39 | #pragma mark - singleton 40 | -(BOOL)isSingleton:(NSString *)protocolName andContext:(NSString *)context; 41 | 42 | #pragma mark - retrieve 43 | /** 44 | * Method for retriving an instance that conforms with the protocol 45 | * specified. 46 | */ 47 | -(id)implementationForProtocol:(NSString *)protocolName andContext:(NSString *)context; 48 | 49 | @end 50 | -------------------------------------------------------------------------------- /Depend.podspec: -------------------------------------------------------------------------------- 1 | # 2 | # Be sure to run `pod lib lint Depend.podspec' to ensure this is a 3 | # valid spec before submitting. 4 | # 5 | # Any lines starting with a # are optional, but their use is encouraged 6 | # To learn more about a Podspec see http://guides.cocoapods.org/syntax/podspec.html 7 | # 8 | 9 | Pod::Spec.new do |s| 10 | s.name = "Depend" 11 | s.version = "0.1.7" 12 | s.summary = "minimalist depedency injection framework" 13 | 14 | # This description is used to generate tags and improve search results. 15 | # * Think: What does it do? Why did you write it? What is the focus? 16 | # * Try to keep it short, snappy and to the point. 17 | # * Write the description between the DESC delimiters below. 18 | # * Finally, don't worry about the indent, CocoaPods strips it! 19 | s.description = "Depend is a simple dependency injection framework to do the simplest and minimally invasive property injection. It just works with Protocol bindings since it is the right way to do it!" 20 | 21 | s.homepage = "https://github.com/rafagonc/Depend" 22 | s.license = 'MIT' 23 | s.author = { "Rafael Gonçalves" => "rafagonc77@yahoo.com.br" } 24 | s.source = { :git => "https://github.com/rafagonc/Depend.git", :tag => s.version.to_s } 25 | # s.social_media_url = 'https://twitter.com/core_rafa' 26 | 27 | s.platform = :ios, '7.0' 28 | s.requires_arc = true 29 | 30 | s.source_files = 'Pod/Classes/**/*' 31 | # s.resource_bundles = { 32 | # 'Depend' => ['Pod/Assets/*.png'] 33 | # } 34 | 35 | s.public_header_files = 'Pod/Classes/DPRegistry.h', 'Pod/Classes/DPInjector.h' 36 | # s.frameworks = 'UIKit', 'MapKit' 37 | # s.dependency 'AFNetworking', '~> 2.3' 38 | end 39 | -------------------------------------------------------------------------------- /Pod/Classes/DPInjectionDescriptor.h: -------------------------------------------------------------------------------- 1 | // 2 | // DPClassInjectionDescriptor.h 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/16/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | 12 | @class DPInjectionPropertyDescriptor; 13 | 14 | /** 15 | * Injection descriptions describes every injectable property 16 | * , selectors, protocols associated with the injection. 17 | */ 18 | @interface DPInjectionDescriptor : NSObject 19 | 20 | #pragma mark - constructor 21 | /** 22 | * Construct an descriptor based on a injectable class. 23 | */ 24 | -(instancetype)initWithClass:(__unsafe_unretained Class)c; 25 | 26 | #pragma mark - properties 27 | /** 28 | * Injectable Class recognized by DPCache. 29 | * 30 | * @see DPCache 31 | */ 32 | @property (nonatomic,readonly, unsafe_unretained) Class injectClass; 33 | /** 34 | * All injectable property names. 35 | */ 36 | @property (nonatomic,readonly) NSArray *propertiesNames; 37 | /** 38 | * Contains DPInjectionPropertyDescriptor instances that 39 | * knows everything about the injection: selector, context, 40 | * protocol. 41 | * 42 | * @see DPInjectionPropertyDescriptor 43 | */ 44 | @property (nonatomic,readonly) NSArray *properties; 45 | 46 | #pragma mark - adding 47 | /** 48 | * Add a DPInjectionPropertyDescriptor isntance to properties array. 49 | * 50 | * @param property an injectable property recognized by DPCache 51 | */ 52 | -(void)addProperty:(objc_property_t)property; 53 | 54 | #pragma mark - retrieving 55 | /** 56 | * Search into properties array for the right property descriptor. 57 | */ 58 | -(DPInjectionPropertyDescriptor *)propertyDescriptorForSelector:(SEL)selector; 59 | 60 | @end 61 | -------------------------------------------------------------------------------- /Pod/Classes/DPCache.m: -------------------------------------------------------------------------------- 1 | // 2 | // DPCache.m 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/16/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import "DPCache.h" 10 | #import 11 | #import "DPInjectionDescriptor.h" 12 | 13 | @implementation DPCache 14 | 15 | #pragma mark - get injectable classes 16 | +(NSDictionary *)injectClasses { 17 | static NSMutableDictionary *injectClasses; 18 | static dispatch_once_t onceToken; 19 | dispatch_once(&onceToken, ^{ 20 | injectClasses = [[NSMutableDictionary alloc] init]; 21 | unsigned int class_count = objc_getClassList(NULL, 0); 22 | Class * classes = (Class *)calloc(class_count, sizeof(Class)); 23 | objc_getClassList(classes, class_count); 24 | for (int i = 0; i < class_count; i++) { 25 | @autoreleasepool { 26 | Class class = classes[i]; 27 | [DPCache shouldBeInjected:class withResult:^(DPInjectionDescriptor *descriptor) { 28 | [injectClasses setObject:descriptor forKey:NSStringFromClass(class)]; 29 | }]; 30 | } 31 | } 32 | }); 33 | return [injectClasses copy]; 34 | } 35 | +(void)shouldBeInjected:(Class)class withResult:(void(^)(DPInjectionDescriptor *descriptor))result { 36 | unsigned int property_count; 37 | objc_property_t *properties = class_copyPropertyList(class, &property_count); 38 | DPInjectionDescriptor *desc = [[DPInjectionDescriptor alloc] initWithClass:class]; 39 | for (int i = 0; i < property_count; i++) { 40 | const char * attr = property_getAttributes(properties[i]); 41 | NSString *attrString = [NSString stringWithCString:attr encoding:NSUTF8StringEncoding]; 42 | if ([attrString rangeOfString:@"injected"].location != NSNotFound) { 43 | [desc addProperty:properties[i]]; 44 | } 45 | } 46 | if (desc.properties.count) result(desc); 47 | } 48 | 49 | #pragma mark - retrieving 50 | +(DPInjectionDescriptor *)descriptorWithClass:(Class)c { 51 | return [DPCache injectClasses][NSStringFromClass(c)]; 52 | } 53 | 54 | @end 55 | -------------------------------------------------------------------------------- /Pod/Classes/DPInjectionPropertyDescriptor.m: -------------------------------------------------------------------------------- 1 | // 2 | // DPInjectionPropertyDescriptor.m 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/16/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import "DPInjectionPropertyDescriptor.h" 10 | 11 | @interface DPInjectionPropertyDescriptor () 12 | 13 | @property (nonatomic,assign) objc_property_t property; 14 | 15 | @end 16 | 17 | @implementation DPInjectionPropertyDescriptor 18 | 19 | #pragma mark - constructor 20 | -(instancetype)initWithProperty:(objc_property_t)property { 21 | if (self = [super init]) { 22 | _property = property; 23 | } return self; 24 | } 25 | 26 | #pragma mark - getters 27 | -(NSString *)propertyName { 28 | return [NSString stringWithCString:property_getName(self.property) encoding:NSUTF8StringEncoding]; 29 | } 30 | -(SEL)injectionSelector { 31 | return NSSelectorFromString([self findInPropertyAttributesRegularExpressionFirstMatch:@"injected.*?(?=,)"]); 32 | } 33 | -(NSString *)protocolName { 34 | return [[self findInPropertyAttributesRegularExpressionFirstMatch:@"(?=<).*?(?=>)"] stringByReplacingOccurrencesOfString:@"<" withString:@""]; //im not an expert in regex; 35 | } 36 | -(NSString *)context { 37 | NSString *selector = NSStringFromSelector([self injectionSelector]); 38 | NSArray *separateContext = [selector componentsSeparatedByString:@"_"]; 39 | return separateContext.count < 2 ? nil : [[separateContext objectAtIndex:1] stringByReplacingOccurrencesOfString:@":" withString:@""]; 40 | } 41 | 42 | #pragma mark - helper 43 | -(NSString *)findInPropertyAttributesRegularExpressionFirstMatch:(NSString *)pattern { 44 | NSError *error; 45 | NSString *attr = [NSString stringWithCString:property_getAttributes(self.property) encoding:NSUTF8StringEncoding]; 46 | NSRegularExpression *regex = [NSRegularExpression regularExpressionWithPattern:pattern options:NSRegularExpressionCaseInsensitive error:&error]; 47 | NSAssert(error == nil, error.localizedDescription); 48 | NSTextCheckingResult *result = [regex firstMatchInString:attr options:NSMatchingReportCompletion range:NSMakeRange(0, attr.length)]; 49 | return [attr substringWithRange:result.range]; 50 | } 51 | 52 | @end 53 | -------------------------------------------------------------------------------- /DependProject/DependProject/AppDelegate.m: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.m 3 | // DependProject 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonzalves. All rights reserved. 7 | // 8 | 9 | #import "AppDelegate.h" 10 | #import "Depend/DPInjector.h" 11 | #import "DPRegister.h" 12 | 13 | @interface AppDelegate () 14 | 15 | @end 16 | 17 | @implementation AppDeleggate 18 | 19 | 20 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { 21 | [DPInjector inject]; 22 | [DPRegister registerImplementations]; 23 | return YES; 24 | } 25 | 26 | - (void)applicationWillResignActive:(UIApplication *)application { 27 | // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. 28 | // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game. 29 | } 30 | 31 | - (void)applicationDidEnterBackground:(UIApplication *)application { 32 | // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. 33 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. 34 | } 35 | 36 | - (void)applicationWillEnterForeground:(UIApplication *)application { 37 | // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background. 38 | } 39 | 40 | - (void)applicationDidBecomeActive:(UIApplication *)application { 41 | // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. 42 | } 43 | 44 | - (void)applicationWillTerminate:(UIApplication *)application { 45 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. 46 | } 47 | 48 | @end 49 | -------------------------------------------------------------------------------- /Pod/Classes/DPInjector.m: -------------------------------------------------------------------------------- 1 | // 2 | // Depend.m 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/16/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import "DPInjector.h" 10 | #import "DPCache.h" 11 | #import "DPInjectionDescriptor.h" 12 | #import "DPInjectionPropertyDescriptor.h" 13 | #import "DPRegistry.h" 14 | 15 | @implementation DPInjector 16 | 17 | #pragma mark - load 18 | +(void)inject { 19 | [super load]; 20 | for (NSString *classesNames in [DPCache injectClasses]) { 21 | [self swizzleGetters:[DPCache injectClasses][classesNames]]; 22 | } 23 | } 24 | 25 | #pragma mark - swizzling 26 | +(void)swizzleGetters:(DPInjectionDescriptor *)desc { 27 | for (NSString *s in desc.propertiesNames) { 28 | SEL getterSelector = NSSelectorFromString(s); 29 | Method getterMethod = class_getInstanceMethod(desc.injectClass, getterSelector); 30 | class_replaceMethod(desc.injectClass, getterSelector, (IMP)returnInjectedValue, method_getTypeEncoding(getterMethod)); 31 | } 32 | } 33 | 34 | #pragma mark - generic getter method 35 | id returnInjectedValue(id self, SEL _cmd) { 36 | Class class = [self class]; 37 | DPInjectionDescriptor *injectionDescriptor = [DPCache descriptorWithClass:[self class]]; 38 | DPInjectionPropertyDescriptor *propertyDescriptor = [injectionDescriptor propertyDescriptorForSelector:_cmd]; 39 | while (propertyDescriptor == nil) { 40 | class = class_getSuperclass(class); 41 | injectionDescriptor = [DPCache descriptorWithClass:class]; 42 | propertyDescriptor = [injectionDescriptor propertyDescriptorForSelector:_cmd]; 43 | if (class_isMetaClass([NSObject class])) break; 44 | } 45 | BOOL isSingleton = [[DPRegistry sharedRegistry] isSingleton:propertyDescriptor.protocolName andContext:propertyDescriptor.context]; 46 | if (isSingleton) { 47 | return [[DPRegistry sharedRegistry] implementationForProtocol:propertyDescriptor.protocolName andContext:propertyDescriptor.context]; 48 | } else { 49 | id injectedObject = objc_getAssociatedObject(self, _cmd); 50 | if (injectedObject == nil) { 51 | objc_setAssociatedObject(self, _cmd, [[DPRegistry sharedRegistry] implementationForProtocol:propertyDescriptor.protocolName andContext:propertyDescriptor.context] , OBJC_ASSOCIATION_RETAIN_NONATOMIC); 52 | } 53 | return objc_getAssociatedObject(self, _cmd); 54 | } 55 | } 56 | 57 | @end 58 | -------------------------------------------------------------------------------- /DependTests/DependTests.m: -------------------------------------------------------------------------------- 1 | // 2 | // DependTests.m 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | #import "DPCache.h" 12 | #import "DPInjectionDescriptor.h" 13 | #import "DPInjector.h" 14 | #import "EXInjectedClass.h" 15 | #import "DPRegistry.h" 16 | #import "EXProtocol.h" 17 | #import "EXProtocolImplementation.h" 18 | #import "EXAnotherProtocolImplementation.h" 19 | #import "EXInjectedClass.h" 20 | #import "EXInjectedSubclass.h" 21 | 22 | @interface DependTests : XCTestCase { 23 | EXInjectedClass * injected; 24 | EXAnotherProtocolImplementation *implementation ; 25 | } 26 | @end 27 | 28 | @implementation DependTests 29 | 30 | -(void)setUp { 31 | [super setUp]; 32 | [DPInjector inject]; 33 | 34 | implementation = [[EXAnotherProtocolImplementation alloc] init]; 35 | 36 | [[DPRegistry sharedRegistry] registerImplementation:[EXProtocolImplementation class] forProtocol:@protocol(EXProtocol) context:nil]; 37 | [[DPRegistry sharedRegistry] registerImplementation:implementation forProtocol:@protocol(EXProtocol) context:@"another"]; 38 | 39 | injected = [[EXInjectedSubclass alloc] init]; 40 | } 41 | 42 | #pragma mark tests 43 | -(void)testInjection { 44 | XCTAssertTrue([injected.object isKindOfClass:[EXProtocolImplementation class]]); 45 | } 46 | -(void)testInjectionWithContext { 47 | XCTAssertTrue([injected.anotherObject isKindOfClass:[EXAnotherProtocolImplementation class]]); 48 | XCTAssertEqual(implementation, injected.anotherObject); 49 | } 50 | -(void)testInjectionWithContextChangingInstances { 51 | [[DPRegistry sharedRegistry] unregisterImplementationForProtocol:@protocol(EXProtocol) context:@"another"]; 52 | [[DPRegistry sharedRegistry] registerImplementation:[[EXAnotherProtocolImplementation alloc] init] forProtocol:@protocol(EXProtocol) context:@"another"]; 53 | XCTAssertTrue([injected.anotherObject isKindOfClass:[EXAnotherProtocolImplementation class]]); 54 | XCTAssertNotEqual(implementation, injected.anotherObject); 55 | } 56 | -(void)testNilImplementationOnAddImplementation { 57 | XCTAssertThrows([[DPRegistry sharedRegistry] registerImplementation:nil forProtocol:@protocol(EXProtocol) context:nil]); 58 | } 59 | -(void)testNilProtocolOnAddImplementation { 60 | XCTAssertThrows([[DPRegistry sharedRegistry] registerImplementation:[EXProtocolImplementation class] forProtocol:nil context:nil]); 61 | } 62 | 63 | @end 64 | -------------------------------------------------------------------------------- /Pod/Classes/DPRegistry.m: -------------------------------------------------------------------------------- 1 | // 2 | // DPRegistry.m 3 | // Depend 4 | // 5 | // Created by Rafael Gonzalves on 9/17/15. 6 | // Copyright (c) 2015 Rafael Gonçalves. All rights reserved. 7 | // 8 | 9 | #import "DPRegistry.h" 10 | #import 11 | #import "DPImplementationKey.h" 12 | #import "DPImplementationValue.h" 13 | 14 | @interface DPRegistry () 15 | 16 | @property (nonatomic,strong) NSMutableDictionary *mRegistrations; 17 | 18 | @end 19 | 20 | @implementation DPRegistry 21 | 22 | #pragma mark - constructor 23 | -(instancetype)init { 24 | if (self = [super init]) { 25 | self.mRegistrations = [[NSMutableDictionary alloc] init]; 26 | } return self; 27 | } 28 | 29 | #pragma mark - singleton 30 | +(DPRegistry *)sharedRegistry { 31 | static DPRegistry *reg; 32 | static dispatch_once_t onceToken; 33 | dispatch_once(&onceToken, ^{ 34 | reg = [[self alloc] init]; 35 | }); 36 | return reg; 37 | } 38 | 39 | #pragma mark - getters 40 | -(NSDictionary *)registrations { 41 | return [self.mRegistrations copy]; 42 | } 43 | 44 | #pragma mark - retrieve 45 | -(id)implementationForProtocol:(NSString *)protocolName andContext:(NSString *)context { 46 | DPImplementationKey * key = [[DPImplementationKey alloc] initWithProtocolName:protocolName andContext:context]; 47 | id imp = [self.mRegistrations objectForKey:key]; 48 | if ([imp class] == imp) { 49 | return [[(Class)imp alloc] init]; 50 | } else { 51 | return imp; 52 | } 53 | } 54 | -(BOOL)isSingleton:(NSString *)protocolName andContext:(NSString *)context { 55 | DPImplementationKey * key = [[DPImplementationKey alloc] initWithProtocolName:protocolName andContext:context]; 56 | id imp = [self.mRegistrations objectForKey:key]; 57 | if ([imp class] == imp) { 58 | return NO; 59 | } else { 60 | return YES; 61 | } 62 | } 63 | 64 | #pragma mark - add 65 | -(void)registerImplementation:(id)imp forProtocol:(Protocol *)protocol context:(NSString *)context { 66 | NSAssert(imp != nil, @"Implementation cannot be nil, it needs to be a class (will be instantiated with default constructor or a instance"); 67 | NSAssert(protocol != nil, @"Protocol cannot be nil when adding an implementation to the registry"); 68 | DPImplementationKey *desc = [[DPImplementationKey alloc] initWithProtocolName:NSStringFromProtocol(protocol) andContext:context]; 69 | [self.mRegistrations setObject:imp forKey:desc]; 70 | } 71 | -(void)unregisterImplementationForProtocol:(Protocol *)protocol context:(NSString *)context { 72 | NSAssert(protocol != nil, @"Protocol cannot be nil when adding an implementation to the registry"); 73 | DPImplementationKey *desc = [[DPImplementationKey alloc] initWithProtocolName:NSStringFromProtocol(protocol) andContext:context]; 74 | [self.mRegistrations removeObjectForKey:desc]; 75 | } 76 | 77 | @end 78 | -------------------------------------------------------------------------------- /DependProject/DependProject/Base.lproj/LaunchScreen.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 20 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Depend 2 | 3 | Depend is a simple dependency injection framework to do the simplest and minimally invasive property injection. It just works with Protocol bindings since it is the right thing to do! And it’s pretty simple: 4 | 5 | 6 | ## The Installation 7 | 8 | You can install using CocoaPods: 9 |
pod ‘Depend'
10 | 11 | Or, you can drop the files inside Pod/Classes into your project. 12 | 13 | ## The Registration 14 | 15 | Just provide the DPRegistry the implementation for the protocol: 16 |
[[DPRegistry sharedRegistry] registerImplementation:[DPDatasource class] forProtocol:@protocol(DPDatasourceProtocol) context:nil];
17 | The implementation works this way: 18 | **If you provide a class**: The injection class will instantiate for you with the default constructor **If you provide an instance**: The instance will be injected! 19 | 20 | 21 | ## The Injection 22 | 23 | On the app delegate, you need to call the DPInjector inject method: 24 |
-(BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
25 |     [DPInjector inject];
26 |     return YES;
27 | }
28 | 
29 | 30 | To inject on a class you just need to write your property declaration with the 'injected' prefix to the setter and the readonly qualifier. It’s important to declare it on the private interface of your class. 31 |
@property (setter=injected1:) id<DPDatasourceProtocol> datasource;
32 |
@property (setter=injected2:) id<REDUser> user;
33 | Done! When you access **self.datasource **, it is going to be already populated. 34 | 35 | 36 | ## Contexts 37 | 38 | For you who wondered what is the context parameter on the DPRegistry registerImplementation:forProtocol:context: method. Defining a context on the injection and in the registration can be used to provide different implementations. 39 | Just change the injection declaration to: 40 |
@property (setter=injected_post:) id<DPDatasourceProtocol> postDatasource;  
41 | @property (setter=injected_stupid:) id<DPDatasourceProtocol> anotherStupidDatasource;
42 | And the registration to: 43 |
[[DPRegistry sharedRegistry] registerImplementation:[DPPostDatasource class] forProtocol:@protocol(DPDatasourceProtocol) context:@“post”];
44 | [[DPRegistry sharedRegistry] registerImplementation:[DPStupidDatasource class] forProtocol:@protocol(DPDatasourceProtocol) context:@“stupid”];
45 | Any word that comes after the _ (underline) is the context name. 46 | 47 | ### Wanna see a example on a real project? 48 | 49 | Check out this small project ! 50 | https://github.com/rafagonc/Reading-List/ 51 | 52 | And the registrations! 53 | https://github.com/rafagonc/Reading-List/blob/master/ReadingList/REDDepedencyInjection.m 54 | 55 | ## License 56 | 57 | The MIT License (MIT) 58 | Copyright (c) 2015 Rafael Gonçalves 59 | Permission is hereby granted, free of charge, to any person obtaining a copy 60 | of this software and associated documentation files (the "Software"), to deal 61 | in the Software without restriction, including without limitation the rights 62 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 63 | copies of the Software, and to permit persons to whom the Software is 64 | furnished to do so, subject to the following conditions: 65 | The above copyright notice and this permission notice shall be included in all 66 | copies or substantial portions of the Software. 67 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 68 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 69 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 70 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 71 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 72 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 73 | SOFTWARE. 74 | -------------------------------------------------------------------------------- /Depend.xcodeproj/xcuserdata/rafagonc.xcuserdatad/xcschemes/Depend.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 29 | 35 | 36 | 37 | 38 | 39 | 44 | 45 | 47 | 53 | 54 | 55 | 56 | 57 | 63 | 64 | 65 | 66 | 75 | 76 | 82 | 83 | 84 | 85 | 86 | 87 | 93 | 94 | 100 | 101 | 102 | 103 | 105 | 106 | 109 | 110 | 111 | -------------------------------------------------------------------------------- /DependProject/DependProject/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 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 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 126 | 127 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | -------------------------------------------------------------------------------- /Depend.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 2A10B37D1BAA6FC10088592B /* DependTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A10B37C1BAA6FC10088592B /* DependTests.m */; }; 11 | 2A10B3801BAA72920088592B /* EXInjectedClass.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A10B37F1BAA72920088592B /* EXInjectedClass.m */; }; 12 | 2A28576F1BAA4B6400AEE15C /* libDepend.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 2A2857631BAA4B6400AEE15C /* libDepend.a */; }; 13 | 2A28578F1BAB519100AEE15C /* EXProtocolImplementation.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A28578E1BAB519100AEE15C /* EXProtocolImplementation.m */; }; 14 | 2A2857921BAB519E00AEE15C /* EXAnotherProtocolImplementation.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A2857911BAB519E00AEE15C /* EXAnotherProtocolImplementation.m */; }; 15 | 2A2E64941BABC7D6001752FE /* DPCache.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A2E64891BABC7D6001752FE /* DPCache.m */; }; 16 | 2A2E64951BABC7D6001752FE /* DPImplementationKey.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A2E648B1BABC7D6001752FE /* DPImplementationKey.m */; }; 17 | 2A2E64961BABC7D6001752FE /* DPInjectionDescriptor.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A2E648D1BABC7D6001752FE /* DPInjectionDescriptor.m */; }; 18 | 2A2E64971BABC7D6001752FE /* DPInjectionPropertyDescriptor.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A2E648F1BABC7D6001752FE /* DPInjectionPropertyDescriptor.m */; }; 19 | 2A2E64981BABC7D6001752FE /* DPInjector.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A2E64911BABC7D6001752FE /* DPInjector.m */; }; 20 | 2A2E64991BABC7D6001752FE /* DPRegistry.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A2E64931BABC7D6001752FE /* DPRegistry.m */; }; 21 | 2A92CA341BDFE33C004044D7 /* EXInjectedSubclass.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A92CA331BDFE33C004044D7 /* EXInjectedSubclass.m */; }; 22 | /* End PBXBuildFile section */ 23 | 24 | /* Begin PBXContainerItemProxy section */ 25 | 2A2857701BAA4B6400AEE15C /* PBXContainerItemProxy */ = { 26 | isa = PBXContainerItemProxy; 27 | containerPortal = 2A28575B1BAA4B6400AEE15C /* Project object */; 28 | proxyType = 1; 29 | remoteGlobalIDString = 2A2857621BAA4B6400AEE15C; 30 | remoteInfo = Depend; 31 | }; 32 | /* End PBXContainerItemProxy section */ 33 | 34 | /* Begin PBXCopyFilesBuildPhase section */ 35 | 2A2857611BAA4B6400AEE15C /* CopyFiles */ = { 36 | isa = PBXCopyFilesBuildPhase; 37 | buildActionMask = 2147483647; 38 | dstPath = "include/$(PRODUCT_NAME)"; 39 | dstSubfolderSpec = 16; 40 | files = ( 41 | ); 42 | runOnlyForDeploymentPostprocessing = 0; 43 | }; 44 | /* End PBXCopyFilesBuildPhase section */ 45 | 46 | /* Begin PBXFileReference section */ 47 | 2A10B37C1BAA6FC10088592B /* DependTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DependTests.m; sourceTree = ""; }; 48 | 2A10B37E1BAA72920088592B /* EXInjectedClass.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EXInjectedClass.h; sourceTree = ""; }; 49 | 2A10B37F1BAA72920088592B /* EXInjectedClass.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = EXInjectedClass.m; sourceTree = ""; }; 50 | 2A10B3811BAA729F0088592B /* EXProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EXProtocol.h; sourceTree = ""; }; 51 | 2A2857631BAA4B6400AEE15C /* libDepend.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libDepend.a; sourceTree = BUILT_PRODUCTS_DIR; }; 52 | 2A28576E1BAA4B6400AEE15C /* DependTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = DependTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 53 | 2A2857741BAA4B6400AEE15C /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 54 | 2A28578D1BAB519100AEE15C /* EXProtocolImplementation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EXProtocolImplementation.h; sourceTree = ""; }; 55 | 2A28578E1BAB519100AEE15C /* EXProtocolImplementation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = EXProtocolImplementation.m; sourceTree = ""; }; 56 | 2A2857901BAB519E00AEE15C /* EXAnotherProtocolImplementation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EXAnotherProtocolImplementation.h; sourceTree = ""; }; 57 | 2A2857911BAB519E00AEE15C /* EXAnotherProtocolImplementation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = EXAnotherProtocolImplementation.m; sourceTree = ""; }; 58 | 2A2E64881BABC7D6001752FE /* DPCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DPCache.h; path = Pod/Classes/DPCache.h; sourceTree = SOURCE_ROOT; }; 59 | 2A2E64891BABC7D6001752FE /* DPCache.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = DPCache.m; path = Pod/Classes/DPCache.m; sourceTree = SOURCE_ROOT; }; 60 | 2A2E648A1BABC7D6001752FE /* DPImplementationKey.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DPImplementationKey.h; path = Pod/Classes/DPImplementationKey.h; sourceTree = SOURCE_ROOT; }; 61 | 2A2E648B1BABC7D6001752FE /* DPImplementationKey.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = DPImplementationKey.m; path = Pod/Classes/DPImplementationKey.m; sourceTree = SOURCE_ROOT; }; 62 | 2A2E648C1BABC7D6001752FE /* DPInjectionDescriptor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DPInjectionDescriptor.h; path = Pod/Classes/DPInjectionDescriptor.h; sourceTree = SOURCE_ROOT; }; 63 | 2A2E648D1BABC7D6001752FE /* DPInjectionDescriptor.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = DPInjectionDescriptor.m; path = Pod/Classes/DPInjectionDescriptor.m; sourceTree = SOURCE_ROOT; }; 64 | 2A2E648E1BABC7D6001752FE /* DPInjectionPropertyDescriptor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DPInjectionPropertyDescriptor.h; path = Pod/Classes/DPInjectionPropertyDescriptor.h; sourceTree = SOURCE_ROOT; }; 65 | 2A2E648F1BABC7D6001752FE /* DPInjectionPropertyDescriptor.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = DPInjectionPropertyDescriptor.m; path = Pod/Classes/DPInjectionPropertyDescriptor.m; sourceTree = SOURCE_ROOT; }; 66 | 2A2E64901BABC7D6001752FE /* DPInjector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DPInjector.h; path = Pod/Classes/DPInjector.h; sourceTree = SOURCE_ROOT; }; 67 | 2A2E64911BABC7D6001752FE /* DPInjector.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = DPInjector.m; path = Pod/Classes/DPInjector.m; sourceTree = SOURCE_ROOT; }; 68 | 2A2E64921BABC7D6001752FE /* DPRegistry.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DPRegistry.h; path = Pod/Classes/DPRegistry.h; sourceTree = SOURCE_ROOT; }; 69 | 2A2E64931BABC7D6001752FE /* DPRegistry.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = DPRegistry.m; path = Pod/Classes/DPRegistry.m; sourceTree = SOURCE_ROOT; }; 70 | 2A92CA321BDFE33C004044D7 /* EXInjectedSubclass.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EXInjectedSubclass.h; sourceTree = ""; }; 71 | 2A92CA331BDFE33C004044D7 /* EXInjectedSubclass.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = EXInjectedSubclass.m; sourceTree = ""; }; 72 | 4458D1A41D3808A40053C14A /* DPImplementationValue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DPImplementationValue.h; path = Pod/Classes/DPImplementationValue.h; sourceTree = SOURCE_ROOT; }; 73 | /* End PBXFileReference section */ 74 | 75 | /* Begin PBXFrameworksBuildPhase section */ 76 | 2A2857601BAA4B6400AEE15C /* Frameworks */ = { 77 | isa = PBXFrameworksBuildPhase; 78 | buildActionMask = 2147483647; 79 | files = ( 80 | ); 81 | runOnlyForDeploymentPostprocessing = 0; 82 | }; 83 | 2A28576B1BAA4B6400AEE15C /* Frameworks */ = { 84 | isa = PBXFrameworksBuildPhase; 85 | buildActionMask = 2147483647; 86 | files = ( 87 | 2A28576F1BAA4B6400AEE15C /* libDepend.a in Frameworks */, 88 | ); 89 | runOnlyForDeploymentPostprocessing = 0; 90 | }; 91 | /* End PBXFrameworksBuildPhase section */ 92 | 93 | /* Begin PBXGroup section */ 94 | 2A28575A1BAA4B6400AEE15C = { 95 | isa = PBXGroup; 96 | children = ( 97 | 2A2857651BAA4B6400AEE15C /* Depend */, 98 | 2A2857721BAA4B6400AEE15C /* DependTests */, 99 | 2A2857641BAA4B6400AEE15C /* Products */, 100 | ); 101 | sourceTree = ""; 102 | }; 103 | 2A2857641BAA4B6400AEE15C /* Products */ = { 104 | isa = PBXGroup; 105 | children = ( 106 | 2A2857631BAA4B6400AEE15C /* libDepend.a */, 107 | 2A28576E1BAA4B6400AEE15C /* DependTests.xctest */, 108 | ); 109 | name = Products; 110 | sourceTree = ""; 111 | }; 112 | 2A2857651BAA4B6400AEE15C /* Depend */ = { 113 | isa = PBXGroup; 114 | children = ( 115 | 2A2E64881BABC7D6001752FE /* DPCache.h */, 116 | 2A2E64891BABC7D6001752FE /* DPCache.m */, 117 | 2A2E648A1BABC7D6001752FE /* DPImplementationKey.h */, 118 | 2A2E648B1BABC7D6001752FE /* DPImplementationKey.m */, 119 | 2A2E648C1BABC7D6001752FE /* DPInjectionDescriptor.h */, 120 | 2A2E648D1BABC7D6001752FE /* DPInjectionDescriptor.m */, 121 | 2A2E648E1BABC7D6001752FE /* DPInjectionPropertyDescriptor.h */, 122 | 2A2E648F1BABC7D6001752FE /* DPInjectionPropertyDescriptor.m */, 123 | 2A2E64901BABC7D6001752FE /* DPInjector.h */, 124 | 2A2E64911BABC7D6001752FE /* DPInjector.m */, 125 | 2A2E64921BABC7D6001752FE /* DPRegistry.h */, 126 | 2A2E64931BABC7D6001752FE /* DPRegistry.m */, 127 | 4458D1A41D3808A40053C14A /* DPImplementationValue.h */, 128 | ); 129 | path = Depend; 130 | sourceTree = ""; 131 | }; 132 | 2A2857721BAA4B6400AEE15C /* DependTests */ = { 133 | isa = PBXGroup; 134 | children = ( 135 | 2A10B37C1BAA6FC10088592B /* DependTests.m */, 136 | 2A2857731BAA4B6400AEE15C /* Supporting Files */, 137 | ); 138 | path = DependTests; 139 | sourceTree = ""; 140 | }; 141 | 2A2857731BAA4B6400AEE15C /* Supporting Files */ = { 142 | isa = PBXGroup; 143 | children = ( 144 | 2A2857741BAA4B6400AEE15C /* Info.plist */, 145 | 2A10B3811BAA729F0088592B /* EXProtocol.h */, 146 | 2A10B37E1BAA72920088592B /* EXInjectedClass.h */, 147 | 2A10B37F1BAA72920088592B /* EXInjectedClass.m */, 148 | 2A28578D1BAB519100AEE15C /* EXProtocolImplementation.h */, 149 | 2A28578E1BAB519100AEE15C /* EXProtocolImplementation.m */, 150 | 2A2857901BAB519E00AEE15C /* EXAnotherProtocolImplementation.h */, 151 | 2A2857911BAB519E00AEE15C /* EXAnotherProtocolImplementation.m */, 152 | 2A92CA321BDFE33C004044D7 /* EXInjectedSubclass.h */, 153 | 2A92CA331BDFE33C004044D7 /* EXInjectedSubclass.m */, 154 | ); 155 | name = "Supporting Files"; 156 | sourceTree = ""; 157 | }; 158 | /* End PBXGroup section */ 159 | 160 | /* Begin PBXNativeTarget section */ 161 | 2A2857621BAA4B6400AEE15C /* Depend */ = { 162 | isa = PBXNativeTarget; 163 | buildConfigurationList = 2A2857771BAA4B6400AEE15C /* Build configuration list for PBXNativeTarget "Depend" */; 164 | buildPhases = ( 165 | 2A28575F1BAA4B6400AEE15C /* Sources */, 166 | 2A2857601BAA4B6400AEE15C /* Frameworks */, 167 | 2A2857611BAA4B6400AEE15C /* CopyFiles */, 168 | ); 169 | buildRules = ( 170 | ); 171 | dependencies = ( 172 | ); 173 | name = Depend; 174 | productName = Depend; 175 | productReference = 2A2857631BAA4B6400AEE15C /* libDepend.a */; 176 | productType = "com.apple.product-type.library.static"; 177 | }; 178 | 2A28576D1BAA4B6400AEE15C /* DependTests */ = { 179 | isa = PBXNativeTarget; 180 | buildConfigurationList = 2A28577A1BAA4B6400AEE15C /* Build configuration list for PBXNativeTarget "DependTests" */; 181 | buildPhases = ( 182 | 2A28576A1BAA4B6400AEE15C /* Sources */, 183 | 2A28576B1BAA4B6400AEE15C /* Frameworks */, 184 | 2A28576C1BAA4B6400AEE15C /* Resources */, 185 | ); 186 | buildRules = ( 187 | ); 188 | dependencies = ( 189 | 2A2857711BAA4B6400AEE15C /* PBXTargetDependency */, 190 | ); 191 | name = DependTests; 192 | productName = DependTests; 193 | productReference = 2A28576E1BAA4B6400AEE15C /* DependTests.xctest */; 194 | productType = "com.apple.product-type.bundle.unit-test"; 195 | }; 196 | /* End PBXNativeTarget section */ 197 | 198 | /* Begin PBXProject section */ 199 | 2A28575B1BAA4B6400AEE15C /* Project object */ = { 200 | isa = PBXProject; 201 | attributes = { 202 | LastUpgradeCheck = 0640; 203 | ORGANIZATIONNAME = "Rafael Gonçalves"; 204 | TargetAttributes = { 205 | 2A2857621BAA4B6400AEE15C = { 206 | CreatedOnToolsVersion = 6.4; 207 | }; 208 | 2A28576D1BAA4B6400AEE15C = { 209 | CreatedOnToolsVersion = 6.4; 210 | }; 211 | }; 212 | }; 213 | buildConfigurationList = 2A28575E1BAA4B6400AEE15C /* Build configuration list for PBXProject "Depend" */; 214 | compatibilityVersion = "Xcode 3.2"; 215 | developmentRegion = English; 216 | hasScannedForEncodings = 0; 217 | knownRegions = ( 218 | en, 219 | ); 220 | mainGroup = 2A28575A1BAA4B6400AEE15C; 221 | productRefGroup = 2A2857641BAA4B6400AEE15C /* Products */; 222 | projectDirPath = ""; 223 | projectRoot = ""; 224 | targets = ( 225 | 2A2857621BAA4B6400AEE15C /* Depend */, 226 | 2A28576D1BAA4B6400AEE15C /* DependTests */, 227 | ); 228 | }; 229 | /* End PBXProject section */ 230 | 231 | /* Begin PBXResourcesBuildPhase section */ 232 | 2A28576C1BAA4B6400AEE15C /* Resources */ = { 233 | isa = PBXResourcesBuildPhase; 234 | buildActionMask = 2147483647; 235 | files = ( 236 | ); 237 | runOnlyForDeploymentPostprocessing = 0; 238 | }; 239 | /* End PBXResourcesBuildPhase section */ 240 | 241 | /* Begin PBXSourcesBuildPhase section */ 242 | 2A28575F1BAA4B6400AEE15C /* Sources */ = { 243 | isa = PBXSourcesBuildPhase; 244 | buildActionMask = 2147483647; 245 | files = ( 246 | 2A2E64981BABC7D6001752FE /* DPInjector.m in Sources */, 247 | 2A2E64961BABC7D6001752FE /* DPInjectionDescriptor.m in Sources */, 248 | 2A2E64991BABC7D6001752FE /* DPRegistry.m in Sources */, 249 | 2A2E64951BABC7D6001752FE /* DPImplementationKey.m in Sources */, 250 | 2A2E64971BABC7D6001752FE /* DPInjectionPropertyDescriptor.m in Sources */, 251 | 2A2E64941BABC7D6001752FE /* DPCache.m in Sources */, 252 | ); 253 | runOnlyForDeploymentPostprocessing = 0; 254 | }; 255 | 2A28576A1BAA4B6400AEE15C /* Sources */ = { 256 | isa = PBXSourcesBuildPhase; 257 | buildActionMask = 2147483647; 258 | files = ( 259 | 2A92CA341BDFE33C004044D7 /* EXInjectedSubclass.m in Sources */, 260 | 2A10B37D1BAA6FC10088592B /* DependTests.m in Sources */, 261 | 2A10B3801BAA72920088592B /* EXInjectedClass.m in Sources */, 262 | 2A2857921BAB519E00AEE15C /* EXAnotherProtocolImplementation.m in Sources */, 263 | 2A28578F1BAB519100AEE15C /* EXProtocolImplementation.m in Sources */, 264 | ); 265 | runOnlyForDeploymentPostprocessing = 0; 266 | }; 267 | /* End PBXSourcesBuildPhase section */ 268 | 269 | /* Begin PBXTargetDependency section */ 270 | 2A2857711BAA4B6400AEE15C /* PBXTargetDependency */ = { 271 | isa = PBXTargetDependency; 272 | target = 2A2857621BAA4B6400AEE15C /* Depend */; 273 | targetProxy = 2A2857701BAA4B6400AEE15C /* PBXContainerItemProxy */; 274 | }; 275 | /* End PBXTargetDependency section */ 276 | 277 | /* Begin XCBuildConfiguration section */ 278 | 2A2857751BAA4B6400AEE15C /* Debug */ = { 279 | isa = XCBuildConfiguration; 280 | buildSettings = { 281 | ALWAYS_SEARCH_USER_PATHS = NO; 282 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 283 | CLANG_CXX_LIBRARY = "libc++"; 284 | CLANG_ENABLE_MODULES = YES; 285 | CLANG_ENABLE_OBJC_ARC = YES; 286 | CLANG_WARN_BOOL_CONVERSION = YES; 287 | CLANG_WARN_CONSTANT_CONVERSION = YES; 288 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 289 | CLANG_WARN_EMPTY_BODY = YES; 290 | CLANG_WARN_ENUM_CONVERSION = YES; 291 | CLANG_WARN_INT_CONVERSION = YES; 292 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 293 | CLANG_WARN_UNREACHABLE_CODE = YES; 294 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 295 | COPY_PHASE_STRIP = NO; 296 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 297 | ENABLE_STRICT_OBJC_MSGSEND = YES; 298 | GCC_C_LANGUAGE_STANDARD = gnu99; 299 | GCC_DYNAMIC_NO_PIC = NO; 300 | GCC_NO_COMMON_BLOCKS = YES; 301 | GCC_OPTIMIZATION_LEVEL = 0; 302 | GCC_PREPROCESSOR_DEFINITIONS = ( 303 | "DEBUG=1", 304 | "$(inherited)", 305 | ); 306 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 307 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 308 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 309 | GCC_WARN_UNDECLARED_SELECTOR = YES; 310 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 311 | GCC_WARN_UNUSED_FUNCTION = YES; 312 | GCC_WARN_UNUSED_VARIABLE = YES; 313 | IPHONEOS_DEPLOYMENT_TARGET = 8.4; 314 | MTL_ENABLE_DEBUG_INFO = YES; 315 | ONLY_ACTIVE_ARCH = YES; 316 | SDKROOT = iphoneos; 317 | }; 318 | name = Debug; 319 | }; 320 | 2A2857761BAA4B6400AEE15C /* Release */ = { 321 | isa = XCBuildConfiguration; 322 | buildSettings = { 323 | ALWAYS_SEARCH_USER_PATHS = NO; 324 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 325 | CLANG_CXX_LIBRARY = "libc++"; 326 | CLANG_ENABLE_MODULES = YES; 327 | CLANG_ENABLE_OBJC_ARC = YES; 328 | CLANG_WARN_BOOL_CONVERSION = YES; 329 | CLANG_WARN_CONSTANT_CONVERSION = YES; 330 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 331 | CLANG_WARN_EMPTY_BODY = YES; 332 | CLANG_WARN_ENUM_CONVERSION = YES; 333 | CLANG_WARN_INT_CONVERSION = YES; 334 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 335 | CLANG_WARN_UNREACHABLE_CODE = YES; 336 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 337 | COPY_PHASE_STRIP = NO; 338 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 339 | ENABLE_NS_ASSERTIONS = NO; 340 | ENABLE_STRICT_OBJC_MSGSEND = YES; 341 | GCC_C_LANGUAGE_STANDARD = gnu99; 342 | GCC_NO_COMMON_BLOCKS = YES; 343 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 344 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 345 | GCC_WARN_UNDECLARED_SELECTOR = YES; 346 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 347 | GCC_WARN_UNUSED_FUNCTION = YES; 348 | GCC_WARN_UNUSED_VARIABLE = YES; 349 | IPHONEOS_DEPLOYMENT_TARGET = 8.4; 350 | MTL_ENABLE_DEBUG_INFO = NO; 351 | SDKROOT = iphoneos; 352 | VALIDATE_PRODUCT = YES; 353 | }; 354 | name = Release; 355 | }; 356 | 2A2857781BAA4B6400AEE15C /* Debug */ = { 357 | isa = XCBuildConfiguration; 358 | buildSettings = { 359 | OTHER_LDFLAGS = "-ObjC"; 360 | PRODUCT_NAME = "$(TARGET_NAME)"; 361 | SKIP_INSTALL = YES; 362 | }; 363 | name = Debug; 364 | }; 365 | 2A2857791BAA4B6400AEE15C /* Release */ = { 366 | isa = XCBuildConfiguration; 367 | buildSettings = { 368 | OTHER_LDFLAGS = "-ObjC"; 369 | PRODUCT_NAME = "$(TARGET_NAME)"; 370 | SKIP_INSTALL = YES; 371 | }; 372 | name = Release; 373 | }; 374 | 2A28577B1BAA4B6400AEE15C /* Debug */ = { 375 | isa = XCBuildConfiguration; 376 | buildSettings = { 377 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 378 | FRAMEWORK_SEARCH_PATHS = ( 379 | "$(SDKROOT)/Developer/Library/Frameworks", 380 | "$(inherited)", 381 | ); 382 | GCC_PREPROCESSOR_DEFINITIONS = ( 383 | "DEBUG=1", 384 | "$(inherited)", 385 | ); 386 | INFOPLIST_FILE = DependTests/Info.plist; 387 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 388 | PRODUCT_NAME = "$(TARGET_NAME)"; 389 | }; 390 | name = Debug; 391 | }; 392 | 2A28577C1BAA4B6400AEE15C /* Release */ = { 393 | isa = XCBuildConfiguration; 394 | buildSettings = { 395 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 396 | FRAMEWORK_SEARCH_PATHS = ( 397 | "$(SDKROOT)/Developer/Library/Frameworks", 398 | "$(inherited)", 399 | ); 400 | INFOPLIST_FILE = DependTests/Info.plist; 401 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 402 | PRODUCT_NAME = "$(TARGET_NAME)"; 403 | }; 404 | name = Release; 405 | }; 406 | /* End XCBuildConfiguration section */ 407 | 408 | /* Begin XCConfigurationList section */ 409 | 2A28575E1BAA4B6400AEE15C /* Build configuration list for PBXProject "Depend" */ = { 410 | isa = XCConfigurationList; 411 | buildConfigurations = ( 412 | 2A2857751BAA4B6400AEE15C /* Debug */, 413 | 2A2857761BAA4B6400AEE15C /* Release */, 414 | ); 415 | defaultConfigurationIsVisible = 0; 416 | defaultConfigurationName = Release; 417 | }; 418 | 2A2857771BAA4B6400AEE15C /* Build configuration list for PBXNativeTarget "Depend" */ = { 419 | isa = XCConfigurationList; 420 | buildConfigurations = ( 421 | 2A2857781BAA4B6400AEE15C /* Debug */, 422 | 2A2857791BAA4B6400AEE15C /* Release */, 423 | ); 424 | defaultConfigurationIsVisible = 0; 425 | defaultConfigurationName = Release; 426 | }; 427 | 2A28577A1BAA4B6400AEE15C /* Build configuration list for PBXNativeTarget "DependTests" */ = { 428 | isa = XCConfigurationList; 429 | buildConfigurations = ( 430 | 2A28577B1BAA4B6400AEE15C /* Debug */, 431 | 2A28577C1BAA4B6400AEE15C /* Release */, 432 | ); 433 | defaultConfigurationIsVisible = 0; 434 | defaultConfigurationName = Release; 435 | }; 436 | /* End XCConfigurationList section */ 437 | }; 438 | rootObject = 2A28575B1BAA4B6400AEE15C /* Project object */; 439 | } 440 | -------------------------------------------------------------------------------- /DependProject/DependProject.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 2A10B40A1BABB4280088592B /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A10B4091BABB4280088592B /* main.m */; }; 11 | 2A10B40D1BABB4280088592B /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A10B40C1BABB4280088592B /* AppDelegate.m */; }; 12 | 2A10B4101BABB4280088592B /* ViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A10B40F1BABB4280088592B /* ViewController.m */; }; 13 | 2A10B4131BABB4280088592B /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 2A10B4111BABB4280088592B /* Main.storyboard */; }; 14 | 2A10B4151BABB4280088592B /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 2A10B4141BABB4280088592B /* Images.xcassets */; }; 15 | 2A10B4181BABB4280088592B /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 2A10B4161BABB4280088592B /* LaunchScreen.xib */; }; 16 | 2A10B4241BABB4280088592B /* DependProjectTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A10B4231BABB4280088592B /* DependProjectTests.m */; }; 17 | 2A10B43B1BABB59E0088592B /* libDepend.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 2A10B43A1BABB59E0088592B /* libDepend.a */; }; 18 | 2A2E647C1BABB683001752FE /* DPDatasource.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A2E647B1BABB683001752FE /* DPDatasource.m */; }; 19 | 2A2E64801BABB797001752FE /* DPRegister.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A2E647F1BABB797001752FE /* DPRegister.m */; }; 20 | 2A2E64831BABB899001752FE /* DPSecondDatasource.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A2E64821BABB899001752FE /* DPSecondDatasource.m */; }; 21 | /* End PBXBuildFile section */ 22 | 23 | /* Begin PBXContainerItemProxy section */ 24 | 2A10B41E1BABB4280088592B /* PBXContainerItemProxy */ = { 25 | isa = PBXContainerItemProxy; 26 | containerPortal = 2A10B3FC1BABB4280088592B /* Project object */; 27 | proxyType = 1; 28 | remoteGlobalIDString = 2A10B4031BABB4280088592B; 29 | remoteInfo = DependProject; 30 | }; 31 | /* End PBXContainerItemProxy section */ 32 | 33 | /* Begin PBXFileReference section */ 34 | 2A10B4041BABB4280088592B /* DependProject.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = DependProject.app; sourceTree = BUILT_PRODUCTS_DIR; }; 35 | 2A10B4081BABB4280088592B /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 36 | 2A10B4091BABB4280088592B /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 37 | 2A10B40B1BABB4280088592B /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; 38 | 2A10B40C1BABB4280088592B /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; }; 39 | 2A10B40E1BABB4280088592B /* ViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ViewController.h; sourceTree = ""; }; 40 | 2A10B40F1BABB4280088592B /* ViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ViewController.m; sourceTree = ""; }; 41 | 2A10B4121BABB4280088592B /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 42 | 2A10B4141BABB4280088592B /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = ""; }; 43 | 2A10B4171BABB4280088592B /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = ""; }; 44 | 2A10B41D1BABB4280088592B /* DependProjectTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = DependProjectTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 45 | 2A10B4221BABB4280088592B /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 46 | 2A10B4231BABB4280088592B /* DependProjectTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = DependProjectTests.m; sourceTree = ""; }; 47 | 2A10B43A1BABB59E0088592B /* libDepend.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libDepend.a; path = "../../../../../Library/Developer/Xcode/DerivedData/Depend-djrujyxodhamrhfahjjaovwgfrtd/Build/Products/Debug-iphoneos/libDepend.a"; sourceTree = ""; }; 48 | 2A2E647A1BABB683001752FE /* DPDatasource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DPDatasource.h; sourceTree = ""; }; 49 | 2A2E647B1BABB683001752FE /* DPDatasource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DPDatasource.m; sourceTree = ""; }; 50 | 2A2E647D1BABB69D001752FE /* DPDatasourceProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DPDatasourceProtocol.h; sourceTree = ""; }; 51 | 2A2E647E1BABB797001752FE /* DPRegister.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DPRegister.h; sourceTree = ""; }; 52 | 2A2E647F1BABB797001752FE /* DPRegister.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DPRegister.m; sourceTree = ""; }; 53 | 2A2E64811BABB899001752FE /* DPSecondDatasource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DPSecondDatasource.h; sourceTree = ""; }; 54 | 2A2E64821BABB899001752FE /* DPSecondDatasource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DPSecondDatasource.m; sourceTree = ""; }; 55 | /* End PBXFileReference section */ 56 | 57 | /* Begin PBXFrameworksBuildPhase section */ 58 | 2A10B4011BABB4280088592B /* Frameworks */ = { 59 | isa = PBXFrameworksBuildPhase; 60 | buildActionMask = 2147483647; 61 | files = ( 62 | 2A10B43B1BABB59E0088592B /* libDepend.a in Frameworks */, 63 | ); 64 | runOnlyForDeploymentPostprocessing = 0; 65 | }; 66 | 2A10B41A1BABB4280088592B /* Frameworks */ = { 67 | isa = PBXFrameworksBuildPhase; 68 | buildActionMask = 2147483647; 69 | files = ( 70 | ); 71 | runOnlyForDeploymentPostprocessing = 0; 72 | }; 73 | /* End PBXFrameworksBuildPhase section */ 74 | 75 | /* Begin PBXGroup section */ 76 | 2A10B3FB1BABB4280088592B = { 77 | isa = PBXGroup; 78 | children = ( 79 | 2A10B4061BABB4280088592B /* DependProject */, 80 | 2A10B4201BABB4280088592B /* DependProjectTests */, 81 | 2A10B4051BABB4280088592B /* Products */, 82 | ); 83 | sourceTree = ""; 84 | }; 85 | 2A10B4051BABB4280088592B /* Products */ = { 86 | isa = PBXGroup; 87 | children = ( 88 | 2A10B4041BABB4280088592B /* DependProject.app */, 89 | 2A10B41D1BABB4280088592B /* DependProjectTests.xctest */, 90 | ); 91 | name = Products; 92 | sourceTree = ""; 93 | }; 94 | 2A10B4061BABB4280088592B /* DependProject */ = { 95 | isa = PBXGroup; 96 | children = ( 97 | 2A2E64871BABB954001752FE /* Registration Class */, 98 | 2A2E64841BABB93F001752FE /* Implementations */, 99 | 2A2E64851BABB944001752FE /* Protocol */, 100 | 2A2E64861BABB94D001752FE /* Injected Class */, 101 | 2A10B4071BABB4280088592B /* Supporting Files */, 102 | ); 103 | path = DependProject; 104 | sourceTree = ""; 105 | }; 106 | 2A10B4071BABB4280088592B /* Supporting Files */ = { 107 | isa = PBXGroup; 108 | children = ( 109 | 2A10B40B1BABB4280088592B /* AppDelegate.h */, 110 | 2A10B40C1BABB4280088592B /* AppDelegate.m */, 111 | 2A10B43A1BABB59E0088592B /* libDepend.a */, 112 | 2A10B4111BABB4280088592B /* Main.storyboard */, 113 | 2A10B4141BABB4280088592B /* Images.xcassets */, 114 | 2A10B4161BABB4280088592B /* LaunchScreen.xib */, 115 | 2A10B4081BABB4280088592B /* Info.plist */, 116 | 2A10B4091BABB4280088592B /* main.m */, 117 | ); 118 | name = "Supporting Files"; 119 | sourceTree = ""; 120 | }; 121 | 2A10B4201BABB4280088592B /* DependProjectTests */ = { 122 | isa = PBXGroup; 123 | children = ( 124 | 2A10B4231BABB4280088592B /* DependProjectTests.m */, 125 | 2A10B4211BABB4280088592B /* Supporting Files */, 126 | ); 127 | path = DependProjectTests; 128 | sourceTree = ""; 129 | }; 130 | 2A10B4211BABB4280088592B /* Supporting Files */ = { 131 | isa = PBXGroup; 132 | children = ( 133 | 2A10B4221BABB4280088592B /* Info.plist */, 134 | ); 135 | name = "Supporting Files"; 136 | sourceTree = ""; 137 | }; 138 | 2A2E64841BABB93F001752FE /* Implementations */ = { 139 | isa = PBXGroup; 140 | children = ( 141 | 2A2E64811BABB899001752FE /* DPSecondDatasource.h */, 142 | 2A2E64821BABB899001752FE /* DPSecondDatasource.m */, 143 | 2A2E647A1BABB683001752FE /* DPDatasource.h */, 144 | 2A2E647B1BABB683001752FE /* DPDatasource.m */, 145 | ); 146 | name = Implementations; 147 | sourceTree = ""; 148 | }; 149 | 2A2E64851BABB944001752FE /* Protocol */ = { 150 | isa = PBXGroup; 151 | children = ( 152 | 2A2E647D1BABB69D001752FE /* DPDatasourceProtocol.h */, 153 | ); 154 | name = Protocol; 155 | sourceTree = ""; 156 | }; 157 | 2A2E64861BABB94D001752FE /* Injected Class */ = { 158 | isa = PBXGroup; 159 | children = ( 160 | 2A10B40E1BABB4280088592B /* ViewController.h */, 161 | 2A10B40F1BABB4280088592B /* ViewController.m */, 162 | ); 163 | name = "Injected Class"; 164 | sourceTree = ""; 165 | }; 166 | 2A2E64871BABB954001752FE /* Registration Class */ = { 167 | isa = PBXGroup; 168 | children = ( 169 | 2A2E647E1BABB797001752FE /* DPRegister.h */, 170 | 2A2E647F1BABB797001752FE /* DPRegister.m */, 171 | ); 172 | name = "Registration Class"; 173 | sourceTree = ""; 174 | }; 175 | /* End PBXGroup section */ 176 | 177 | /* Begin PBXNativeTarget section */ 178 | 2A10B4031BABB4280088592B /* DependProject */ = { 179 | isa = PBXNativeTarget; 180 | buildConfigurationList = 2A10B4271BABB4280088592B /* Build configuration list for PBXNativeTarget "DependProject" */; 181 | buildPhases = ( 182 | 2A10B4001BABB4280088592B /* Sources */, 183 | 2A10B4011BABB4280088592B /* Frameworks */, 184 | 2A10B4021BABB4280088592B /* Resources */, 185 | ); 186 | buildRules = ( 187 | ); 188 | dependencies = ( 189 | ); 190 | name = DependProject; 191 | productName = DependProject; 192 | productReference = 2A10B4041BABB4280088592B /* DependProject.app */; 193 | productType = "com.apple.product-type.application"; 194 | }; 195 | 2A10B41C1BABB4280088592B /* DependProjectTests */ = { 196 | isa = PBXNativeTarget; 197 | buildConfigurationList = 2A10B42A1BABB4280088592B /* Build configuration list for PBXNativeTarget "DependProjectTests" */; 198 | buildPhases = ( 199 | 2A10B4191BABB4280088592B /* Sources */, 200 | 2A10B41A1BABB4280088592B /* Frameworks */, 201 | 2A10B41B1BABB4280088592B /* Resources */, 202 | ); 203 | buildRules = ( 204 | ); 205 | dependencies = ( 206 | 2A10B41F1BABB4280088592B /* PBXTargetDependency */, 207 | ); 208 | name = DependProjectTests; 209 | productName = DependProjectTests; 210 | productReference = 2A10B41D1BABB4280088592B /* DependProjectTests.xctest */; 211 | productType = "com.apple.product-type.bundle.unit-test"; 212 | }; 213 | /* End PBXNativeTarget section */ 214 | 215 | /* Begin PBXProject section */ 216 | 2A10B3FC1BABB4280088592B /* Project object */ = { 217 | isa = PBXProject; 218 | attributes = { 219 | LastUpgradeCheck = 0640; 220 | ORGANIZATIONNAME = "Rafael Gonzalves"; 221 | TargetAttributes = { 222 | 2A10B4031BABB4280088592B = { 223 | CreatedOnToolsVersion = 6.4; 224 | }; 225 | 2A10B41C1BABB4280088592B = { 226 | CreatedOnToolsVersion = 6.4; 227 | TestTargetID = 2A10B4031BABB4280088592B; 228 | }; 229 | }; 230 | }; 231 | buildConfigurationList = 2A10B3FF1BABB4280088592B /* Build configuration list for PBXProject "DependProject" */; 232 | compatibilityVersion = "Xcode 3.2"; 233 | developmentRegion = English; 234 | hasScannedForEncodings = 0; 235 | knownRegions = ( 236 | en, 237 | Base, 238 | ); 239 | mainGroup = 2A10B3FB1BABB4280088592B; 240 | productRefGroup = 2A10B4051BABB4280088592B /* Products */; 241 | projectDirPath = ""; 242 | projectRoot = ""; 243 | targets = ( 244 | 2A10B4031BABB4280088592B /* DependProject */, 245 | 2A10B41C1BABB4280088592B /* DependProjectTests */, 246 | ); 247 | }; 248 | /* End PBXProject section */ 249 | 250 | /* Begin PBXResourcesBuildPhase section */ 251 | 2A10B4021BABB4280088592B /* Resources */ = { 252 | isa = PBXResourcesBuildPhase; 253 | buildActionMask = 2147483647; 254 | files = ( 255 | 2A10B4131BABB4280088592B /* Main.storyboard in Resources */, 256 | 2A10B4181BABB4280088592B /* LaunchScreen.xib in Resources */, 257 | 2A10B4151BABB4280088592B /* Images.xcassets in Resources */, 258 | ); 259 | runOnlyForDeploymentPostprocessing = 0; 260 | }; 261 | 2A10B41B1BABB4280088592B /* Resources */ = { 262 | isa = PBXResourcesBuildPhase; 263 | buildActionMask = 2147483647; 264 | files = ( 265 | ); 266 | runOnlyForDeploymentPostprocessing = 0; 267 | }; 268 | /* End PBXResourcesBuildPhase section */ 269 | 270 | /* Begin PBXSourcesBuildPhase section */ 271 | 2A10B4001BABB4280088592B /* Sources */ = { 272 | isa = PBXSourcesBuildPhase; 273 | buildActionMask = 2147483647; 274 | files = ( 275 | 2A2E64831BABB899001752FE /* DPSecondDatasource.m in Sources */, 276 | 2A2E647C1BABB683001752FE /* DPDatasource.m in Sources */, 277 | 2A10B4101BABB4280088592B /* ViewController.m in Sources */, 278 | 2A10B40D1BABB4280088592B /* AppDelegate.m in Sources */, 279 | 2A2E64801BABB797001752FE /* DPRegister.m in Sources */, 280 | 2A10B40A1BABB4280088592B /* main.m in Sources */, 281 | ); 282 | runOnlyForDeploymentPostprocessing = 0; 283 | }; 284 | 2A10B4191BABB4280088592B /* Sources */ = { 285 | isa = PBXSourcesBuildPhase; 286 | buildActionMask = 2147483647; 287 | files = ( 288 | 2A10B4241BABB4280088592B /* DependProjectTests.m in Sources */, 289 | ); 290 | runOnlyForDeploymentPostprocessing = 0; 291 | }; 292 | /* End PBXSourcesBuildPhase section */ 293 | 294 | /* Begin PBXTargetDependency section */ 295 | 2A10B41F1BABB4280088592B /* PBXTargetDependency */ = { 296 | isa = PBXTargetDependency; 297 | target = 2A10B4031BABB4280088592B /* DependProject */; 298 | targetProxy = 2A10B41E1BABB4280088592B /* PBXContainerItemProxy */; 299 | }; 300 | /* End PBXTargetDependency section */ 301 | 302 | /* Begin PBXVariantGroup section */ 303 | 2A10B4111BABB4280088592B /* Main.storyboard */ = { 304 | isa = PBXVariantGroup; 305 | children = ( 306 | 2A10B4121BABB4280088592B /* Base */, 307 | ); 308 | name = Main.storyboard; 309 | sourceTree = ""; 310 | }; 311 | 2A10B4161BABB4280088592B /* LaunchScreen.xib */ = { 312 | isa = PBXVariantGroup; 313 | children = ( 314 | 2A10B4171BABB4280088592B /* Base */, 315 | ); 316 | name = LaunchScreen.xib; 317 | sourceTree = ""; 318 | }; 319 | /* End PBXVariantGroup section */ 320 | 321 | /* Begin XCBuildConfiguration section */ 322 | 2A10B4251BABB4280088592B /* Debug */ = { 323 | isa = XCBuildConfiguration; 324 | buildSettings = { 325 | ALWAYS_SEARCH_USER_PATHS = NO; 326 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 327 | CLANG_CXX_LIBRARY = "libc++"; 328 | CLANG_ENABLE_MODULES = YES; 329 | CLANG_ENABLE_OBJC_ARC = YES; 330 | CLANG_WARN_BOOL_CONVERSION = YES; 331 | CLANG_WARN_CONSTANT_CONVERSION = YES; 332 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 333 | CLANG_WARN_EMPTY_BODY = YES; 334 | CLANG_WARN_ENUM_CONVERSION = YES; 335 | CLANG_WARN_INT_CONVERSION = YES; 336 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 337 | CLANG_WARN_UNREACHABLE_CODE = YES; 338 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 339 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 340 | COPY_PHASE_STRIP = NO; 341 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 342 | ENABLE_STRICT_OBJC_MSGSEND = YES; 343 | GCC_C_LANGUAGE_STANDARD = gnu99; 344 | GCC_DYNAMIC_NO_PIC = NO; 345 | GCC_NO_COMMON_BLOCKS = YES; 346 | GCC_OPTIMIZATION_LEVEL = 0; 347 | GCC_PREPROCESSOR_DEFINITIONS = ( 348 | "DEBUG=1", 349 | "$(inherited)", 350 | ); 351 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 352 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 353 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 354 | GCC_WARN_UNDECLARED_SELECTOR = YES; 355 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 356 | GCC_WARN_UNUSED_FUNCTION = YES; 357 | GCC_WARN_UNUSED_VARIABLE = YES; 358 | IPHONEOS_DEPLOYMENT_TARGET = 8.4; 359 | MTL_ENABLE_DEBUG_INFO = YES; 360 | ONLY_ACTIVE_ARCH = YES; 361 | SDKROOT = iphoneos; 362 | }; 363 | name = Debug; 364 | }; 365 | 2A10B4261BABB4280088592B /* Release */ = { 366 | isa = XCBuildConfiguration; 367 | buildSettings = { 368 | ALWAYS_SEARCH_USER_PATHS = NO; 369 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 370 | CLANG_CXX_LIBRARY = "libc++"; 371 | CLANG_ENABLE_MODULES = YES; 372 | CLANG_ENABLE_OBJC_ARC = YES; 373 | CLANG_WARN_BOOL_CONVERSION = YES; 374 | CLANG_WARN_CONSTANT_CONVERSION = YES; 375 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 376 | CLANG_WARN_EMPTY_BODY = YES; 377 | CLANG_WARN_ENUM_CONVERSION = YES; 378 | CLANG_WARN_INT_CONVERSION = YES; 379 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 380 | CLANG_WARN_UNREACHABLE_CODE = YES; 381 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 382 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 383 | COPY_PHASE_STRIP = NO; 384 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 385 | ENABLE_NS_ASSERTIONS = NO; 386 | ENABLE_STRICT_OBJC_MSGSEND = YES; 387 | GCC_C_LANGUAGE_STANDARD = gnu99; 388 | GCC_NO_COMMON_BLOCKS = YES; 389 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 390 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 391 | GCC_WARN_UNDECLARED_SELECTOR = YES; 392 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 393 | GCC_WARN_UNUSED_FUNCTION = YES; 394 | GCC_WARN_UNUSED_VARIABLE = YES; 395 | IPHONEOS_DEPLOYMENT_TARGET = 8.4; 396 | MTL_ENABLE_DEBUG_INFO = NO; 397 | SDKROOT = iphoneos; 398 | VALIDATE_PRODUCT = YES; 399 | }; 400 | name = Release; 401 | }; 402 | 2A10B4281BABB4280088592B /* Debug */ = { 403 | isa = XCBuildConfiguration; 404 | buildSettings = { 405 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 406 | INFOPLIST_FILE = DependProject/Info.plist; 407 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 408 | LIBRARY_SEARCH_PATHS = ( 409 | "$(inherited)", 410 | "$(USER_LIBRARY_DIR)/Developer/Xcode/DerivedData/Depend-djrujyxodhamrhfahjjaovwgfrtd/Build/Products/Debug-iphoneos", 411 | ); 412 | PRODUCT_NAME = "$(TARGET_NAME)"; 413 | }; 414 | name = Debug; 415 | }; 416 | 2A10B4291BABB4280088592B /* Release */ = { 417 | isa = XCBuildConfiguration; 418 | buildSettings = { 419 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 420 | INFOPLIST_FILE = DependProject/Info.plist; 421 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 422 | LIBRARY_SEARCH_PATHS = ( 423 | "$(inherited)", 424 | "$(USER_LIBRARY_DIR)/Developer/Xcode/DerivedData/Depend-djrujyxodhamrhfahjjaovwgfrtd/Build/Products/Debug-iphoneos", 425 | ); 426 | PRODUCT_NAME = "$(TARGET_NAME)"; 427 | }; 428 | name = Release; 429 | }; 430 | 2A10B42B1BABB4280088592B /* Debug */ = { 431 | isa = XCBuildConfiguration; 432 | buildSettings = { 433 | BUNDLE_LOADER = "$(TEST_HOST)"; 434 | FRAMEWORK_SEARCH_PATHS = ( 435 | "$(SDKROOT)/Developer/Library/Frameworks", 436 | "$(inherited)", 437 | ); 438 | GCC_PREPROCESSOR_DEFINITIONS = ( 439 | "DEBUG=1", 440 | "$(inherited)", 441 | ); 442 | INFOPLIST_FILE = DependProjectTests/Info.plist; 443 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 444 | PRODUCT_NAME = "$(TARGET_NAME)"; 445 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/DependProject.app/DependProject"; 446 | }; 447 | name = Debug; 448 | }; 449 | 2A10B42C1BABB4280088592B /* Release */ = { 450 | isa = XCBuildConfiguration; 451 | buildSettings = { 452 | BUNDLE_LOADER = "$(TEST_HOST)"; 453 | FRAMEWORK_SEARCH_PATHS = ( 454 | "$(SDKROOT)/Developer/Library/Frameworks", 455 | "$(inherited)", 456 | ); 457 | INFOPLIST_FILE = DependProjectTests/Info.plist; 458 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 459 | PRODUCT_NAME = "$(TARGET_NAME)"; 460 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/DependProject.app/DependProject"; 461 | }; 462 | name = Release; 463 | }; 464 | /* End XCBuildConfiguration section */ 465 | 466 | /* Begin XCConfigurationList section */ 467 | 2A10B3FF1BABB4280088592B /* Build configuration list for PBXProject "DependProject" */ = { 468 | isa = XCConfigurationList; 469 | buildConfigurations = ( 470 | 2A10B4251BABB4280088592B /* Debug */, 471 | 2A10B4261BABB4280088592B /* Release */, 472 | ); 473 | defaultConfigurationIsVisible = 0; 474 | defaultConfigurationName = Release; 475 | }; 476 | 2A10B4271BABB4280088592B /* Build configuration list for PBXNativeTarget "DependProject" */ = { 477 | isa = XCConfigurationList; 478 | buildConfigurations = ( 479 | 2A10B4281BABB4280088592B /* Debug */, 480 | 2A10B4291BABB4280088592B /* Release */, 481 | ); 482 | defaultConfigurationIsVisible = 0; 483 | defaultConfigurationName = Release; 484 | }; 485 | 2A10B42A1BABB4280088592B /* Build configuration list for PBXNativeTarget "DependProjectTests" */ = { 486 | isa = XCConfigurationList; 487 | buildConfigurations = ( 488 | 2A10B42B1BABB4280088592B /* Debug */, 489 | 2A10B42C1BABB4280088592B /* Release */, 490 | ); 491 | defaultConfigurationIsVisible = 0; 492 | defaultConfigurationName = Release; 493 | }; 494 | /* End XCConfigurationList section */ 495 | }; 496 | rootObject = 2A10B3FC1BABB4280088592B /* Project object */; 497 | } 498 | --------------------------------------------------------------------------------