iOS异步处理:从NSThread到GCD的实现
1. 异步处理基础代码示例
1.1 项目结构代码
首先,我们来看一下项目的基本结构代码,主要包括 AppDelegate 和 ViewController 相关的代码。
1.1.1 AppDelegate.h
#import <UIKit/UIKit.h>
@class ViewController;
@interface AppDelegate : UIResponder <UIApplicationDelegate>
@property (strong, nonatomic) UIWindow *window;
@property (strong, nonatomic) ViewController *viewController;
@end
1.1.2 AppDelegate.m
#import "AppDelegate.h"
#import "ViewController.h"
@implementation AppDelegate
@synthesize window = _window;
@synthesize viewController = _viewController;
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:
超级会员免费看
订阅专栏 解锁全文
845

被折叠的 条评论
为什么被折叠?



