[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[news.eclipse.tools.jdt] Re: How to get the reference of the Java Element undermodification on the JavaEditor

You need to register using a POST_RECONCILE event mask. Note that POST_CHANGE events won't include a fine grained description (see IJavaElementDelta#F_FINE_GRAINED) of the change, only POST_RECONCILE events contain such a fine grained description (this is what the Outline view listens to).

Jerome

PS: No need to spam the dev lists to get a reply :-)

Prabhakar.S wrote:
Hi all,

Iam preparing a plugin which listens to the Java Element under modification and carries out a business processing on the modifed Java Element.

I registered with JavaCore for IElementChangedListener.
I get either ICompilationUnit or IType reference when ever i modify the java source.
I want to get the IMethod or IField reference of the method or field which ever i modify.
How to solve this.


The Outline view tree selection is synchronised with the element under edit in the JavaEditor.
How does Outline view listens to the element under edit in the JavaEditor.


    Please do reply as early as possible.

    Thanks in advance.
Regards,

Prabhakar.S