Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[jdt-dev] How to apply an IJavaElementDelta to a Compilation Unit

Hi

    The Eclipse jdt help sugests add a IElementChangeListener to respond to
changes in Java Elements as the following example:

JavaCore.addElementChangedListener(new MyJavaElementChangeReporter());public
class MyJavaElementChangeReporter implements IElementChangedListener {
      public void elementChanged(ElementChangedEvent event) {
         IJavaElementDelta delta= event.getDelta();
         if (delta != null) {
            System.out.println("delta received: ");
            System.out.print(delta);
         }
      }
   }    I need to get the IJavaElementDelta received and so reproduce the
event in a second ICompilationUnit. Ho can i do this ?


Tanks !

Leandro Pfleger de Aguiar


Back to the top