Objective-C 浅析Copy语法(二)

2014-11-23 17:55:12 · 作者: · 浏览: 27
-(id)copyWithZone:(NSZone *)zone{ Student *student = [super copyWithZone:zone]; student.school = self.school; return student; } @end
注意其中copyWithZone方法的实现。