摘要: 1.直接加密2.多次加密3.先加密,后乱序4.根据公司规定方法加密 阅读全文
posted @ 2015-06-07 15:11 forflame 阅读(198) 评论(0) 推荐(0) 编辑
摘要: // .h文件#define WLSingletonH(name) + (instancetype)shared##name;// .m文件#if __has_feature(objc_arc) #define WLSingletonM(name) \ static id _instac... 阅读全文
posted @ 2015-06-07 14:21 forflame 阅读(248) 评论(0) 推荐(0) 编辑
摘要: 有时想在代码中有只执行一次的代码,第二次不会执行 static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ NSLog(@"once"); });当第二次执行到这里时,相当于该代码段从未出现过一样 阅读全文
posted @ 2015-06-07 13:51 forflame 阅读(147) 评论(0) 推荐(0) 编辑
摘要: - 1.使用NSThread类[NSThread sleepForTimeInterval:3];该方法会阻塞当前线程-2.使用NSObject中的方法[self performSelector:@selector(download:) withObject:sender afterDelay:ti... 阅读全文
posted @ 2015-06-07 13:45 forflame 阅读(386) 评论(0) 推荐(0) 编辑