private static boolean overridesIsValidFragment(ResolvedClass resolvedClass) { Iterable<ResolvedMethod> resolvedMethods = resolvedClass.getMethods(IS_VALID_FRAGMENT, false); for (ResolvedMethod resolvedMethod : resolvedMethods) { if (resolvedMethod.getArgumentCount() == 1 && resolvedMethod.getArgumentType(0).getName().equals(TYPE_STRING)) { return true; } } return false; } }
for (String methodName : methodNames) { boolean found = false; for (ResolvedMethod method : resolvedClass.getMethods(methodName, true)) {
String methodName = getName(); int argCount = getArgumentCount(); for (ResolvedMethod method : cls.getMethods(methodName, true)) { if (argCount != method.getArgumentCount()) { continue;
private static boolean isJavaScriptAnnotated(ResolvedClass clz) { while (clz != null) { for (ResolvedAnnotation annotation : clz.getAnnotations()) { if (annotation.getType().matchesSignature(JAVASCRIPT_INTERFACE_CLS)) { return true; } } for (ResolvedMethod method : clz.getMethods(false)) { for (ResolvedAnnotation annotation : method.getAnnotations()) { if (annotation.getType().matchesSignature(JAVASCRIPT_INTERFACE_CLS)) { return true; } } } clz = clz.getSuperClass(); } return false; }