Klasse ModelUpdater
java.lang.Object
org.aspectj.org.eclipse.jdt.internal.core.ModelUpdater
This class is used by
JavaModelManager to update the JavaModel
based on some IJavaElementDeltas.-
Konstruktorübersicht
Konstruktoren -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungprotected voidaddToParentInfo(Openable child) Adds the given child handle to its parent's cache of children.protected static voidCloses the given element, which removes it from the cache of open elements.protected voidelementAdded(Openable element) Processing for an element that has been added: If the element is a project, do nothing, and do not process children, as when a project is created it does not yet have any natures - specifically a java nature.protected voidelementChanged(Openable element) Generic processing for elements with changed contents: The element is closed such that any subsequent accesses will re-open the element reflecting its new structure.protected voidelementRemoved(Openable element) Generic processing for a removed element: Close the element, removing its structure from the cache Remove the element from its parent's cache of children Add a REMOVED entry in the deltavoidConverts aIResourceDeltarooted in aWorkspaceinto the corresponding set ofIJavaElementDelta, rooted in the relevantJavaModels.protected voidremoveFromParentInfo(Openable child) Removes the given element from its parents cache of children.protected voidtraverseDelta(IJavaElementDelta delta, IPackageFragmentRoot root, IJavaProject project) Converts anIResourceDeltaand its children into the correspondingIJavaElementDeltas.
-
Konstruktordetails
-
ModelUpdater
public ModelUpdater()
-
-
Methodendetails
-
addToParentInfo
Adds the given child handle to its parent's cache of children. -
close
Closes the given element, which removes it from the cache of open elements. -
elementAdded
Processing for an element that has been added:- If the element is a project, do nothing, and do not process children, as when a project is created it does not yet have any natures - specifically a java nature.
- If the elemet is not a project, process it as added (see
basicElementAdded.
-
elementChanged
Generic processing for elements with changed contents:- The element is closed such that any subsequent accesses will re-open the element reflecting its new structure.
-
elementRemoved
Generic processing for a removed element:- Close the element, removing its structure from the cache
- Remove the element from its parent's cache of children
- Add a REMOVED entry in the delta
-
processJavaDelta
Converts aIResourceDeltarooted in aWorkspaceinto the corresponding set ofIJavaElementDelta, rooted in the relevantJavaModels. -
removeFromParentInfo
Removes the given element from its parents cache of children. If the element does not have a parent, or the parent is not currently open, this has no effect. -
traverseDelta
protected void traverseDelta(IJavaElementDelta delta, IPackageFragmentRoot root, IJavaProject project) Converts anIResourceDeltaand its children into the correspondingIJavaElementDeltas. Return whether the delta corresponds to a resource on the classpath. If it is not a resource on the classpath, it will be added as a non-java resource by the sender of this method.
-