开发者

Java question about super

If A extends B, t开发者_如何学Gohen I know I can user super.* to access B's method.

What if A extends B and B extends C, how to access C's method from A?


If a method is overriden in B, you cannot "bypass" it.

It's not possible even when using reflection (not in any way known to me).


not sure but I think you can do super.super.methodA ?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