@Override public boolean visit(MethodInvocation node) { Expression exp= node.getExpression(); if (exp != null) fIgnore.add(node.getName()); return true; } @Override
@Override public boolean visit(MethodInvocation node) { Expression exp = node.getExpression(); if (exp != null) { fIgnore.add(node.getName()); } return true; }
@Override public boolean visit(MethodInvocation node) { if (fTypeCounter == 0) { Expression receiver= node.getExpression(); if (receiver == null && !isStaticallyImported(node.getName())) { fImplicitReceivers.add(node); } } return true; } @Override
@Override public boolean visit(MethodInvocation node) { if (fTargetIsStaticMethodImport) { return !addPossibleStaticImport(node.getName(), node.resolveMethodBinding()); } return true; }
private static boolean doesParentQualify(Name fieldName) { ASTNode parent= fieldName.getParent(); Assert.isNotNull(parent); if (parent instanceof FieldAccess && ((FieldAccess) parent).getName() == fieldName) return true; if (parent instanceof QualifiedName && ((QualifiedName) parent).getName() == fieldName) return true; if (parent instanceof MethodInvocation && ((MethodInvocation) parent).getName() == fieldName) return true; return false; }
public final boolean visit(final MethodInvocation node) { Assert.isNotNull(node); if (fAnonymousClass > 0) { final IMethodBinding binding= node.resolveMethodBinding(); if (binding != null) { if (node.getExpression() == null && !Modifier.isStatic(binding.getModifiers())) fResult.add(node.getName()); } } return true; }
public boolean visit(MethodInvocation invocation) { if (invocation.getExpression() == null) qualifyUnqualifiedMemberNameIfNecessary(invocation.getName()); else invocation.getExpression().accept(this); for (Iterator it= invocation.arguments().iterator(); it.hasNext();) ((Expression) it.next()).accept(this); return false; }
@Override protected CSExpression mapMethodTargetExpression(MethodInvocation node) { if (null == node.getExpression()) { return createEnclosingTargetReferences(node.getName()); } return super.mapMethodTargetExpression(node); }
@Override public boolean visit(MethodInvocation node) { int lParen = this.tm.firstIndexAfter(node.getName(), TokenNameLPAREN); int rParen = this.tm.lastIndexIn(node, TokenNameRPAREN); handleParenthesesPositions(lParen, rParen, this.options.parenthesis_positions_in_method_invocation); return true; }
@Override public boolean visit(MethodInvocation node) { int lParen = this.tm.firstIndexAfter(node.getName(), TokenNameLPAREN); int rParen = this.tm.lastIndexIn(node, TokenNameRPAREN); handleParenthesesPositions(lParen, rParen, this.options.parenthesis_positions_in_method_invocation); return true; }
public boolean isEnumNameMethodInvocation (MethodInvocation node) { return node.getName().getIdentifier().equals("name") && node.getExpression() != null && node.getExpression().resolveTypeBinding().isEnum(); }
@Override public boolean visit(MethodInvocation node) { if (isExitPoint(node.resolveMethodBinding())) { SimpleName name= node.getName(); fResult.add(new OccurrenceLocation(name.getStartPosition(), name.getLength(), 0, fExitDescription)); } return true; }
public boolean isEnumOrdinalMethodInvocation (MethodInvocation node) { return node.getName().getIdentifier().equals("ordinal") && node.getExpression() != null && node.getExpression().resolveTypeBinding().isEnum(); }
@Override public boolean visit(MethodInvocation node) { if (node.getExpression() == null) { visitName(node.getName()); } else { fResult &= new LoadTimeConstantChecker((IExpressionFragment) ASTFragmentFactory.createFragmentForFullSubtree(node.getExpression())).check(); } return false; }
@Override public boolean visit(MethodInvocation node) { if(node.getExpression() == null) { visitName(node.getName()); } else { fResult&= new LoadTimeConstantChecker((IExpressionFragment) ASTFragmentFactory.createFragmentForFullSubtree(node.getExpression())).check(); } return false; } @Override
int treeSize() { return memSize() + (this.optionalExpression == null ? 0 : getExpression().treeSize()) + (this.typeArguments == null ? 0 : this.typeArguments.listSize()) + (this.methodName == null ? 0 : getName().treeSize()) + (this.arguments == null ? 0 : this.arguments.listSize()); } }
ASTNode clone0(AST target) { MethodInvocation result = new MethodInvocation(target); result.setSourceRange(getStartPosition(), getLength()); result.setName((SimpleName) getName().clone(target)); result.setExpression( (Expression) ASTNode.copySubtree(target, getExpression())); if (this.ast.apiLevel >= AST.JLS3_INTERNAL) { result.typeArguments().addAll(ASTNode.copySubtrees(target, typeArguments())); } result.arguments().addAll(ASTNode.copySubtrees(target, arguments())); return result; }
ASTNode clone0(AST target) { MethodInvocation result = new MethodInvocation(target); result.setSourceRange(getStartPosition(), getLength()); result.setName((SimpleName) getName().clone(target)); result.setExpression( (Expression) ASTNode.copySubtree(target, getExpression())); if (this.ast.apiLevel >= AST.JLS3) { result.typeArguments().addAll(ASTNode.copySubtrees(target, typeArguments())); } result.arguments().addAll(ASTNode.copySubtrees(target, arguments())); return result; }
ASTNode clone0(AST target) { MethodInvocation result = new MethodInvocation(target); result.setSourceRange(getStartPosition(), getLength()); result.setName((SimpleName) getName().clone(target)); result.setExpression( (Expression) ASTNode.copySubtree(target, getExpression())); if (this.ast.apiLevel >= AST.JLS3_INTERNAL) { result.typeArguments().addAll(ASTNode.copySubtrees(target, typeArguments())); } result.arguments().addAll(ASTNode.copySubtrees(target, arguments())); return result; }