摘要: 1、加self的方式:1Student *mystudent = [[Student alloc] init];//mystudent 对象 retainCount = 1;2self.student = mystudent;//student 对象 retainCount = 2;3[mystudent release];//student 对象 retainCount = 1;retainCount指对象引用计数,student的property 是retain 默认使用self.student引用计数+1。2、不加self的方式1Student *mystudent = [[Studen 阅读全文
posted @ 2012-06-14 13:12 dsqtb 阅读(127) 评论(0) 推荐(0)