public void addFinishedTarget(Target target) {
   // 向finishedTargets队列中加入一个任务
   synchronized (finishedTargets) {
     finishedTargets.notify();
     finishedTargets.add(target);
   }
 }
Пример #2
0
 void add(Target t) {
   synchronized (pending) {
     pending.add(t);
     pending.notify();
   }
 }