Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » Java Development Tools (JDT) » IMethodBinding from MethodInvocation(How to get it?)
IMethodBinding from MethodInvocation [message #555185] Wed, 25 August 2010 18:18 Go to next message
Caio Lima is currently offline Caio LimaFriend
Messages: 6
Registered: March 2010
Junior Member
Then guys.

I'm trying to get IMethodBinding from a MethodInvocation

My syntax is:
//a visitor class
public boolean visit(MethodInvocation node){
    IMethodBindings teste=node.resolveMethodBindings();
    super.visit(node);
}

/...

but, every time it return me null.

Then...How can i get the Bindings?

I'm thank you

Re: IMethodBinding from MethodInvocation [message #555365 is a reply to message #555185] Thu, 26 August 2010 12:31 Go to previous messageGo to next message
Satyam Kandula is currently offline Satyam KandulaFriend
Messages: 444
Registered: July 2009
Senior Member
Are you calling ASTParser#setResolveBindings(true) before createASTs()
Re: IMethodBinding from MethodInvocation [message #555513 is a reply to message #555185] Thu, 26 August 2010 21:24 Go to previous messageGo to next message
Caio Lima is currently offline Caio LimaFriend
Messages: 6
Registered: March 2010
Junior Member
How can i do it?

Re: IMethodBinding from MethodInvocation [message #555529 is a reply to message #555513] Fri, 27 August 2010 03:42 Go to previous message
Satyam Kandula is currently offline Satyam KandulaFriend
Messages: 444
Registered: July 2009
Senior Member
I believe you should be calling creareASTs() before getting to the visit functions. Before the call to createAST on the ASTParser object, just call setResolveBindings(true) on ASTParser. Look at http://www.eclipse.org/articles/article.php?file=Article-Jav aCodeManipulation_AST/index.html for more information
Previous Topic:Shortcuts (Keys) CSV
Next Topic:eclipse doesn't update metadata/index after JAR change
Goto Forum:
  


Current Time: Fri Apr 26 02:54:28 GMT 2024

Powered by FUDForum. Page generated in 0.03227 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top