Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.port80.eclipse.jdt.graph
Class MethodReferenceASTVisitor  view MethodReferenceASTVisitor download MethodReferenceASTVisitor.java

java.lang.Object
  extended byorg.eclipse.jdt.core.dom.ASTVisitor
      extended bycom.port80.eclipse.jdt.graph.MethodReferenceASTVisitor

public class MethodReferenceASTVisitor
extends org.eclipse.jdt.core.dom.ASTVisitor

Find method referenced in a given CompilationUnit.


Nested Class Summary
static class MethodReferenceASTVisitor.Result
           
 
Field Summary
private static boolean DEBUG
           
private  MethodReferenceASTVisitor.Result fResult
           
private static java.lang.String NAME
           
private static boolean TERSE
           
 
Fields inherited from class org.eclipse.jdt.core.dom.ASTVisitor
 
Constructor Summary
MethodReferenceASTVisitor()
           
 
Method Summary
private  org.eclipse.jdt.core.dom.IMethodBinding addCall(org.eclipse.jdt.core.dom.Name node)
           
private  org.eclipse.jdt.core.dom.ITypeBinding addDeclaredType(org.eclipse.jdt.core.dom.Name node)
           
private  void evalQualifyingExpression(org.eclipse.jdt.core.dom.Expression expr)
           
 MethodReferenceASTVisitor.Result getResult()
           
private  void possibleTypeRefFound(org.eclipse.jdt.core.dom.Name node)
           
 void preVisit(org.eclipse.jdt.core.dom.ASTNode node)
          Visits the given AST node prior to the type-specific visit.
private  org.eclipse.jdt.core.dom.IMethodBinding resolveMethod(org.eclipse.jdt.core.dom.Name node)
           
private  org.eclipse.jdt.core.dom.ITypeBinding resolveType(org.eclipse.jdt.core.dom.Name node)
           
static MethodReferenceASTVisitor startAt(org.eclipse.jdt.core.dom.ASTNode root)
           
private  org.eclipse.jdt.core.dom.ITypeBinding typeRefFound(org.eclipse.jdt.core.dom.Name node)
          If a nested type is referenced, only the nested type is counted.
 boolean visit(org.eclipse.jdt.core.dom.ArrayType node)
          Visits the given type-specific AST node.
 boolean visit(org.eclipse.jdt.core.dom.ClassInstanceCreation node)
          Visits the given type-specific AST node.
 boolean visit(org.eclipse.jdt.core.dom.FieldAccess node)
          Visits the given type-specific AST node.
 boolean visit(org.eclipse.jdt.core.dom.MethodDeclaration node)
          Visits the given type-specific AST node.
 boolean visit(org.eclipse.jdt.core.dom.MethodInvocation node)
          Visits the given type-specific AST node.
 boolean visit(org.eclipse.jdt.core.dom.PackageDeclaration node)
          Visits the given type-specific AST node.
 boolean visit(org.eclipse.jdt.core.dom.QualifiedName node)
          Visits the given type-specific AST node.
 boolean visit(org.eclipse.jdt.core.dom.SimpleName node)
          Visits the given type-specific AST node.
 boolean visit(org.eclipse.jdt.core.dom.SimpleType node)
          Visits the given type-specific AST node.
 boolean visit(org.eclipse.jdt.core.dom.SuperConstructorInvocation node)
          Visits the given type-specific AST node.
 boolean visit(org.eclipse.jdt.core.dom.SuperMethodInvocation node)
          Visits the given type-specific AST node.
 boolean visit(org.eclipse.jdt.core.dom.ThisExpression node)
          Visits the given type-specific AST node.
 boolean visit(org.eclipse.jdt.core.dom.TypeDeclaration node)
          Visits the given type-specific AST node.
private  void visitChildren(java.util.List elements)
           
 
Methods inherited from class org.eclipse.jdt.core.dom.ASTVisitor
endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, endVisit, postVisit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NAME

private static final java.lang.String NAME
See Also:
Constant Field Values

DEBUG

private static final boolean DEBUG
See Also:
Constant Field Values

TERSE

private static final boolean TERSE
See Also:
Constant Field Values

fResult

private MethodReferenceASTVisitor.Result fResult
Constructor Detail

MethodReferenceASTVisitor

public MethodReferenceASTVisitor()
Method Detail

startAt

public static MethodReferenceASTVisitor startAt(org.eclipse.jdt.core.dom.ASTNode root)

getResult

public MethodReferenceASTVisitor.Result getResult()

addDeclaredType

private org.eclipse.jdt.core.dom.ITypeBinding addDeclaredType(org.eclipse.jdt.core.dom.Name node)

addCall

