<pre>
@interface A : NSObject
@end
@interface A (Extention)
-(void)test;
@end
</pre>
<pre>
@implementation A
-(void)test{
NSLog(@"A");
}
@end
@implementation A (Extention)
-(void)test{
NSLog(@"A Extention");
}
@end
</pre>
<pre>
@interface B : A
@end
@implementation B
-(void)test{
NSLog(@"B");
[super test];
}
@end
</pre>
网友评论