首页
学习
活动
专区
工具
TVP
发布
精选内容/技术社群/优惠产品,尽在小程序
立即前往
您找到你想要的搜索结果了吗?
是的
没有找到

iOS应用架构谈 view层的组织和调用方案 pragma mark - life cyclepragma mark - life cyclepragma mark - getters and set

比如这样: pragma mark - life cycle (void)viewDidLoad { [super viewDidLoad]; self.view.backgroundColor...然后要求业务工程师写代码的时候按照顺序来分配代码块的位置,先是life cycle,然后是Delegate方法实现,然后是event response,然后才是getters and setters。...关于private methods,正常情况下ViewController里面不应该写 不是delegate方法的,不是event response方法的,不是life cycle方法的,就是private...比如在写ViewController时,我之前给团队制定的规范就是前面一段全部是getter setter,然后接下来一段是life cycle,viewDidLoad之类的方法都在这里。...interface CustomObject() @property (nonatomic, strong) UILabel *label; @end @implement pragma mark - life

92780
领券