private org.eclipse.jdt.core.dom.IMethodBinding addCall(org.eclipse.jdt.core.dom.Name node)

resolveType

private org.eclipse.jdt.core.dom.ITypeBinding resolveType(org.eclipse.jdt.core.dom.Name node)

typeRefFound

private org.eclipse.jdt.core.dom.ITypeBinding typeRefFound(org.eclipse.jdt.core.dom.Name node)
If a nested type is referenced, only the nested type is counted. Its enclosing type is not counted.


possibleTypeRefFound

private void possibleTypeRefFound(org.eclipse.jdt.core.dom.Name node)

resolveMethod

private org.eclipse.jdt.core.dom.IMethodBinding resolveMethod(org.eclipse.jdt.core.dom.Name node)

visitChildren

private void visitChildren(java.util.List elements)

visit

public boolean visit(org.eclipse.jdt.core.dom.ArrayType node)
Description copied from class: org.eclipse.jdt.core.dom.ASTVisitor
Visits the given type-specific AST node.

The default implementation does nothing and return true. Subclasses may reimplement.


visit

public boolean visit(org.eclipse.jdt.core.dom.SimpleType node)
Description copied from class: org.eclipse.jdt.core.dom.ASTVisitor
Visits the given type-specific AST node.

The default implementation does nothing and return true. Subclasses may reimplement.


visit

public boolean visit(org.eclipse.jdt.core.dom.QualifiedName node)
Description copied from class: org.eclipse.jdt.core.dom.ASTVisitor
Visits the given type-specific AST node.

The default implementation does nothing and return true. Subclasses may reimplement.


visit

public boolean visit(org.eclipse.jdt.core.dom.PackageDeclaration node)
Description copied from class: org.eclipse.jdt.core.dom.ASTVisitor
Visits the given type-specific AST node.

The default implementation does nothing and return true. Subclasses may reimplement.


visit

public boolean visit(org.eclipse.jdt.core.dom.ThisExpression node)
Description copied from class: org.eclipse.jdt.core.dom.ASTVisitor
Visits the given type-specific AST node.

The default implementation does nothing and return true. Subclasses may reimplement.


evalQualifyingExpression

private void evalQualifyingExpression(org.eclipse.jdt.core.dom.Expression expr)

visit

public boolean visit(org.eclipse.jdt.core.dom.ClassInstanceCreation node)
Description copied from class: org.eclipse.jdt.core.dom.ASTVisitor
Visits the given type-specific AST node.

The default implementation does nothing and return true. Subclasses may reimplement.


visit

public boolean visit(org.eclipse.jdt.core.dom.MethodInvocation node)
Description copied from class: org.eclipse.jdt.core.dom.ASTVisitor
Visits the given type-specific AST node.

The default implementation does nothing and return true. Subclasses may reimplement.


visit

public boolean visit(org.eclipse.jdt.core.dom.SuperConstructorInvocation node)
Description copied from class: org.eclipse.jdt.core.dom.ASTVisitor
Visits the given type-specific AST node.

The default implementation does nothing and return true. Subclasses may reimplement.


visit

public boolean visit(org.eclipse.jdt.core.dom.SuperMethodInvocation node)
Description copied from class: org.eclipse.jdt.core.dom.ASTVisitor
Visits the given type-specific AST node.

The default implementation does nothing and return true. Subclasses may reimplement.


visit

public boolean visit(org.eclipse.jdt.core.dom.FieldAccess node)
Description copied from class: org.eclipse.jdt.core.dom.ASTVisitor
Visits the given type-specific AST node.

The default implementation does nothing and return true. Subclasses may reimplement.


visit

public boolean visit(org.eclipse.jdt.core.dom.SimpleName node)
Description copied from class: org.eclipse.jdt.core.dom.ASTVisitor
Visits the given type-specific AST node.

The default implementation does nothing and return true. Subclasses may reimplement.


visit

public boolean visit(org.eclipse.jdt.core.dom.TypeDeclaration node)
Description copied from class: org.eclipse.jdt.core.dom.ASTVisitor
Visits the given type-specific AST node.

The default implementation does nothing and return true. Subclasses may reimplement.


visit

public boolean visit(org.eclipse.jdt.core.dom.MethodDeclaration node)
Description copied from class: org.eclipse.jdt.core.dom.ASTVisitor
Visits the given type-specific AST node.

The default implementation does nothing and return true. Subclasses may reimplement.


preVisit

public void preVisit(org.eclipse.jdt.core.dom.ASTNode node)
Description copied from class: org.eclipse.jdt.core.dom.ASTVisitor
Visits the given AST node prior to the type-specific visit. (before visit).

The default implementation does nothing. Subclasses may reimplement.