@Override
 protected IStatus run(final IProgressMonitor monitor) {
   while (true) {
     Task task;
     synchronized (fTasksLock) {
       final IModelElement element = (!fTaskQueue.isEmpty()) ? fTaskQueue.removeFirst() : null;
       if (element == null || fStop) {
         fWorking = false;
         return Status.OK_STATUS;
       }
       fWorking = true;
       task = fTaskDetail.remove(element);
     }
     try {
       task.run();
     } catch (final Throwable e) {
       LTKCorePlugin.log(
           new Status(
               IStatus.ERROR,
               LTK.PLUGIN_ID,
               -1,
               "An error occurred when firing model event for "
                   + fModelManager.getModelTypeId()
                   + ".", //$NON-NLS-1$
               e));
     }
   }
 }
 @Override
 public void handleException(final Throwable e) {
   LTKCorePlugin.log(
       new Status(
           IStatus.ERROR,
           LTK.PLUGIN_ID,
           -1,
           "An error occured while notifying an ElementChangedListener.",
           e)); //$NON-NLS-1$
 }