摘要:
1. 字符串转Data NSString * str =@"str"; NSData *data =[str dataUsingEncoding:NSUTF8StringEncoding]; 2.NSData 转NSString NSString * str =[[NSString alloc] i 阅读全文
摘要:
转自http://www.jianshu.com/p/e03aa66a197f 很多人实现单例会这样写: @implementation XXClass + (id)sharedInstance { static XXClass *sharedInstance = nil; @synchronize 阅读全文