interfaceSuper { publicvoid m(Object o); // This method should not be visible in AC publicvoid m(String s); // This method should not be visible in AC
}
interface One extendsSuper { publicvoid m(Object o); publicvoid m1(); // Either this method or Two.m1 should be visible in AC
}
interface Two extendsSuper { publicvoid m(String s); publicvoid m1(); // Either this method or One.m1 should be visible in AC
}
abstractclass AC implements One, Two {
}
class CC extends AC { publicvoid m(Object o) {
} publicvoid m(String s) {
} publicvoid m1() {
} publicstaticvoid main(String[] args) {
System.out.println("Goodbye from VisibleMethods!");
}
}
privatevoid verifyContains(List<String> methods, int matches,
String... sigs) throws Exception { if (countMatches(methods, sigs) != matches) { thrownew Exception("visibleMethods() should have contained "
+ matches + " entry/entries from " + Arrays.toString(sigs));
}
}
privateint countMatches(List<String> list1, String[] list2) { int count = 0; for (String s1 : list1) { for (String s2 : list2) { if (s1.equals(s2)) {
count++;
}
}
} return count;
}
}
Messung V0.5 in Prozent
¤ Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.0.10Bemerkung:
(vorverarbeitet am 2026-06-10)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.