@Override public IdentifierTree visitMethod(MethodTree methodTree, Void aVoid) { if (isSuppressed(methodTree)) { return null; } return super.visitMethod(methodTree, aVoid); }
@Override public Void visitMethod(MethodTree tree, Void unused) { // Ignore synthetic constructors: if (ASTHelpers.isGeneratedConstructor(tree)) { return null; } return super.visitMethod(tree, null); }
@Override public Void visitMethod(MethodTree method, Void unused) { return isSuppressed(method) ? null : super.visitMethod(method, unused); }
@Override public Void visitMethod(MethodTree tree, Void unused) { if (isSuppressed(tree)) { suppressions++; matchMethod(tree); super.visitMethod(tree, null); suppressions--; } else { matchMethod(tree); super.visitMethod(tree, null); } return null; }
@Override public Void visitMethod(MethodTree methodTree, Void aVoid) { if (implementationMethodMatcher.matches(methodTree, state)) { processImplementationMethod(methodTree); } return super.visitMethod(methodTree, aVoid); }
@Override public Void visitMethod(MethodTree node, InitializationContext init) { MethodSymbol sym = ASTHelpers.getSymbol(node); if (sym != null && sym.isConstructor()) { init = InitializationContext.INSTANCE; } return super.visitMethod(node, init); }
@Override public Void visitMethod(MethodTree tree, Void unused) { if (getSymbol(tree).equals(methodSymbol)) { removeByIndex(tree.getParameters()); } return super.visitMethod(tree, null); }
@Override public Void visitMethod(MethodTree tree, HeldLockSet locks) { // Synchronized instance methods hold the 'this' lock; synchronized static methods // hold the Class lock for the enclosing class. Set<Modifier> mods = tree.getModifiers().getFlags(); if (mods.contains(Modifier.SYNCHRONIZED)) { Symbol owner = (((JCTree.JCMethodDecl) tree).sym.owner); GuardedByExpression lock = mods.contains(Modifier.STATIC) ? F.classLiteral(owner) : F.thisliteral(); locks = locks.plus(lock); } // @GuardedBy annotations on methods are trusted for declarations, and checked // for invocations. for (String guard : GuardedByUtils.getGuardValues(tree, visitorState)) { Optional<GuardedByExpression> bound = GuardedByBinder.bindString(guard, GuardedBySymbolResolver.from(tree, visitorState)); if (bound.isPresent()) { locks = locks.plus(bound.get()); } } return super.visitMethod(tree, locks); }
@Override public Void visitMethod(MethodTree tree, Void unused) { // Ignore synthetic constructors: if (ASTHelpers.isGeneratedConstructor(tree)) { return null; } return super.visitMethod(tree, null); }
@Override public IdentifierTree visitMethod(MethodTree methodTree, Void aVoid) { if (isSuppressed(methodTree)) { return null; } return super.visitMethod(methodTree, aVoid); }
@Override public Void visitMethod(MethodTree node, Trees trees) { add(node, trees); return super.visitMethod(node, trees); }
@Override public Optional<TreePath> visitMethod(@Nullable MethodTree node, Void v) { if (node == null) { return Optional.absent(); } else if (isMatch(node, node.getName())) { return currentPathPlus(node); } return super.visitMethod(node, v); }
@Override public Tree visitMethod(MethodTree tree, Void v) { if (useStatus != UsageStatus.USED && !canSkip(getCurrentPath())) { return super.visitMethod(tree, v); } return null; }
@Override public Optional<TreePath> visitMethod(@Nullable MethodTree node, Void v) { if (node == null) { return Optional.absent(); } else if (isMatch(node, node.getName())) { return currentPathPlus(node); } return super.visitMethod(node, v); }
@Override public Optional<TreePath> visitMethod(@Nullable MethodTree node, Void v) { if (node == null) { return Optional.absent(); } else if (isMatch(node, node.getName())) { return currentPathPlus(node); } return super.visitMethod(node, v); }
@Override public Void visitMethod(MethodTree node, InitializationContext init) { MethodSymbol sym = ASTHelpers.getSymbol(node); if (sym != null && sym.isConstructor()) { init = InitializationContext.INSTANCE; } return super.visitMethod(node, init); }
@Override public Tree visitMethod(MethodTree tree,Element elemToRename) { renameIfMatch(getCurrentPath(), tree, elemToRename); return super.visitMethod(tree, elemToRename); }
@Override public Void visitMethod(MethodTree tree, TemplateModel templateModel) { tryAddParameter(trees.getElement(getCurrentPath()), templateModel); return super.visitMethod(tree, templateModel); }
@Override public Void visitMethod(MethodTree node, Void p) { Tree returnType = node.getReturnType(); if (returnType != null) { checkPackageAccess(returnType, getQualifiedPackageName(returnType)); } return super.visitMethod(node, p); }
@Override public Void visitMethod(MethodTree node, Void p) { if (info.getTreeUtilities().isSynthetic(/*should not be used:*/getCurrentPath().getCompilationUnit(), node)) return null; return super.visitMethod(node, p); }