* accumulated deltas, and if the tree is not already locked it
* becomes a blocking call.
*/
workspace.run(new IWorkspaceRunnable() {
public void run(final IProgressMonitor worspaceMonitor) throws CoreException {
ISavedState savedState = null;
try {
//add the save participant for this bundle
savedState = ResourcesPlugin.getWorkspace().addSaveParticipant(
JSPCorePlugin.plugin.getBundle().getSymbolicName(), new SaveParticipant());
} catch (CoreException e) {
Logger.logException("JSP Core Plugin failed at loading previously saved state." + //$NON-NLS-1$
" All componenets dependent on this state will start as if first workspace load.", e); //$NON-NLS-1$
}
//if there is a saved state start up using that, else start up cold
if(savedState != null) {
try {
Thread.currentThread().setPriority(Thread.MIN_PRIORITY);
} finally {
savedState.processResourceChangeEvents(new IResourceChangeListener() {
/**
* @see org.eclipse.core.resources.IResourceChangeListener#resourceChanged(org.eclipse.core.resources.IResourceChangeEvent)
*/
public void resourceChanged(IResourceChangeEvent event) {
JSPIndexManager.getDefault().start(event.getDelta(), worspaceMonitor);