Skip to main content



      Home
Home » Language IDEs » Java Development Tools (JDT) » Name of anonymous class declaration
Name of anonymous class declaration [message #211531] Wed, 03 August 2005 21:12 Go to next message
Eclipse UserFriend
Hello,
I have an
AnonymousClassDeclaration object. How can I get a string with the name of
this anonymous class declaration.I expect something like ParentClass$1.

The number value ($1 or simple 1) would be enough for me!

(What is the use of AnonymousClassDeclaration.getLocationInParent() ??)
Thanks for help!
Re: Name of anonymous class declaration [message #211806 is a reply to message #211531] Mon, 08 August 2005 11:35 Go to previous message
Eclipse UserFriend
Use resolveTypeBinding on the AST node and call getBinaryName on the
obtained binding

Cheers

Tobias

"Przemyslaw" <Przemek_d@gmx.de> wrote in message
news:dcrq48$e5$1@news.eclipse.org...
> Hello,
> I have an
> AnonymousClassDeclaration object. How can I get a string with the name of
> this anonymous class declaration.I expect something like ParentClass$1.
>
> The number value ($1 or simple 1) would be enough for me!
>
> (What is the use of AnonymousClassDeclaration.getLocationInParent() ??)
> Thanks for help!
>
Previous Topic:EAR file on classpath?
Next Topic:Debug editor doesn't select current line of code...
Goto Forum:
  


Current Time: Wed May 07 13:39:29 EDT 2025

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

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

Back to the top