NSTimer两种初始化方式的区别
NSTimer有两种常用的创建方式 // 第一种 timer = [NSTimer timerWithTimeInterval:1 target:self selector:@selector(timerSelec...
NSTimer有两种常用的创建方式 // 第一种 timer = [NSTimer timerWithTimeInterval:1 target:self selector:@selector(timerSelec...
使用NSTimer定义定时器需要将NSTimer对象添加到当前线程的RunLoop。否则在进行其他RunLoop切换时,会导致NSTimer受到影响,不能准确的进行调用。 而使用GCD创建定时器,更加精确,不需要使...
当前iOS的多线程方式分为4中 pthreads NSThread GCD NSOperation \& NSOperationQueue pthreads 定义 POSIX线程(英语:POSIX Threads,...