我有一个小问题,关于xcode中的super是什么意思。比如说我有下面这段代码。如果在dealloc方法中先调用[super dealloc],它会起作用吗?或者说super总是应该放在最后面吗?super到底是什么-我知道它是超类,但它是父类还是?
这是该类的.h文件
@interface TwitterTableViewController : PullRefreshTableViewController<TweetDelegate>
这是上述接口的.m类中的一些代码
- (id)initWithStyle:(UITableViewStyle)style
{
self = [super initWithStyle:style];
if (self) {
// Custom initialization
}
return self;
}
- (void)dealloc
{
[self.twitterManager release];
[tweets release];
[lastRefreshedLabel release];
[super dealloc];
我已经查看了所有相关资料,但是仍然没有一个令人满意的解释。如果有人能用通俗易懂的语言解释一下这个问题,那就太好了。谢谢!