标签:
//单例模式 #import "MySingleton.h" @implementation MySingleton - (instancetype) sharedInstance{ static MySingleton *SharedInstance = nil; static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ SharedInstance = [MySingleton new]; }); return SharedInstance; } @end
标签:
原文地址:http://my.oschina.net/u/1782374/blog/394561