Beispiel #1
0
 public void done(IJobChangeEvent event) {
   JobsManager.getInstance().removeCanceled(event.getJob());
   synchronized (jobs) {
     boolean reschedule = TeslaSWTAccess.getJobEventReSchedule(event) && state;
     getOrCreateJobInfo(event.getJob()).done(reschedule);
     if (needDisable && isJoinEmpty()) {
       disable();
     }
     if (!reschedule) jobs.remove(event.getJob());
   }
 }
Beispiel #2
0
 public void scheduled(IJobChangeEvent event) {
   if (!state) {
     return;
   }
   JobInfo jobInfo = getOrCreateJobInfo(event.getJob());
   jobInfo.scheduled(event.getDelay());
   if (JobStatus.REQUIRED.equals(jobInfo.status)) {
     if (event.getJob().belongsTo(TeslaSWTAccess.getDecoratorManagerFamily())) {
       JobsManager.getInstance().nulifyTime(event.getJob());
     }
     if (jobInfo.rescheduleCounter < TeslaLimits.getJobNullifyRescheduleMaxValue()) {
       JobsManager.getInstance().nulifyTime(event.getJob());
     }
   }
 }
 public void done(IJobChangeEvent event) {
   if (event.getJob().belongsTo(fPDomManager)) {
     if (Job.getJobManager().find(fPDomManager).length == 0) {
       fPDomManager.fireStateChange(IndexerStateEvent.STATE_IDLE);
     }
   }
 }
Beispiel #4
0
 @Override
 public void scheduled(IJobChangeEvent event) {
   if (fixedTheJob) return;
   Job job = event.getJob();
   if (job == null) return;
   Class<? extends Job> jobClazz = job.getClass();
   if (!job.isSystem()
       && jobClazz
           .getName()
           .equals("org.eclipse.egit.core.internal.indexdiff.IndexDiffCacheEntry$5")) {
     try {
       Field field = InternalJob.class.getDeclaredField("flags");
       field.setAccessible(true);
       field.set(
           job, ((Integer) field.get(job)).intValue() | 0x0100 /*InternalJob.M_SYSTEM*/);
       if (log.isInfoEnabled()) {
         log.info("Made job '" + job + "' a system job.");
       }
       fixedTheJob = true;
     } catch (Exception e) {
       log.error(e.getMessage(), e);
     }
   }
 }
Beispiel #5
0
 public void sleeping(IJobChangeEvent event) {
   getOrCreateJobInfo(event.getJob()).sleeping();
 }
Beispiel #6
0
 public void awake(IJobChangeEvent event) {
   getOrCreateJobInfo(event.getJob()).awake();
 }
 @Override
 public void scheduled(IJobChangeEvent event) {
   if ("Local Waveform Release".equals(event.getJob().getName())) {
     jobScheduled = true;
   }
 }
 public void done(IJobChangeEvent event) {
   if (event.getJob() == runningJob) {
     runningJob = null;
   }
 }
 public void scheduled(IJobChangeEvent event) {
   if (event.getJob().belongsTo(fPDomManager)) {
     fPDomManager.fireStateChange(IndexerStateEvent.STATE_BUSY);
   }
 }