├── README.md ├── YBRouterAndDecouplingDemo ├── Assets.xcassets │ ├── Contents.json │ └── AppIcon.appiconset │ │ └── Contents.json ├── 非完全解耦 │ ├── Mediator │ │ ├── AMediator.m │ │ └── AMediator.h │ ├── AController.h │ ├── AAim │ │ ├── AMediator+AAim.h │ │ ├── AAimController.h │ │ ├── AAimController.m │ │ └── AMediator+AAim.m │ └── AController.m ├── PrefixHeader.pch ├── Block解耦 │ ├── DController.h │ ├── DAim (模块独立repo) │ │ ├── DAimRegister.h │ │ ├── DAimController.h │ │ ├── DAimController.m │ │ └── DAimRegister.m │ ├── DMediator+DAim (独立repo) │ │ ├── DMediator+DAim.h │ │ └── DMediator+DAim.m │ ├── Mediator (基础库独立repo) │ │ ├── DMediator.h │ │ └── DMediator.m │ └── DController.m ├── Protocol解耦 │ ├── CController.h │ ├── CAim (模块独立repo) │ │ ├── CAimServiceProvider.h │ │ ├── CAimController.h │ │ ├── CAimController.m │ │ └── CAimServiceProvider.m │ ├── CAimService (独立repo) │ │ └── CAimService.h │ ├── Mediator (基础库独立repo) │ │ ├── CMediator.h │ │ └── CMediator.m │ └── CController.m ├── RootController.h ├── Runtime解耦 │ ├── BController.h │ ├── BAim (模块独立repo) │ │ ├── BAimTarget.h │ │ ├── BAimController.h │ │ ├── BAimTarget.m │ │ └── BAimController.m │ ├── BMediator+BAim (独立repo) │ │ ├── BMediator+BAim.h │ │ └── BMediator+BAim.m │ ├── Mediator (基础库独立repo) │ │ ├── BMediator.h │ │ └── BMediator.m │ └── BController.m ├── 弱符号解耦 │ ├── EController.h │ ├── Mediator (基础库独立repo) │ │ ├── EMediator.h │ │ └── EMediator.m │ ├── EAim (模块独立repo) │ │ ├── EAimRouter.h │ │ ├── EAimController.h │ │ ├── EAimRouter.m │ │ └── EAimController.m │ ├── EAimMediator (独立repo) │ │ └── EAimMediator.h │ └── EController.m ├── AppDelegate.h ├── main.m ├── Tool │ ├── UIViewController+UI.h │ └── UIViewController+UI.m ├── Info.plist ├── Base.lproj │ ├── Main.storyboard │ └── LaunchScreen.storyboard ├── AppDelegate.m └── RootController.mm ├── YBRouterAndDecouplingDemo.xcodeproj ├── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ │ └── IDEWorkspaceChecks.plist ├── xcshareddata │ └── xcschemes │ │ └── YBRouterAndDecouplingDemo.xcscheme └── project.pbxproj ├── LICENSE └── .gitignore /README.md: -------------------------------------------------------------------------------- 1 | # YBRouterAndDecouplingDemo 2 | iOS 路由和解耦方案 Demo 3 | 4 | 博客:[解读 iOS 组件化与路由的本质](https://www.jianshu.com/p/40060fa2a564) 5 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/非完全解耦/Mediator/AMediator.m: -------------------------------------------------------------------------------- 1 | // 2 | // AMediator.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "AMediator.h" 10 | 11 | @implementation AMediator 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/PrefixHeader.pch: -------------------------------------------------------------------------------- 1 | // 2 | // PrefixHeader 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #ifndef PrefixHeader_pch 10 | #define PrefixHeader_pch 11 | 12 | #import "UIViewController+UI.h" 13 | 14 | #endif /* PrefixHeader_pch */ 15 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/非完全解耦/Mediator/AMediator.h: -------------------------------------------------------------------------------- 1 | // 2 | // AMediator.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface AMediator : NSObject 14 | 15 | @end 16 | 17 | NS_ASSUME_NONNULL_END 18 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/非完全解耦/AController.h: -------------------------------------------------------------------------------- 1 | // 2 | // AController.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface AController : UIViewController 14 | 15 | @end 16 | 17 | NS_ASSUME_NONNULL_END 18 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Block解耦/DController.h: -------------------------------------------------------------------------------- 1 | // 2 | // DController.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface DController : UIViewController 14 | 15 | @end 16 | 17 | NS_ASSUME_NONNULL_END 18 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Protocol解耦/CController.h: -------------------------------------------------------------------------------- 1 | // 2 | // CController.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface CController : UIViewController 14 | 15 | @end 16 | 17 | NS_ASSUME_NONNULL_END 18 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/RootController.h: -------------------------------------------------------------------------------- 1 | // 2 | // RootController.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface RootController : UIViewController 14 | 15 | @end 16 | 17 | NS_ASSUME_NONNULL_END 18 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Runtime解耦/BController.h: -------------------------------------------------------------------------------- 1 | // 2 | // BController.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface BController : UIViewController 14 | 15 | @end 16 | 17 | NS_ASSUME_NONNULL_END 18 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/弱符号解耦/EController.h: -------------------------------------------------------------------------------- 1 | // 2 | // EController.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 波儿菜 on 2019/11/17. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface EController : UIViewController 14 | 15 | @end 16 | 17 | NS_ASSUME_NONNULL_END 18 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/AppDelegate.h: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface AppDelegate : UIResponder 12 | 13 | @property (strong, nonatomic) UIWindow *window; 14 | 15 | 16 | @end 17 | 18 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Block解耦/DAim (模块独立repo)/DAimRegister.h: -------------------------------------------------------------------------------- 1 | // 2 | // DAimRegister.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface DAimRegister : NSObject 14 | 15 | @end 16 | 17 | NS_ASSUME_NONNULL_END 18 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/main.m: -------------------------------------------------------------------------------- 1 | // 2 | // main.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. 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 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Runtime解耦/BAim (模块独立repo)/BAimTarget.h: -------------------------------------------------------------------------------- 1 | // 2 | // BAimTarget.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface BAimTarget : NSObject 14 | 15 | - (void)gotoBAimController:(NSDictionary *)params; 16 | 17 | @end 18 | 19 | NS_ASSUME_NONNULL_END 20 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Protocol解耦/CAim (模块独立repo)/CAimServiceProvider.h: -------------------------------------------------------------------------------- 1 | // 2 | // CAimServiceProvider.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "CAimService.h" 11 | 12 | NS_ASSUME_NONNULL_BEGIN 13 | 14 | @interface CAimServiceProvider : NSObject 15 | 16 | @end 17 | 18 | NS_ASSUME_NONNULL_END 19 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/非完全解耦/AAim/AMediator+AAim.h: -------------------------------------------------------------------------------- 1 | // 2 | // AMediator+AAim.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "AMediator.h" 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface AMediator (AAim) 14 | 15 | + (void)gotoAAimControllerWithName:(NSString *)name callBack:(void(^)(void))callBack; 16 | 17 | @end 18 | 19 | NS_ASSUME_NONNULL_END 20 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/弱符号解耦/Mediator (基础库独立repo)/EMediator.h: -------------------------------------------------------------------------------- 1 | // 2 | // EMediator.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 波儿菜 on 2019/11/17. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | extern void ERouterNotFound(id params, ...) NS_REQUIRES_NIL_TERMINATION; 14 | 15 | @interface EMediator : NSObject 16 | 17 | @end 18 | 19 | NS_ASSUME_NONNULL_END 20 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/弱符号解耦/EAim (模块独立repo)/EAimRouter.h: -------------------------------------------------------------------------------- 1 | // 2 | // EAimRouter.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 波儿菜 on 2019/11/17. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | // 这句代码建议不用加,内部调用如需要使用这个方法导入 EAimMediator 使用比较好,减少维护成本。 14 | //extern void ERouterGotoEAimController(NSString *name, void(^callBack)(void)); 15 | 16 | NS_ASSUME_NONNULL_END 17 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Block解耦/DMediator+DAim (独立repo)/DMediator+DAim.h: -------------------------------------------------------------------------------- 1 | // 2 | // DMediator+DAim.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "DMediator.h" 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface DMediator (DAim) 14 | 15 | - (void)gotoDAimControllerWithName:(NSString *)name callBack:(void (^)(void))callBack; 16 | 17 | @end 18 | 19 | NS_ASSUME_NONNULL_END 20 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Runtime解耦/BMediator+BAim (独立repo)/BMediator+BAim.h: -------------------------------------------------------------------------------- 1 | // 2 | // BMediator+BAim.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "BMediator.h" 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface BMediator (BAim) 14 | 15 | - (void)gotoBAimControllerWithName:(NSString *)name callBack:(void(^)(void))callBack; 16 | 17 | @end 18 | 19 | NS_ASSUME_NONNULL_END 20 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Protocol解耦/CAimService (独立repo)/CAimService.h: -------------------------------------------------------------------------------- 1 | // 2 | // CAimService.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @protocol CAimService 14 | 15 | - (void)gotoCAimControllerWithName:(NSString *)name callBack:(void (^)(void))callBack; 16 | 17 | @end 18 | 19 | NS_ASSUME_NONNULL_END 20 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/非完全解耦/AAim/AAimController.h: -------------------------------------------------------------------------------- 1 | // 2 | // AAimController.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface AAimController : UIViewController 14 | 15 | @property (nonatomic, copy) NSString *name; 16 | @property (nonatomic, copy) void(^callBack)(void); 17 | 18 | @end 19 | 20 | NS_ASSUME_NONNULL_END 21 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Block解耦/DAim (模块独立repo)/DAimController.h: -------------------------------------------------------------------------------- 1 | // 2 | // DAimController.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface DAimController : UIViewController 14 | 15 | @property (nonatomic, copy) NSString *name; 16 | @property (nonatomic, copy) void(^callBack)(void); 17 | 18 | @end 19 | 20 | NS_ASSUME_NONNULL_END 21 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Runtime解耦/BAim (模块独立repo)/BAimController.h: -------------------------------------------------------------------------------- 1 | // 2 | // BAimController.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface BAimController : UIViewController 14 | 15 | @property (nonatomic, copy) NSString *name; 16 | @property (nonatomic, copy) void(^callBack)(void); 17 | 18 | @end 19 | 20 | NS_ASSUME_NONNULL_END 21 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/弱符号解耦/EAim (模块独立repo)/EAimController.h: -------------------------------------------------------------------------------- 1 | // 2 | // EAimController.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 波儿菜 on 2019/11/17. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface EAimController : UIViewController 14 | 15 | @property (nonatomic, copy) NSString *name; 16 | @property (nonatomic, copy) void(^callBack)(void); 17 | 18 | @end 19 | 20 | NS_ASSUME_NONNULL_END 21 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Protocol解耦/CAim (模块独立repo)/CAimController.h: -------------------------------------------------------------------------------- 1 | // 2 | // CAimController.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface CAimController : UIViewController 14 | 15 | @property (nonatomic, copy) NSString *name; 16 | @property (nonatomic, copy) void(^callBack)(void); 17 | 18 | @end 19 | 20 | NS_ASSUME_NONNULL_END 21 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Tool/UIViewController+UI.h: -------------------------------------------------------------------------------- 1 | // 2 | // UIViewController+UI.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | UINavigationController *YBTopNavigationController(void); 14 | 15 | @interface UIViewController (UI) 16 | 17 | /** 获取顶层的 UIViewController 实例 */ 18 | + (UIViewController *)yb_top; 19 | 20 | @end 21 | 22 | NS_ASSUME_NONNULL_END 23 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/弱符号解耦/EAimMediator (独立repo)/EAimMediator.h: -------------------------------------------------------------------------------- 1 | // 2 | // EAimMediator.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 波儿菜 on 2019/11/17. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #ifndef EAimMediator_h 10 | #define EAimMediator_h 11 | #import "EMediator.h" 12 | 13 | 14 | __attribute__ ((weak)) void ERouterGotoEAimController(NSString *name, void(^callBack)(void)) { 15 | ERouterNotFound(name, callBack, nil); 16 | } 17 | 18 | 19 | #endif /* EAimMediator_h */ 20 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Block解耦/DMediator+DAim (独立repo)/DMediator+DAim.m: -------------------------------------------------------------------------------- 1 | // 2 | // DMediator+DAim.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "DMediator+DAim.h" 10 | 11 | @implementation DMediator (DAim) 12 | 13 | - (void)gotoDAimControllerWithName:(NSString *)name callBack:(void (^)(void))callBack { 14 | [self excuteBlockWithKey:@"gotoDAimKey" params:@{@"name":name, @"callBack":callBack}]; 15 | } 16 | 17 | @end 18 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Runtime解耦/Mediator (基础库独立repo)/BMediator.h: -------------------------------------------------------------------------------- 1 | // 2 | // BMediator.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface BMediator : NSObject 14 | 15 | + (instancetype)share; 16 | 17 | - (id)performTarget:(NSString *)target action:(NSString *)action params:(NSDictionary *)params; 18 | 19 | @end 20 | 21 | NS_ASSUME_NONNULL_END 22 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/弱符号解耦/EAim (模块独立repo)/EAimRouter.m: -------------------------------------------------------------------------------- 1 | // 2 | // EAimRouter.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 波儿菜 on 2019/11/17. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "EAimRouter.h" 10 | #import "EAimController.h" 11 | 12 | void ERouterGotoEAimController(NSString *name, void(^callBack)(void)) { 13 | EAimController *vc = [EAimController new]; 14 | vc.name = name; 15 | vc.callBack = callBack; 16 | [UIViewController.yb_top.navigationController pushViewController:vc animated:YES]; 17 | } 18 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Protocol解耦/Mediator (基础库独立repo)/CMediator.h: -------------------------------------------------------------------------------- 1 | // 2 | // CMediator.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface CMediator : NSObject 14 | 15 | + (instancetype)share; 16 | 17 | /// 注册 Protocol : Class 18 | - (void)registerService:(Protocol *)service class:(Class)cls; 19 | 20 | /// 通过 Protocol 读取 [Class new] 21 | - (id)getObject:(Protocol *)service; 22 | 23 | @end 24 | 25 | NS_ASSUME_NONNULL_END 26 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/非完全解耦/AAim/AAimController.m: -------------------------------------------------------------------------------- 1 | // 2 | // AAimController.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "AAimController.h" 10 | 11 | @interface AAimController () 12 | 13 | @end 14 | 15 | @implementation AAimController 16 | 17 | - (void)viewDidLoad { 18 | [super viewDidLoad]; 19 | self.view.backgroundColor = UIColor.whiteColor; 20 | 21 | self.navigationItem.title = self.name; 22 | if (self.callBack) { 23 | self.callBack(); 24 | } 25 | } 26 | 27 | @end 28 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Block解耦/DAim (模块独立repo)/DAimController.m: -------------------------------------------------------------------------------- 1 | // 2 | // DAimController.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "DAimController.h" 10 | 11 | @interface DAimController () 12 | 13 | @end 14 | 15 | @implementation DAimController 16 | 17 | - (void)viewDidLoad { 18 | [super viewDidLoad]; 19 | self.view.backgroundColor = UIColor.whiteColor; 20 | 21 | self.navigationItem.title = self.name; 22 | if (self.callBack) { 23 | self.callBack(); 24 | } 25 | } 26 | 27 | @end 28 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Runtime解耦/BAim (模块独立repo)/BAimTarget.m: -------------------------------------------------------------------------------- 1 | // 2 | // BAimTarget.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "BAimTarget.h" 10 | #import "BAimController.h" 11 | 12 | @implementation BAimTarget 13 | 14 | - (void)gotoBAimController:(NSDictionary *)params { 15 | BAimController *vc = [BAimController new]; 16 | vc.name = params[@"name"]; 17 | vc.callBack = params[@"callBack"]; 18 | [UIViewController.yb_top.navigationController pushViewController:vc animated:YES]; 19 | } 20 | 21 | @end 22 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/弱符号解耦/EAim (模块独立repo)/EAimController.m: -------------------------------------------------------------------------------- 1 | // 2 | // EAimController.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 波儿菜 on 2019/11/17. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "EAimController.h" 10 | 11 | @interface EAimController () 12 | 13 | @end 14 | 15 | @implementation EAimController 16 | 17 | - (void)viewDidLoad { 18 | [super viewDidLoad]; 19 | self.view.backgroundColor = UIColor.whiteColor; 20 | 21 | self.navigationItem.title = self.name; 22 | if (self.callBack) { 23 | self.callBack(); 24 | } 25 | } 26 | 27 | @end 28 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Protocol解耦/CAim (模块独立repo)/CAimController.m: -------------------------------------------------------------------------------- 1 | // 2 | // CAimController.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "CAimController.h" 10 | 11 | @interface CAimController () 12 | 13 | @end 14 | 15 | @implementation CAimController 16 | 17 | - (void)viewDidLoad { 18 | [super viewDidLoad]; 19 | self.view.backgroundColor = UIColor.whiteColor; 20 | 21 | self.navigationItem.title = self.name; 22 | if (self.callBack) { 23 | self.callBack(); 24 | } 25 | } 26 | 27 | @end 28 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Runtime解耦/BAim (模块独立repo)/BAimController.m: -------------------------------------------------------------------------------- 1 | // 2 | // BAimController.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "BAimController.h" 10 | 11 | @interface BAimController () 12 | 13 | @end 14 | 15 | @implementation BAimController 16 | 17 | - (void)viewDidLoad { 18 | [super viewDidLoad]; 19 | self.view.backgroundColor = UIColor.whiteColor; 20 | 21 | self.navigationItem.title = self.name; 22 | if (self.callBack) { 23 | self.callBack(); 24 | } 25 | } 26 | 27 | @end 28 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/非完全解耦/AAim/AMediator+AAim.m: -------------------------------------------------------------------------------- 1 | // 2 | // AMediator+AAim.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "AMediator+AAim.h" 10 | #import "AAimController.h" 11 | 12 | @implementation AMediator (AAim) 13 | 14 | + (void)gotoAAimControllerWithName:(NSString *)name callBack:(void (^)(void))callBack { 15 | AAimController *vc = [AAimController new]; 16 | vc.name = name; 17 | vc.callBack = callBack; 18 | [YBTopNavigationController() pushViewController:vc animated:YES]; 19 | } 20 | 21 | @end 22 | 23 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/弱符号解耦/EController.m: -------------------------------------------------------------------------------- 1 | // 2 | // EController.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 波儿菜 on 2019/11/17. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "EController.h" 10 | #import "EAimMediator.h" 11 | 12 | @interface EController () 13 | 14 | @end 15 | 16 | @implementation EController 17 | 18 | - (void)viewDidLoad { 19 | [super viewDidLoad]; 20 | } 21 | 22 | - (void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event { 23 | 24 | ERouterGotoEAimController(@"From E", ^{ 25 | NSLog(@"EAim 回调"); 26 | }); 27 | } 28 | 29 | @end 30 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Runtime解耦/BMediator+BAim (独立repo)/BMediator+BAim.m: -------------------------------------------------------------------------------- 1 | // 2 | // BMediator+BAim.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "BMediator+BAim.h" 10 | 11 | static NSString * const kTarget = @"BAimTarget"; 12 | static NSString * const kAction = @"gotoBAimController:"; 13 | 14 | @implementation BMediator (BAim) 15 | 16 | - (void)gotoBAimControllerWithName:(NSString *)name callBack:(void (^)(void))callBack { 17 | [self performTarget:kTarget action:kAction params:@{@"name":name, @"callBack":callBack}]; 18 | } 19 | 20 | @end 21 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/非完全解耦/AController.m: -------------------------------------------------------------------------------- 1 | // 2 | // AController.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "AController.h" 10 | #import "AMediator+AAim.h" 11 | 12 | @interface AController () 13 | 14 | @end 15 | 16 | @implementation AController 17 | 18 | - (void)viewDidLoad { 19 | [super viewDidLoad]; 20 | } 21 | 22 | - (void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event { 23 | [AMediator gotoAAimControllerWithName:@"From A" callBack:^{ 24 | NSLog(@"AAim CallBack"); 25 | }]; 26 | } 27 | 28 | @end 29 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Block解耦/Mediator (基础库独立repo)/DMediator.h: -------------------------------------------------------------------------------- 1 | // 2 | // DMediator.h 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | @interface DMediator : NSObject 14 | 15 | + (instancetype)share; 16 | 17 | /// 注册 key : block 18 | - (void)registerKey:(NSString *)key block:(id _Nullable (^)(NSDictionary * _Nullable params))block; 19 | 20 | /// 通过 key 执行 block 21 | - (nullable id)excuteBlockWithKey:(NSString *)key params:(NSDictionary *)params; 22 | 23 | @end 24 | 25 | NS_ASSUME_NONNULL_END 26 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/弱符号解耦/Mediator (基础库独立repo)/EMediator.m: -------------------------------------------------------------------------------- 1 | // 2 | // EMediator.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 波儿菜 on 2019/11/17. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "EMediator.h" 10 | 11 | // 在这里做统一的路由失败处理 12 | void ERouterNotFound(id params, ...) { 13 | if (params) { 14 | va_list argList; 15 | va_start(argList, params); 16 | id arg = params; 17 | do { 18 | NSLog(@"cur arg: %@", arg); 19 | } while ((arg = va_arg(argList, id))); 20 | va_end(argList); 21 | } 22 | NSLog(@"router not found"); 23 | } 24 | 25 | @implementation EMediator 26 | 27 | @end 28 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Block解耦/DAim (模块独立repo)/DAimRegister.m: -------------------------------------------------------------------------------- 1 | // 2 | // DAimRegister.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "DAimRegister.h" 10 | #import "DMediator.h" 11 | #import "DAimController.h" 12 | 13 | @implementation DAimRegister 14 | 15 | + (void)load { 16 | [DMediator.share registerKey:@"gotoDAimKey" block:^id _Nullable(NSDictionary * _Nullable params) { 17 | DAimController *vc = [DAimController new]; 18 | vc.name = params[@"name"]; 19 | vc.callBack = params[@"callBack"]; 20 | [UIViewController.yb_top.navigationController pushViewController:vc animated:YES]; 21 | return nil; 22 | }]; 23 | } 24 | 25 | @end 26 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Protocol解耦/CController.m: -------------------------------------------------------------------------------- 1 | // 2 | // CController.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "CController.h" 10 | #import "CMediator.h" 11 | #import "CAimService.h" 12 | 13 | @interface CController () 14 | 15 | @end 16 | 17 | @implementation CController 18 | 19 | - (void)viewDidLoad { 20 | [super viewDidLoad]; 21 | } 22 | 23 | - (void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event { 24 | 25 | id service = [CMediator.share getObject:@protocol(CAimService)]; 26 | [service gotoCAimControllerWithName:@"From C" callBack:^{ 27 | NSLog(@"CAim CallBack"); 28 | }]; 29 | 30 | } 31 | 32 | @end 33 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Protocol解耦/CAim (模块独立repo)/CAimServiceProvider.m: -------------------------------------------------------------------------------- 1 | // 2 | // CAimServiceProvider.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "CAimServiceProvider.h" 10 | #import "CMediator.h" 11 | #import "CAimController.h" 12 | 13 | @implementation CAimServiceProvider 14 | 15 | + (void)load { 16 | [CMediator.share registerService:@protocol(CAimService) class:self]; 17 | } 18 | 19 | #pragma mark - 20 | 21 | - (void)gotoCAimControllerWithName:(NSString *)name callBack:(void (^)(void))callBack { 22 | CAimController *vc = [CAimController new]; 23 | vc.name = name; 24 | vc.callBack = callBack; 25 | [UIViewController.yb_top.navigationController pushViewController:vc animated:YES]; 26 | } 27 | 28 | @end 29 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Block解耦/DController.m: -------------------------------------------------------------------------------- 1 | // 2 | // DController.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "DController.h" 10 | #import "DMediator+DAim.h" 11 | 12 | @interface DController () 13 | 14 | @end 15 | 16 | @implementation DController 17 | 18 | - (void)viewDidLoad { 19 | [super viewDidLoad]; 20 | } 21 | 22 | - (void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event { 23 | 24 | [DMediator.share gotoDAimControllerWithName:@"From D" callBack:^{ 25 | NSLog(@"DAim 回调"); 26 | }]; 27 | 28 | /* 29 | // 不使用语法糖 30 | [DMediator.share excuteBlockWithKey:@"gotoDAimKey" params:@{@"name":@"From D", @"callBack":^{ 31 | NSLog(@"DAim 回调"); 32 | }}]; 33 | */ 34 | } 35 | 36 | @end 37 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Runtime解耦/BController.m: -------------------------------------------------------------------------------- 1 | // 2 | // BController.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "BController.h" 10 | #import "BMediator+BAim.h" 11 | 12 | @interface BController () 13 | 14 | @end 15 | 16 | @implementation BController 17 | 18 | - (void)viewDidLoad { 19 | [super viewDidLoad]; 20 | } 21 | 22 | - (void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event { 23 | 24 | [BMediator.share gotoBAimControllerWithName:@"From B" callBack:^{ 25 | NSLog(@"BAim 回调"); 26 | }]; 27 | 28 | /* 29 | // 不使用语法糖 30 | [BMediator.share performTarget:@"BTarget" action:@"gotoBAimController:" params:@{@"name":@"From B", @"callBack":^{ 31 | NSLog(@"BAim 回调"); 32 | }}]; 33 | */ 34 | } 35 | 36 | @end 37 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2019 杨波 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 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Block解耦/Mediator (基础库独立repo)/DMediator.m: -------------------------------------------------------------------------------- 1 | // 2 | // DMediator.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "DMediator.h" 10 | 11 | @interface DMediator () 12 | @property (nonatomic, strong) NSMutableDictionary *map; 13 | @end 14 | 15 | @implementation DMediator 16 | 17 | + (instancetype)share { 18 | static DMediator *mediator = nil; 19 | static dispatch_once_t onceToken; 20 | dispatch_once(&onceToken, ^{ 21 | mediator = [DMediator new]; 22 | mediator.map = [NSMutableDictionary new]; 23 | }); 24 | return mediator; 25 | } 26 | 27 | - (void)registerKey:(NSString *)key block:(nonnull id _Nullable (^)(NSDictionary * _Nullable))block { 28 | if (!key || !block) return; 29 | self.map[key] = block; 30 | } 31 | 32 | /// 此方法就是一个拦截器,可做容错以及动态调度 33 | - (id)excuteBlockWithKey:(NSString *)key params:(NSDictionary *)params { 34 | if (!key) return nil; 35 | id(^block)(NSDictionary *) = self.map[key]; 36 | if (!block) return nil; 37 | return block(params); 38 | } 39 | 40 | @end 41 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Protocol解耦/Mediator (基础库独立repo)/CMediator.m: -------------------------------------------------------------------------------- 1 | // 2 | // CMediator.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "CMediator.h" 10 | 11 | @interface CMediator () 12 | @property (nonatomic, strong) NSMutableDictionary *map; 13 | @end 14 | 15 | @implementation CMediator 16 | 17 | + (instancetype)share { 18 | static CMediator *mediator = nil; 19 | static dispatch_once_t onceToken; 20 | dispatch_once(&onceToken, ^{ 21 | mediator = [CMediator new]; 22 | mediator.map = [NSMutableDictionary new]; 23 | }); 24 | return mediator; 25 | } 26 | 27 | - (void)registerService:(Protocol *)service class:(Class)cls { 28 | if (!service || !cls) return; 29 | self.map[NSStringFromProtocol(service)] = cls; 30 | } 31 | 32 | - (id)getObject:(Protocol *)service { 33 | if (!service) return nil; 34 | Class cls = self.map[NSStringFromProtocol(service)]; 35 | id obj = [cls new]; 36 | if ([obj conformsToProtocol:service]) { 37 | return obj; 38 | } 39 | return nil; 40 | } 41 | 42 | @end 43 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Runtime解耦/Mediator (基础库独立repo)/BMediator.m: -------------------------------------------------------------------------------- 1 | // 2 | // BMediator.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "BMediator.h" 10 | 11 | @implementation BMediator 12 | 13 | + (instancetype)share { 14 | static BMediator *mediator = nil; 15 | static dispatch_once_t onceToken; 16 | dispatch_once(&onceToken, ^{ 17 | mediator = [BMediator new]; 18 | }); 19 | return mediator; 20 | } 21 | 22 | /// 此方法就是一个拦截器,可做容错以及动态调度 23 | - (id)performTarget:(NSString *)target action:(NSString *)action params:(NSDictionary *)params { 24 | 25 | Class cls; id obj; SEL sel; 26 | 27 | cls = NSClassFromString(target); 28 | if (!cls) goto fail; 29 | sel = NSSelectorFromString(action); 30 | if (!sel) goto fail; 31 | obj = [cls new]; 32 | if (![obj respondsToSelector:sel]) goto fail; 33 | 34 | #pragma clang diagnostic push 35 | #pragma clang diagnostic ignored "-Warc-performSelector-leaks" 36 | return [obj performSelector:sel withObject:params]; 37 | #pragma clang diagnostic pop 38 | 39 | fail: 40 | NSLog(@"找不到目标,写容错逻辑"); 41 | return nil; 42 | } 43 | 44 | @end 45 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1 21 | LSRequiresIPhoneOS 22 | 23 | UILaunchStoryboardName 24 | LaunchScreen 25 | UIMainStoryboardFile 26 | 27 | UIRequiredDeviceCapabilities 28 | 29 | armv7 30 | 31 | UISupportedInterfaceOrientations 32 | 33 | UIInterfaceOrientationPortrait 34 | UIInterfaceOrientationLandscapeLeft 35 | UIInterfaceOrientationLandscapeRight 36 | 37 | UISupportedInterfaceOrientations~ipad 38 | 39 | UIInterfaceOrientationPortrait 40 | UIInterfaceOrientationPortraitUpsideDown 41 | UIInterfaceOrientationLandscapeLeft 42 | UIInterfaceOrientationLandscapeRight 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Xcode 2 | # 3 | # gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore 4 | 5 | ## Build generated 6 | build/ 7 | DerivedData/ 8 | 9 | ## Various settings 10 | *.pbxuser 11 | !default.pbxuser 12 | *.mode1v3 13 | !default.mode1v3 14 | *.mode2v3 15 | !default.mode2v3 16 | *.perspectivev3 17 | !default.perspectivev3 18 | xcuserdata/ 19 | 20 | ## Other 21 | *.moved-aside 22 | *.xccheckout 23 | *.xcscmblueprint 24 | 25 | ## Obj-C/Swift specific 26 | *.hmap 27 | *.ipa 28 | *.dSYM.zip 29 | *.dSYM 30 | 31 | # CocoaPods 32 | # 33 | # We recommend against adding the Pods directory to your .gitignore. However 34 | # you should judge for yourself, the pros and cons are mentioned at: 35 | # https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control 36 | # 37 | # Pods/ 38 | 39 | # Carthage 40 | # 41 | # Add this line if you want to avoid checking in source code from Carthage dependencies. 42 | # Carthage/Checkouts 43 | 44 | Carthage/Build 45 | 46 | # fastlane 47 | # 48 | # It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the 49 | # screenshots whenever they are needed. 50 | # For more information about the recommended setup visit: 51 | # https://docs.fastlane.tools/best-practices/source-control/#source-control 52 | 53 | fastlane/report.xml 54 | fastlane/Preview.html 55 | fastlane/screenshots/**/*.png 56 | fastlane/test_output 57 | 58 | # Code Injection 59 | # 60 | # After new code Injection tools there's a generated folder /iOSInjectionProject 61 | # https://github.com/johnno1962/injectionforxcode 62 | 63 | iOSInjectionProject/ 64 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/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 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Base.lproj/LaunchScreen.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 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "size" : "20x20", 6 | "scale" : "2x" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "size" : "20x20", 11 | "scale" : "3x" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "size" : "29x29", 16 | "scale" : "2x" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "size" : "29x29", 21 | "scale" : "3x" 22 | }, 23 | { 24 | "idiom" : "iphone", 25 | "size" : "40x40", 26 | "scale" : "2x" 27 | }, 28 | { 29 | "idiom" : "iphone", 30 | "size" : "40x40", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "idiom" : "iphone", 35 | "size" : "60x60", 36 | "scale" : "2x" 37 | }, 38 | { 39 | "idiom" : "iphone", 40 | "size" : "60x60", 41 | "scale" : "3x" 42 | }, 43 | { 44 | "idiom" : "ipad", 45 | "size" : "20x20", 46 | "scale" : "1x" 47 | }, 48 | { 49 | "idiom" : "ipad", 50 | "size" : "20x20", 51 | "scale" : "2x" 52 | }, 53 | { 54 | "idiom" : "ipad", 55 | "size" : "29x29", 56 | "scale" : "1x" 57 | }, 58 | { 59 | "idiom" : "ipad", 60 | "size" : "29x29", 61 | "scale" : "2x" 62 | }, 63 | { 64 | "idiom" : "ipad", 65 | "size" : "40x40", 66 | "scale" : "1x" 67 | }, 68 | { 69 | "idiom" : "ipad", 70 | "size" : "40x40", 71 | "scale" : "2x" 72 | }, 73 | { 74 | "idiom" : "ipad", 75 | "size" : "76x76", 76 | "scale" : "1x" 77 | }, 78 | { 79 | "idiom" : "ipad", 80 | "size" : "76x76", 81 | "scale" : "2x" 82 | }, 83 | { 84 | "idiom" : "ipad", 85 | "size" : "83.5x83.5", 86 | "scale" : "2x" 87 | }, 88 | { 89 | "idiom" : "ios-marketing", 90 | "size" : "1024x1024", 91 | "scale" : "1x" 92 | } 93 | ], 94 | "info" : { 95 | "version" : 1, 96 | "author" : "xcode" 97 | } 98 | } -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/Tool/UIViewController+UI.m: -------------------------------------------------------------------------------- 1 | // 2 | // UIViewController+UI.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "UIViewController+UI.h" 10 | 11 | UINavigationController *YBTopNavigationController(void) { 12 | return UIViewController.yb_top.navigationController; 13 | } 14 | 15 | @implementation UIViewController (UI) 16 | 17 | + (UIWindow *)yb_normalWindow { 18 | UIWindow *window = [[UIApplication sharedApplication] keyWindow]; 19 | if (window.windowLevel != UIWindowLevelNormal) { 20 | NSArray *windows = [[UIApplication sharedApplication] windows]; 21 | for (UIWindow *temp in windows) { 22 | if (temp.windowLevel == UIWindowLevelNormal) { 23 | window = temp; 24 | break; 25 | } 26 | } 27 | } 28 | return window; 29 | } 30 | 31 | + (UIViewController *)yb_top { 32 | 33 | UIViewController *topController = nil; 34 | UIWindow *window = [self yb_normalWindow]; 35 | UIView *frontView = [[window subviews] objectAtIndex:0]; 36 | id nextResponder = [frontView nextResponder]; 37 | if ([nextResponder isKindOfClass:UIViewController.class]) { 38 | topController = nextResponder; 39 | } else { 40 | topController = window.rootViewController; 41 | } 42 | 43 | while ([topController isKindOfClass:UITabBarController.class] || [topController isKindOfClass:UINavigationController.class]) { 44 | if ([topController isKindOfClass:UITabBarController.class]) { 45 | topController = ((UITabBarController *)topController).selectedViewController; 46 | } else if ([topController isKindOfClass:UINavigationController.class]) { 47 | topController = ((UINavigationController *)topController).topViewController; 48 | } 49 | } 50 | 51 | while (topController.presentedViewController) { 52 | topController = topController.presentedViewController; 53 | } 54 | 55 | return topController; 56 | } 57 | 58 | @end 59 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/AppDelegate.m: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "AppDelegate.h" 10 | #import "RootController.h" 11 | 12 | @interface AppDelegate () 13 | 14 | @end 15 | 16 | @implementation AppDelegate 17 | 18 | 19 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { 20 | 21 | _window = [[UIWindow alloc] initWithFrame:(CGRect){CGPointZero, UIScreen.mainScreen.bounds.size}]; 22 | _window.rootViewController = [[UINavigationController alloc] initWithRootViewController:[RootController new]]; 23 | [_window makeKeyAndVisible]; 24 | 25 | return YES; 26 | } 27 | 28 | 29 | - (void)applicationWillResignActive:(UIApplication *)application { 30 | // 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. 31 | // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. 32 | } 33 | 34 | 35 | - (void)applicationDidEnterBackground:(UIApplication *)application { 36 | // 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. 37 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. 38 | } 39 | 40 | 41 | - (void)applicationWillEnterForeground:(UIApplication *)application { 42 | // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. 43 | } 44 | 45 | 46 | - (void)applicationDidBecomeActive:(UIApplication *)application { 47 | // 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. 48 | } 49 | 50 | 51 | - (void)applicationWillTerminate:(UIApplication *)application { 52 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. 53 | } 54 | 55 | 56 | @end 57 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo/RootController.mm: -------------------------------------------------------------------------------- 1 | // 2 | // RootController.m 3 | // YBRouterAndDecouplingDemo 4 | // 5 | // Created by 杨波 on 2019/5/29. 6 | // Copyright © 2019 杨波. All rights reserved. 7 | // 8 | 9 | #import "RootController.h" 10 | #import 11 | using namespace std; 12 | #import "AController.h" 13 | #import "BController.h" 14 | #import "CController.h" 15 | #import "DController.h" 16 | #import "EController.h" 17 | 18 | typedef pair RootRow; 19 | 20 | @interface RootController () 21 | @property (nonatomic, strong) UITableView *tableView; 22 | @end 23 | 24 | @implementation RootController { 25 | vector _dataSource; 26 | } 27 | 28 | #pragma mark - life cycle 29 | 30 | - (void)viewDidLoad { 31 | [super viewDidLoad]; 32 | [self prepareData]; 33 | self.view.backgroundColor = UIColor.whiteColor; 34 | [self.view addSubview:self.tableView]; 35 | } 36 | 37 | - (void)prepareData { 38 | RootRow arr[] = { 39 | RootRow(@"非完全解耦", AController.self), 40 | RootRow(@"Runtime解耦", BController.self), 41 | RootRow(@"Protocol解耦", CController.self), 42 | RootRow(@"Block解耦", DController.self), 43 | RootRow(@"弱符号解耦", EController.self) 44 | }; 45 | for (auto value : arr) { 46 | _dataSource.push_back(value); 47 | } 48 | } 49 | 50 | - (void)viewWillLayoutSubviews { 51 | [super viewWillLayoutSubviews]; 52 | self.tableView.frame = self.view.bounds; 53 | } 54 | 55 | #pragma mark - 56 | 57 | - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { 58 | return _dataSource.size(); 59 | } 60 | 61 | - (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath { 62 | return 50; 63 | } 64 | 65 | - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { 66 | NSString *identifier = NSStringFromClass(UITableViewCell.self); 67 | UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:identifier]; 68 | if (!cell) { 69 | cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleValue1 reuseIdentifier:identifier]; 70 | } 71 | cell.textLabel.text = _dataSource[indexPath.row].first; 72 | return cell; 73 | } 74 | 75 | - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { 76 | UIViewController *vc = [_dataSource[indexPath.row].second new]; 77 | vc.view.backgroundColor = UIColor.whiteColor; 78 | vc.navigationItem.title = _dataSource[indexPath.row].first; 79 | [self.navigationController pushViewController:vc animated:YES]; 80 | } 81 | 82 | #pragma mark - getter 83 | 84 | - (UITableView *)tableView { 85 | if (!_tableView) { 86 | _tableView = [[UITableView alloc] initWithFrame:CGRectZero style:UITableViewStylePlain]; 87 | _tableView.tableFooterView = [UIView new]; 88 | _tableView.delegate = self; 89 | _tableView.dataSource = self; 90 | } 91 | return _tableView; 92 | } 93 | 94 | @end 95 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo.xcodeproj/xcshareddata/xcschemes/YBRouterAndDecouplingDemo.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 39 | 40 | 41 | 42 | 43 | 44 | 54 | 56 | 62 | 63 | 64 | 65 | 69 | 70 | 71 | 72 | 73 | 74 | 80 | 82 | 88 | 89 | 90 | 91 | 93 | 94 | 97 | 98 | 99 | -------------------------------------------------------------------------------- /YBRouterAndDecouplingDemo.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 50; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 233A191B2381120E00FF9846 /* EController.m in Sources */ = {isa = PBXBuildFile; fileRef = 233A191A2381120E00FF9846 /* EController.m */; }; 11 | 233A191F238112DC00FF9846 /* EAimController.m in Sources */ = {isa = PBXBuildFile; fileRef = 233A191E238112DC00FF9846 /* EAimController.m */; }; 12 | 233A193523811BFC00FF9846 /* EAimRouter.m in Sources */ = {isa = PBXBuildFile; fileRef = 233A193423811BFC00FF9846 /* EAimRouter.m */; }; 13 | 233A19382381211100FF9846 /* EMediator.m in Sources */ = {isa = PBXBuildFile; fileRef = 233A19372381211100FF9846 /* EMediator.m */; }; 14 | 2365A1A1229E86F10027C78C /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1A0229E86F10027C78C /* AppDelegate.m */; }; 15 | 2365A1A7229E86F10027C78C /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 2365A1A5229E86F10027C78C /* Main.storyboard */; }; 16 | 2365A1A9229E86F30027C78C /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 2365A1A8229E86F30027C78C /* Assets.xcassets */; }; 17 | 2365A1AC229E86F30027C78C /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 2365A1AA229E86F30027C78C /* LaunchScreen.storyboard */; }; 18 | 2365A1AF229E86F30027C78C /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1AE229E86F30027C78C /* main.m */; }; 19 | 2365A1BD229E88F30027C78C /* AController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1BC229E88F30027C78C /* AController.m */; }; 20 | 2365A1C0229E89330027C78C /* AAimController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1BF229E89330027C78C /* AAimController.m */; }; 21 | 2365A1C3229E89520027C78C /* BController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1C2229E89520027C78C /* BController.m */; }; 22 | 2365A1C9229E89660027C78C /* CController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1C8229E89660027C78C /* CController.m */; }; 23 | 2365A1CC229E896E0027C78C /* CAimController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1CB229E896E0027C78C /* CAimController.m */; }; 24 | 2365A1CF229E89B20027C78C /* DController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1CE229E89B20027C78C /* DController.m */; }; 25 | 2365A1D2229E89BE0027C78C /* DAimController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1D1229E89BE0027C78C /* DAimController.m */; }; 26 | 2365A1D5229E8B5D0027C78C /* RootController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1D4229E8B5D0027C78C /* RootController.mm */; }; 27 | 2365A1DC229E949E0027C78C /* AMediator.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1DB229E949E0027C78C /* AMediator.m */; }; 28 | 2365A1DF229E94A80027C78C /* BMediator.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1DE229E94A80027C78C /* BMediator.m */; }; 29 | 2365A1E2229E94AF0027C78C /* CMediator.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1E1229E94AF0027C78C /* CMediator.m */; }; 30 | 2365A1E5229E94B60027C78C /* DMediator.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1E4229E94B60027C78C /* DMediator.m */; }; 31 | 2365A1E9229E97B20027C78C /* UIViewController+UI.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1E8229E97B20027C78C /* UIViewController+UI.m */; }; 32 | 2365A1F1229EB2650027C78C /* AMediator+AAim.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1F0229EB2650027C78C /* AMediator+AAim.m */; }; 33 | 2365A1F7229EB3E40027C78C /* BMediator+BAim.m in Sources */ = {isa = PBXBuildFile; fileRef = 2365A1F6229EB3E40027C78C /* BMediator+BAim.m */; }; 34 | 2394B5AC229EBF2E00310A57 /* BAimController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2394B5A8229EBF2E00310A57 /* BAimController.m */; }; 35 | 2394B5AD229EBF2E00310A57 /* BAimTarget.m in Sources */ = {isa = PBXBuildFile; fileRef = 2394B5AA229EBF2E00310A57 /* BAimTarget.m */; }; 36 | 2394B5B0229EC66C00310A57 /* DAimRegister.m in Sources */ = {isa = PBXBuildFile; fileRef = 2394B5AF229EC66C00310A57 /* DAimRegister.m */; }; 37 | 2394B5B3229EC8A400310A57 /* DMediator+DAim.m in Sources */ = {isa = PBXBuildFile; fileRef = 2394B5B2229EC8A400310A57 /* DMediator+DAim.m */; }; 38 | 2394B5B7229ED85A00310A57 /* CAimServiceProvider.m in Sources */ = {isa = PBXBuildFile; fileRef = 2394B5B6229ED85A00310A57 /* CAimServiceProvider.m */; }; 39 | /* End PBXBuildFile section */ 40 | 41 | /* Begin PBXFileReference section */ 42 | 233A19192381120E00FF9846 /* EController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = EController.h; sourceTree = ""; }; 43 | 233A191A2381120E00FF9846 /* EController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = EController.m; sourceTree = ""; }; 44 | 233A191D238112DC00FF9846 /* EAimController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = EAimController.h; sourceTree = ""; }; 45 | 233A191E238112DC00FF9846 /* EAimController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = EAimController.m; sourceTree = ""; }; 46 | 233A193123811ADF00FF9846 /* EAimMediator.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = EAimMediator.h; sourceTree = ""; }; 47 | 233A193323811BFC00FF9846 /* EAimRouter.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = EAimRouter.h; sourceTree = ""; }; 48 | 233A193423811BFC00FF9846 /* EAimRouter.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = EAimRouter.m; sourceTree = ""; }; 49 | 233A19362381211100FF9846 /* EMediator.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = EMediator.h; sourceTree = ""; }; 50 | 233A19372381211100FF9846 /* EMediator.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = EMediator.m; sourceTree = ""; }; 51 | 2365A19C229E86F10027C78C /* YBRouterAndDecouplingDemo.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = YBRouterAndDecouplingDemo.app; sourceTree = BUILT_PRODUCTS_DIR; }; 52 | 2365A19F229E86F10027C78C /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; 53 | 2365A1A0229E86F10027C78C /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; }; 54 | 2365A1A6229E86F10027C78C /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 55 | 2365A1A8229E86F30027C78C /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 56 | 2365A1AB229E86F30027C78C /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 57 | 2365A1AD229E86F30027C78C /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 58 | 2365A1AE229E86F30027C78C /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 59 | 2365A1BB229E88F30027C78C /* AController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AController.h; sourceTree = ""; }; 60 | 2365A1BC229E88F30027C78C /* AController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AController.m; sourceTree = ""; }; 61 | 2365A1BE229E89330027C78C /* AAimController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AAimController.h; sourceTree = ""; }; 62 | 2365A1BF229E89330027C78C /* AAimController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AAimController.m; sourceTree = ""; }; 63 | 2365A1C1229E89520027C78C /* BController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = BController.h; sourceTree = ""; }; 64 | 2365A1C2229E89520027C78C /* BController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = BController.m; sourceTree = ""; }; 65 | 2365A1C7229E89660027C78C /* CController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CController.h; sourceTree = ""; }; 66 | 2365A1C8229E89660027C78C /* CController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = CController.m; sourceTree = ""; }; 67 | 2365A1CA229E896E0027C78C /* CAimController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CAimController.h; sourceTree = ""; }; 68 | 2365A1CB229E896E0027C78C /* CAimController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = CAimController.m; sourceTree = ""; }; 69 | 2365A1CD229E89B20027C78C /* DController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DController.h; sourceTree = ""; }; 70 | 2365A1CE229E89B20027C78C /* DController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = DController.m; sourceTree = ""; }; 71 | 2365A1D0229E89BE0027C78C /* DAimController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DAimController.h; sourceTree = ""; }; 72 | 2365A1D1229E89BE0027C78C /* DAimController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = DAimController.m; sourceTree = ""; }; 73 | 2365A1D3229E8B5C0027C78C /* RootController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RootController.h; sourceTree = ""; }; 74 | 2365A1D4229E8B5D0027C78C /* RootController.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = RootController.mm; sourceTree = ""; }; 75 | 2365A1DA229E949E0027C78C /* AMediator.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AMediator.h; sourceTree = ""; }; 76 | 2365A1DB229E949E0027C78C /* AMediator.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AMediator.m; sourceTree = ""; }; 77 | 2365A1DD229E94A80027C78C /* BMediator.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = BMediator.h; sourceTree = ""; }; 78 | 2365A1DE229E94A80027C78C /* BMediator.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = BMediator.m; sourceTree = ""; }; 79 | 2365A1E0229E94AF0027C78C /* CMediator.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CMediator.h; sourceTree = ""; }; 80 | 2365A1E1229E94AF0027C78C /* CMediator.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = CMediator.m; sourceTree = ""; }; 81 | 2365A1E3229E94B60027C78C /* DMediator.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DMediator.h; sourceTree = ""; }; 82 | 2365A1E4229E94B60027C78C /* DMediator.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = DMediator.m; sourceTree = ""; }; 83 | 2365A1E7229E97B20027C78C /* UIViewController+UI.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIViewController+UI.h"; sourceTree = ""; }; 84 | 2365A1E8229E97B20027C78C /* UIViewController+UI.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIViewController+UI.m"; sourceTree = ""; }; 85 | 2365A1EF229EB2650027C78C /* AMediator+AAim.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "AMediator+AAim.h"; sourceTree = ""; }; 86 | 2365A1F0229EB2650027C78C /* AMediator+AAim.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = "AMediator+AAim.m"; sourceTree = ""; }; 87 | 2365A1F5229EB3E40027C78C /* BMediator+BAim.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "BMediator+BAim.h"; sourceTree = ""; }; 88 | 2365A1F6229EB3E40027C78C /* BMediator+BAim.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = "BMediator+BAim.m"; sourceTree = ""; }; 89 | 2365A1FB229EB9480027C78C /* PrefixHeader.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PrefixHeader.pch; sourceTree = ""; }; 90 | 2394B5A8229EBF2E00310A57 /* BAimController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BAimController.m; sourceTree = ""; }; 91 | 2394B5A9229EBF2E00310A57 /* BAimTarget.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BAimTarget.h; sourceTree = ""; }; 92 | 2394B5AA229EBF2E00310A57 /* BAimTarget.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BAimTarget.m; sourceTree = ""; }; 93 | 2394B5AB229EBF2E00310A57 /* BAimController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BAimController.h; sourceTree = ""; }; 94 | 2394B5AE229EC66C00310A57 /* DAimRegister.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DAimRegister.h; sourceTree = ""; }; 95 | 2394B5AF229EC66C00310A57 /* DAimRegister.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = DAimRegister.m; sourceTree = ""; }; 96 | 2394B5B1229EC8A400310A57 /* DMediator+DAim.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "DMediator+DAim.h"; sourceTree = ""; }; 97 | 2394B5B2229EC8A400310A57 /* DMediator+DAim.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = "DMediator+DAim.m"; sourceTree = ""; }; 98 | 2394B5B4229ED4A100310A57 /* CAimService.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CAimService.h; sourceTree = ""; }; 99 | 2394B5B5229ED85A00310A57 /* CAimServiceProvider.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CAimServiceProvider.h; sourceTree = ""; }; 100 | 2394B5B6229ED85A00310A57 /* CAimServiceProvider.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = CAimServiceProvider.m; sourceTree = ""; }; 101 | /* End PBXFileReference section */ 102 | 103 | /* Begin PBXFrameworksBuildPhase section */ 104 | 2365A199229E86F10027C78C /* Frameworks */ = { 105 | isa = PBXFrameworksBuildPhase; 106 | buildActionMask = 2147483647; 107 | files = ( 108 | ); 109 | runOnlyForDeploymentPostprocessing = 0; 110 | }; 111 | /* End PBXFrameworksBuildPhase section */ 112 | 113 | /* Begin PBXGroup section */ 114 | 233A1915238111E000FF9846 /* 弱符号解耦 */ = { 115 | isa = PBXGroup; 116 | children = ( 117 | 233A192A2381188000FF9846 /* Mediator (基础库独立repo) */, 118 | 233A193C238124CC00FF9846 /* EAimMediator (独立repo) */, 119 | 233A191C238112B700FF9846 /* EAim (模块独立repo) */, 120 | 233A19192381120E00FF9846 /* EController.h */, 121 | 233A191A2381120E00FF9846 /* EController.m */, 122 | ); 123 | path = "弱符号解耦"; 124 | sourceTree = ""; 125 | }; 126 | 233A191C238112B700FF9846 /* EAim (模块独立repo) */ = { 127 | isa = PBXGroup; 128 | children = ( 129 | 233A193323811BFC00FF9846 /* EAimRouter.h */, 130 | 233A193423811BFC00FF9846 /* EAimRouter.m */, 131 | 233A191D238112DC00FF9846 /* EAimController.h */, 132 | 233A191E238112DC00FF9846 /* EAimController.m */, 133 | ); 134 | path = "EAim (模块独立repo)"; 135 | sourceTree = ""; 136 | }; 137 | 233A192A2381188000FF9846 /* Mediator (基础库独立repo) */ = { 138 | isa = PBXGroup; 139 | children = ( 140 | 233A19362381211100FF9846 /* EMediator.h */, 141 | 233A19372381211100FF9846 /* EMediator.m */, 142 | ); 143 | path = "Mediator (基础库独立repo)"; 144 | sourceTree = ""; 145 | }; 146 | 233A1939238123C900FF9846 /* DMediator+DAim (独立repo) */ = { 147 | isa = PBXGroup; 148 | children = ( 149 | 2394B5B1229EC8A400310A57 /* DMediator+DAim.h */, 150 | 2394B5B2229EC8A400310A57 /* DMediator+DAim.m */, 151 | ); 152 | path = "DMediator+DAim (独立repo)"; 153 | sourceTree = ""; 154 | }; 155 | 233A193A2381244100FF9846 /* CAimService (独立repo) */ = { 156 | isa = PBXGroup; 157 | children = ( 158 | 2394B5B4229ED4A100310A57 /* CAimService.h */, 159 | ); 160 | path = "CAimService (独立repo)"; 161 | sourceTree = ""; 162 | }; 163 | 233A193B2381247200FF9846 /* BMediator+BAim (独立repo) */ = { 164 | isa = PBXGroup; 165 | children = ( 166 | 2365A1F5229EB3E40027C78C /* BMediator+BAim.h */, 167 | 2365A1F6229EB3E40027C78C /* BMediator+BAim.m */, 168 | ); 169 | path = "BMediator+BAim (独立repo)"; 170 | sourceTree = ""; 171 | }; 172 | 233A193C238124CC00FF9846 /* EAimMediator (独立repo) */ = { 173 | isa = PBXGroup; 174 | children = ( 175 | 233A193123811ADF00FF9846 /* EAimMediator.h */, 176 | ); 177 | path = "EAimMediator (独立repo)"; 178 | sourceTree = ""; 179 | }; 180 | 2365A193229E86F10027C78C = { 181 | isa = PBXGroup; 182 | children = ( 183 | 2365A19E229E86F10027C78C /* YBRouterAndDecouplingDemo */, 184 | 2365A19D229E86F10027C78C /* Products */, 185 | ); 186 | sourceTree = ""; 187 | }; 188 | 2365A19D229E86F10027C78C /* Products */ = { 189 | isa = PBXGroup; 190 | children = ( 191 | 2365A19C229E86F10027C78C /* YBRouterAndDecouplingDemo.app */, 192 | ); 193 | name = Products; 194 | sourceTree = ""; 195 | }; 196 | 2365A19E229E86F10027C78C /* YBRouterAndDecouplingDemo */ = { 197 | isa = PBXGroup; 198 | children = ( 199 | 2365A1E6229E978E0027C78C /* Tool */, 200 | 2365A1B7229E88010027C78C /* 非完全解耦 */, 201 | 2365A1B8229E881D0027C78C /* Runtime解耦 */, 202 | 2365A1B9229E88250027C78C /* Protocol解耦 */, 203 | 2365A1BA229E88460027C78C /* Block解耦 */, 204 | 233A1915238111E000FF9846 /* 弱符号解耦 */, 205 | 2365A19F229E86F10027C78C /* AppDelegate.h */, 206 | 2365A1A0229E86F10027C78C /* AppDelegate.m */, 207 | 2365A1D3229E8B5C0027C78C /* RootController.h */, 208 | 2365A1D4229E8B5D0027C78C /* RootController.mm */, 209 | 2365A1FB229EB9480027C78C /* PrefixHeader.pch */, 210 | 2365A1A5229E86F10027C78C /* Main.storyboard */, 211 | 2365A1A8229E86F30027C78C /* Assets.xcassets */, 212 | 2365A1AA229E86F30027C78C /* LaunchScreen.storyboard */, 213 | 2365A1AD229E86F30027C78C /* Info.plist */, 214 | 2365A1AE229E86F30027C78C /* main.m */, 215 | ); 216 | path = YBRouterAndDecouplingDemo; 217 | sourceTree = ""; 218 | }; 219 | 2365A1B7229E88010027C78C /* 非完全解耦 */ = { 220 | isa = PBXGroup; 221 | children = ( 222 | 2365A1D6229E8F190027C78C /* Mediator */, 223 | 2365A1EB229EB21A0027C78C /* AAim */, 224 | 2365A1BB229E88F30027C78C /* AController.h */, 225 | 2365A1BC229E88F30027C78C /* AController.m */, 226 | ); 227 | path = "非完全解耦"; 228 | sourceTree = ""; 229 | }; 230 | 2365A1B8229E881D0027C78C /* Runtime解耦 */ = { 231 | isa = PBXGroup; 232 | children = ( 233 | 2365A1D7229E8F630027C78C /* Mediator (基础库独立repo) */, 234 | 233A193B2381247200FF9846 /* BMediator+BAim (独立repo) */, 235 | 2365A1F2229EB3600027C78C /* BAim (模块独立repo) */, 236 | 2365A1C1229E89520027C78C /* BController.h */, 237 | 2365A1C2229E89520027C78C /* BController.m */, 238 | ); 239 | path = "Runtime解耦"; 240 | sourceTree = ""; 241 | }; 242 | 2365A1B9229E88250027C78C /* Protocol解耦 */ = { 243 | isa = PBXGroup; 244 | children = ( 245 | 2365A1D8229E8F650027C78C /* Mediator (基础库独立repo) */, 246 | 233A193A2381244100FF9846 /* CAimService (独立repo) */, 247 | 2365A1F3229EB36F0027C78C /* CAim (模块独立repo) */, 248 | 2365A1C7229E89660027C78C /* CController.h */, 249 | 2365A1C8229E89660027C78C /* CController.m */, 250 | ); 251 | path = "Protocol解耦"; 252 | sourceTree = ""; 253 | }; 254 | 2365A1BA229E88460027C78C /* Block解耦 */ = { 255 | isa = PBXGroup; 256 | children = ( 257 | 2365A1D9229E8F690027C78C /* Mediator (基础库独立repo) */, 258 | 233A1939238123C900FF9846 /* DMediator+DAim (独立repo) */, 259 | 2365A1F4229EB3870027C78C /* DAim (模块独立repo) */, 260 | 2365A1CD229E89B20027C78C /* DController.h */, 261 | 2365A1CE229E89B20027C78C /* DController.m */, 262 | ); 263 | path = "Block解耦"; 264 | sourceTree = ""; 265 | }; 266 | 2365A1D6229E8F190027C78C /* Mediator */ = { 267 | isa = PBXGroup; 268 | children = ( 269 | 2365A1DA229E949E0027C78C /* AMediator.h */, 270 | 2365A1DB229E949E0027C78C /* AMediator.m */, 271 | ); 272 | path = Mediator; 273 | sourceTree = ""; 274 | }; 275 | 2365A1D7229E8F630027C78C /* Mediator (基础库独立repo) */ = { 276 | isa = PBXGroup; 277 | children = ( 278 | 2365A1DD229E94A80027C78C /* BMediator.h */, 279 | 2365A1DE229E94A80027C78C /* BMediator.m */, 280 | ); 281 | path = "Mediator (基础库独立repo)"; 282 | sourceTree = ""; 283 | }; 284 | 2365A1D8229E8F650027C78C /* Mediator (基础库独立repo) */ = { 285 | isa = PBXGroup; 286 | children = ( 287 | 2365A1E0229E94AF0027C78C /* CMediator.h */, 288 | 2365A1E1229E94AF0027C78C /* CMediator.m */, 289 | ); 290 | path = "Mediator (基础库独立repo)"; 291 | sourceTree = ""; 292 | }; 293 | 2365A1D9229E8F690027C78C /* Mediator (基础库独立repo) */ = { 294 | isa = PBXGroup; 295 | children = ( 296 | 2365A1E3229E94B60027C78C /* DMediator.h */, 297 | 2365A1E4229E94B60027C78C /* DMediator.m */, 298 | ); 299 | path = "Mediator (基础库独立repo)"; 300 | sourceTree = ""; 301 | }; 302 | 2365A1E6229E978E0027C78C /* Tool */ = { 303 | isa = PBXGroup; 304 | children = ( 305 | 2365A1E7229E97B20027C78C /* UIViewController+UI.h */, 306 | 2365A1E8229E97B20027C78C /* UIViewController+UI.m */, 307 | ); 308 | path = Tool; 309 | sourceTree = ""; 310 | }; 311 | 2365A1EB229EB21A0027C78C /* AAim */ = { 312 | isa = PBXGroup; 313 | children = ( 314 | 2365A1EF229EB2650027C78C /* AMediator+AAim.h */, 315 | 2365A1F0229EB2650027C78C /* AMediator+AAim.m */, 316 | 2365A1BE229E89330027C78C /* AAimController.h */, 317 | 2365A1BF229E89330027C78C /* AAimController.m */, 318 | ); 319 | path = AAim; 320 | sourceTree = ""; 321 | }; 322 | 2365A1F2229EB3600027C78C /* BAim (模块独立repo) */ = { 323 | isa = PBXGroup; 324 | children = ( 325 | 2394B5A9229EBF2E00310A57 /* BAimTarget.h */, 326 | 2394B5AA229EBF2E00310A57 /* BAimTarget.m */, 327 | 2394B5AB229EBF2E00310A57 /* BAimController.h */, 328 | 2394B5A8229EBF2E00310A57 /* BAimController.m */, 329 | ); 330 | path = "BAim (模块独立repo)"; 331 | sourceTree = ""; 332 | }; 333 | 2365A1F3229EB36F0027C78C /* CAim (模块独立repo) */ = { 334 | isa = PBXGroup; 335 | children = ( 336 | 2394B5B5229ED85A00310A57 /* CAimServiceProvider.h */, 337 | 2394B5B6229ED85A00310A57 /* CAimServiceProvider.m */, 338 | 2365A1CA229E896E0027C78C /* CAimController.h */, 339 | 2365A1CB229E896E0027C78C /* CAimController.m */, 340 | ); 341 | path = "CAim (模块独立repo)"; 342 | sourceTree = ""; 343 | }; 344 | 2365A1F4229EB3870027C78C /* DAim (模块独立repo) */ = { 345 | isa = PBXGroup; 346 | children = ( 347 | 2394B5AE229EC66C00310A57 /* DAimRegister.h */, 348 | 2394B5AF229EC66C00310A57 /* DAimRegister.m */, 349 | 2365A1D0229E89BE0027C78C /* DAimController.h */, 350 | 2365A1D1229E89BE0027C78C /* DAimController.m */, 351 | ); 352 | path = "DAim (模块独立repo)"; 353 | sourceTree = ""; 354 | }; 355 | /* End PBXGroup section */ 356 | 357 | /* Begin PBXNativeTarget section */ 358 | 2365A19B229E86F10027C78C /* YBRouterAndDecouplingDemo */ = { 359 | isa = PBXNativeTarget; 360 | buildConfigurationList = 2365A1B2229E86F30027C78C /* Build configuration list for PBXNativeTarget "YBRouterAndDecouplingDemo" */; 361 | buildPhases = ( 362 | 2365A198229E86F10027C78C /* Sources */, 363 | 2365A199229E86F10027C78C /* Frameworks */, 364 | 2365A19A229E86F10027C78C /* Resources */, 365 | ); 366 | buildRules = ( 367 | ); 368 | dependencies = ( 369 | ); 370 | name = YBRouterAndDecouplingDemo; 371 | productName = YBRouterAndDecouplingDemo; 372 | productReference = 2365A19C229E86F10027C78C /* YBRouterAndDecouplingDemo.app */; 373 | productType = "com.apple.product-type.application"; 374 | }; 375 | /* End PBXNativeTarget section */ 376 | 377 | /* Begin PBXProject section */ 378 | 2365A194229E86F10027C78C /* Project object */ = { 379 | isa = PBXProject; 380 | attributes = { 381 | LastUpgradeCheck = 1020; 382 | ORGANIZATIONNAME = "杨波"; 383 | TargetAttributes = { 384 | 2365A19B229E86F10027C78C = { 385 | CreatedOnToolsVersion = 10.2; 386 | }; 387 | }; 388 | }; 389 | buildConfigurationList = 2365A197229E86F10027C78C /* Build configuration list for PBXProject "YBRouterAndDecouplingDemo" */; 390 | compatibilityVersion = "Xcode 9.3"; 391 | developmentRegion = en; 392 | hasScannedForEncodings = 0; 393 | knownRegions = ( 394 | en, 395 | Base, 396 | ); 397 | mainGroup = 2365A193229E86F10027C78C; 398 | productRefGroup = 2365A19D229E86F10027C78C /* Products */; 399 | projectDirPath = ""; 400 | projectRoot = ""; 401 | targets = ( 402 | 2365A19B229E86F10027C78C /* YBRouterAndDecouplingDemo */, 403 | ); 404 | }; 405 | /* End PBXProject section */ 406 | 407 | /* Begin PBXResourcesBuildPhase section */ 408 | 2365A19A229E86F10027C78C /* Resources */ = { 409 | isa = PBXResourcesBuildPhase; 410 | buildActionMask = 2147483647; 411 | files = ( 412 | 2365A1AC229E86F30027C78C /* LaunchScreen.storyboard in Resources */, 413 | 2365A1A9229E86F30027C78C /* Assets.xcassets in Resources */, 414 | 2365A1A7229E86F10027C78C /* Main.storyboard in Resources */, 415 | ); 416 | runOnlyForDeploymentPostprocessing = 0; 417 | }; 418 | /* End PBXResourcesBuildPhase section */ 419 | 420 | /* Begin PBXSourcesBuildPhase section */ 421 | 2365A198229E86F10027C78C /* Sources */ = { 422 | isa = PBXSourcesBuildPhase; 423 | buildActionMask = 2147483647; 424 | files = ( 425 | 2394B5AD229EBF2E00310A57 /* BAimTarget.m in Sources */, 426 | 2365A1F1229EB2650027C78C /* AMediator+AAim.m in Sources */, 427 | 2365A1D5229E8B5D0027C78C /* RootController.mm in Sources */, 428 | 2365A1DF229E94A80027C78C /* BMediator.m in Sources */, 429 | 233A19382381211100FF9846 /* EMediator.m in Sources */, 430 | 2365A1F7229EB3E40027C78C /* BMediator+BAim.m in Sources */, 431 | 2394B5B3229EC8A400310A57 /* DMediator+DAim.m in Sources */, 432 | 2365A1CF229E89B20027C78C /* DController.m in Sources */, 433 | 2365A1E2229E94AF0027C78C /* CMediator.m in Sources */, 434 | 2394B5B0229EC66C00310A57 /* DAimRegister.m in Sources */, 435 | 2365A1E5229E94B60027C78C /* DMediator.m in Sources */, 436 | 2394B5B7229ED85A00310A57 /* CAimServiceProvider.m in Sources */, 437 | 2365A1C0229E89330027C78C /* AAimController.m in Sources */, 438 | 2365A1DC229E949E0027C78C /* AMediator.m in Sources */, 439 | 2365A1CC229E896E0027C78C /* CAimController.m in Sources */, 440 | 2394B5AC229EBF2E00310A57 /* BAimController.m in Sources */, 441 | 2365A1C3229E89520027C78C /* BController.m in Sources */, 442 | 233A191B2381120E00FF9846 /* EController.m in Sources */, 443 | 2365A1BD229E88F30027C78C /* AController.m in Sources */, 444 | 2365A1D2229E89BE0027C78C /* DAimController.m in Sources */, 445 | 233A191F238112DC00FF9846 /* EAimController.m in Sources */, 446 | 2365A1AF229E86F30027C78C /* main.m in Sources */, 447 | 233A193523811BFC00FF9846 /* EAimRouter.m in Sources */, 448 | 2365A1A1229E86F10027C78C /* AppDelegate.m in Sources */, 449 | 2365A1E9229E97B20027C78C /* UIViewController+UI.m in Sources */, 450 | 2365A1C9229E89660027C78C /* CController.m in Sources */, 451 | ); 452 | runOnlyForDeploymentPostprocessing = 0; 453 | }; 454 | /* End PBXSourcesBuildPhase section */ 455 | 456 | /* Begin PBXVariantGroup section */ 457 | 2365A1A5229E86F10027C78C /* Main.storyboard */ = { 458 | isa = PBXVariantGroup; 459 | children = ( 460 | 2365A1A6229E86F10027C78C /* Base */, 461 | ); 462 | name = Main.storyboard; 463 | sourceTree = ""; 464 | }; 465 | 2365A1AA229E86F30027C78C /* LaunchScreen.storyboard */ = { 466 | isa = PBXVariantGroup; 467 | children = ( 468 | 2365A1AB229E86F30027C78C /* Base */, 469 | ); 470 | name = LaunchScreen.storyboard; 471 | sourceTree = ""; 472 | }; 473 | /* End PBXVariantGroup section */ 474 | 475 | /* Begin XCBuildConfiguration section */ 476 | 2365A1B0229E86F30027C78C /* Debug */ = { 477 | isa = XCBuildConfiguration; 478 | buildSettings = { 479 | ALWAYS_SEARCH_USER_PATHS = NO; 480 | CLANG_ANALYZER_NONNULL = YES; 481 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 482 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 483 | CLANG_CXX_LIBRARY = "libc++"; 484 | CLANG_ENABLE_MODULES = YES; 485 | CLANG_ENABLE_OBJC_ARC = YES; 486 | CLANG_ENABLE_OBJC_WEAK = YES; 487 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 488 | CLANG_WARN_BOOL_CONVERSION = YES; 489 | CLANG_WARN_COMMA = YES; 490 | CLANG_WARN_CONSTANT_CONVERSION = YES; 491 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 492 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 493 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 494 | CLANG_WARN_EMPTY_BODY = YES; 495 | CLANG_WARN_ENUM_CONVERSION = YES; 496 | CLANG_WARN_INFINITE_RECURSION = YES; 497 | CLANG_WARN_INT_CONVERSION = YES; 498 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 499 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 500 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 501 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 502 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 503 | CLANG_WARN_STRICT_PROTOTYPES = YES; 504 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 505 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 506 | CLANG_WARN_UNREACHABLE_CODE = YES; 507 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 508 | CODE_SIGN_IDENTITY = "iPhone Developer"; 509 | COPY_PHASE_STRIP = NO; 510 | DEBUG_INFORMATION_FORMAT = dwarf; 511 | ENABLE_STRICT_OBJC_MSGSEND = YES; 512 | ENABLE_TESTABILITY = YES; 513 | GCC_C_LANGUAGE_STANDARD = gnu11; 514 | GCC_DYNAMIC_NO_PIC = NO; 515 | GCC_NO_COMMON_BLOCKS = YES; 516 | GCC_OPTIMIZATION_LEVEL = 0; 517 | GCC_PREPROCESSOR_DEFINITIONS = ( 518 | "DEBUG=1", 519 | "$(inherited)", 520 | ); 521 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 522 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 523 | GCC_WARN_UNDECLARED_SELECTOR = YES; 524 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 525 | GCC_WARN_UNUSED_FUNCTION = YES; 526 | GCC_WARN_UNUSED_VARIABLE = YES; 527 | IPHONEOS_DEPLOYMENT_TARGET = 12.2; 528 | MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; 529 | MTL_FAST_MATH = YES; 530 | ONLY_ACTIVE_ARCH = YES; 531 | SDKROOT = iphoneos; 532 | }; 533 | name = Debug; 534 | }; 535 | 2365A1B1229E86F30027C78C /* Release */ = { 536 | isa = XCBuildConfiguration; 537 | buildSettings = { 538 | ALWAYS_SEARCH_USER_PATHS = NO; 539 | CLANG_ANALYZER_NONNULL = YES; 540 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 541 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 542 | CLANG_CXX_LIBRARY = "libc++"; 543 | CLANG_ENABLE_MODULES = YES; 544 | CLANG_ENABLE_OBJC_ARC = YES; 545 | CLANG_ENABLE_OBJC_WEAK = YES; 546 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 547 | CLANG_WARN_BOOL_CONVERSION = YES; 548 | CLANG_WARN_COMMA = YES; 549 | CLANG_WARN_CONSTANT_CONVERSION = YES; 550 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 551 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 552 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 553 | CLANG_WARN_EMPTY_BODY = YES; 554 | CLANG_WARN_ENUM_CONVERSION = YES; 555 | CLANG_WARN_INFINITE_RECURSION = YES; 556 | CLANG_WARN_INT_CONVERSION = YES; 557 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 558 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 559 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 560 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 561 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 562 | CLANG_WARN_STRICT_PROTOTYPES = YES; 563 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 564 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 565 | CLANG_WARN_UNREACHABLE_CODE = YES; 566 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 567 | CODE_SIGN_IDENTITY = "iPhone Developer"; 568 | COPY_PHASE_STRIP = NO; 569 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 570 | ENABLE_NS_ASSERTIONS = NO; 571 | ENABLE_STRICT_OBJC_MSGSEND = YES; 572 | GCC_C_LANGUAGE_STANDARD = gnu11; 573 | GCC_NO_COMMON_BLOCKS = YES; 574 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 575 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 576 | GCC_WARN_UNDECLARED_SELECTOR = YES; 577 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 578 | GCC_WARN_UNUSED_FUNCTION = YES; 579 | GCC_WARN_UNUSED_VARIABLE = YES; 580 | IPHONEOS_DEPLOYMENT_TARGET = 12.2; 581 | MTL_ENABLE_DEBUG_INFO = NO; 582 | MTL_FAST_MATH = YES; 583 | SDKROOT = iphoneos; 584 | VALIDATE_PRODUCT = YES; 585 | }; 586 | name = Release; 587 | }; 588 | 2365A1B3229E86F30027C78C /* Debug */ = { 589 | isa = XCBuildConfiguration; 590 | buildSettings = { 591 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 592 | CODE_SIGN_STYLE = Automatic; 593 | DEVELOPMENT_TEAM = UU8H9EQ986; 594 | GCC_PREFIX_HEADER = "$(SRCROOT)/YBRouterAndDecouplingDemo/PrefixHeader.pch"; 595 | INFOPLIST_FILE = YBRouterAndDecouplingDemo/Info.plist; 596 | LD_RUNPATH_SEARCH_PATHS = ( 597 | "$(inherited)", 598 | "@executable_path/Frameworks", 599 | ); 600 | PRODUCT_BUNDLE_IDENTIFIER = yangbo.YBRouterAndDecouplingDemo; 601 | PRODUCT_NAME = "$(TARGET_NAME)"; 602 | TARGETED_DEVICE_FAMILY = "1,2"; 603 | }; 604 | name = Debug; 605 | }; 606 | 2365A1B4229E86F30027C78C /* Release */ = { 607 | isa = XCBuildConfiguration; 608 | buildSettings = { 609 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 610 | CODE_SIGN_STYLE = Automatic; 611 | DEVELOPMENT_TEAM = UU8H9EQ986; 612 | GCC_PREFIX_HEADER = "$(SRCROOT)/YBRouterAndDecouplingDemo/PrefixHeader.pch"; 613 | INFOPLIST_FILE = YBRouterAndDecouplingDemo/Info.plist; 614 | LD_RUNPATH_SEARCH_PATHS = ( 615 | "$(inherited)", 616 | "@executable_path/Frameworks", 617 | ); 618 | PRODUCT_BUNDLE_IDENTIFIER = yangbo.YBRouterAndDecouplingDemo; 619 | PRODUCT_NAME = "$(TARGET_NAME)"; 620 | TARGETED_DEVICE_FAMILY = "1,2"; 621 | }; 622 | name = Release; 623 | }; 624 | /* End XCBuildConfiguration section */ 625 | 626 | /* Begin XCConfigurationList section */ 627 | 2365A197229E86F10027C78C /* Build configuration list for PBXProject "YBRouterAndDecouplingDemo" */ = { 628 | isa = XCConfigurationList; 629 | buildConfigurations = ( 630 | 2365A1B0229E86F30027C78C /* Debug */, 631 | 2365A1B1229E86F30027C78C /* Release */, 632 | ); 633 | defaultConfigurationIsVisible = 0; 634 | defaultConfigurationName = Release; 635 | }; 636 | 2365A1B2229E86F30027C78C /* Build configuration list for PBXNativeTarget "YBRouterAndDecouplingDemo" */ = { 637 | isa = XCConfigurationList; 638 | buildConfigurations = ( 639 | 2365A1B3229E86F30027C78C /* Debug */, 640 | 2365A1B4229E86F30027C78C /* Release */, 641 | ); 642 | defaultConfigurationIsVisible = 0; 643 | defaultConfigurationName = Release; 644 | }; 645 | /* End XCConfigurationList section */ 646 | }; 647 | rootObject = 2365A194229E86F10027C78C /* Project object */; 648 | } 649 | --------------------------------------------------------------------------------