Skip to main content



      Home
Home » Language IDEs » Java Development Tools (JDT) » "implements/overrides" annotation line number
"implements/overrides" annotation line number [message #250393] Sat, 29 December 2007 08:50 Go to next message
Eclipse UserFriend
Hello,
I need to find out programmatically where are the annotations which
are represented as a little green triangle (the ones that tell the user
that the method is overriding another method). Does anyone know what
exactly are those triangles, how does Eclipse create them and if their
line number is accessible to a plugin developer ?
Thank you very much,
George
Re: "implements/overrides" annotation line number [message #250490 is a reply to message #250393] Mon, 07 January 2008 11:49 Go to previous message
Eclipse UserFriend
George Ganea wrote:

> Hello,
> I need to find out programmatically where are the annotations which
> are represented as a little green triangle (the ones that tell the user
> that the method is overriding another method). Does anyone know what
> exactly are those triangles,

They tell you that the method overrides/implements another method.

> how does Eclipse create them

See org.eclipse.jdt.internal.ui.javaeditor.OverrideIndicatorMana ger.

> and if their
> line number is accessible to a plugin developer ?

If you have the annotation at hand you can call
org.eclipse.jface.text.source.IAnnotationModel.getPosition(A nnotation)
to get the position. From there you can get the line number using
org.eclipse.jface.text.IDocument.getLineOfOffset(int).

Dani

> Thank you very much,
> George
>
Previous Topic:JDT refactor detele my extra files
Next Topic:AST for other languages
Goto Forum:
  


Current Time: Wed Apr 30 03:56:41 EDT 2025

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

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

Back to the top