static L findMethodsNamed2(O obj, S method, bool staticOnly) { if (obj == null) ret null; ret findMethodsNamed2(_getClass(obj), method, staticOnly); } static L findMethodsNamed2(Class c, S method, bool staticOnly) { new L l; while (c != null) { for (Method m : c.getDeclaredMethods()) if (m.getName().equals(method) && (!staticOnly || (m.getModifiers() & Modifier.STATIC) != 0)) { m.setAccessible(true); l.add(m); } c = c.getSuperclass(); } ret l; }