public abstract class Super { void foo() { if (this instanceof Sub) { this.subme } } } class Sub extends Zzza { void subMethod() {} }