Class DeltaProcessor
java.lang.Object
org.aspectj.org.eclipse.jdt.internal.core.DeltaProcessor
This class is used by
JavaModelManager
to convert
IResourceDelta
s into IJavaElementDelta
s.
It also does some processing on the JavaElement
s involved
(e.g. closing them or updating classpaths).
High level summary of what the delta processor does:
- reacts to resource deltas
- fires corresponding Java element deltas
- deltas also contain non-Java resources changes
- updates the model to reflect the Java element changes
- notifies type hierarchies of the changes
- triggers indexing of the changed elements
- refresh external archives (delta, model update, indexing)
- is thread safe (one delta processor instance per thread, see DeltaProcessingState#resourceChanged(...))
- handles .classpath changes (updates package fragment roots, update project references, validate classpath (.classpath format, resolved classpath, cycles))
-
Nested Class Summary
-
Field Summary
Modifier and TypeFieldDescriptionstatic boolean
static int
int
static boolean
static boolean
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
checkExternalArchiveChanges(IJavaElement[] elementsScope, org.eclipse.core.runtime.IProgressMonitor monitor)
void
fire(IJavaElementDelta customDelta, int eventType)
void
flush()
static long
getTimeStamp(File file)
void
notifyAndFire(IJavaElementDelta delta)
void
void
void
resourceChanged(org.eclipse.core.resources.IResourceChangeEvent event)
boolean
updateCurrentDeltaAndIndex(org.eclipse.core.resources.IResourceDelta delta, int elementType, DeltaProcessor.RootInfo rootInfo)
void
updateJavaModel(IJavaElementDelta customDelta)
-
Field Details
-
DEBUG
public static boolean DEBUG -
VERBOSE
public static boolean VERBOSE -
PERF
public static boolean PERF -
DEFAULT_CHANGE_EVENT
public static final int DEFAULT_CHANGE_EVENT- See Also:
- Constant Field Values
-
javaModelDeltas
-
reconcileDeltas
-
projectCachesToReset
-
oldRoots
-
overridenEventType
public int overridenEventType
-
-
Constructor Details
-
DeltaProcessor
-
-
Method Details
-
getTimeStamp
-
checkExternalArchiveChanges
public void checkExternalArchiveChanges(IJavaElement[] elementsScope, org.eclipse.core.runtime.IProgressMonitor monitor) throws JavaModelException- Throws:
JavaModelException
-
flush
public void flush() -
fire
-
resetProjectCaches
public void resetProjectCaches() -
registerJavaModelDelta
-
resourceChanged
public void resourceChanged(org.eclipse.core.resources.IResourceChangeEvent event) -
notifyAndFire
-
updateCurrentDeltaAndIndex
public boolean updateCurrentDeltaAndIndex(org.eclipse.core.resources.IResourceDelta delta, int elementType, DeltaProcessor.RootInfo rootInfo) -
updateJavaModel
-