Lines Matching defs:queue

42  * automatically removed from the work queue until its delay elapses.
57 * {@code corePoolSize} threads and an unbounded queue, adjustments
113 * 2. Using a custom queue (DelayedWorkQueue), a variant of
142 * True if ScheduledFutureTask.cancel should remove from queue.
173 * Index into delay queue, to support faster cancellation.
294 * is shut down, rejects the task. Otherwise adds task to queue
334 * Cancels and clears the queue of all tasks that should not be run
455 * because the thread bounds and queue capacities are reached
475 * because the thread bounds and queue capacities are reached
504 * Constrains the values of all delays in the queue to be within
608 * Note that inspections of the queue and of the list returned by
720 * removed from the work queue at time of cancellation. This value is
733 * removed from the work queue at time of cancellation. This value is
737 * from the queue
770 * from the task queue upon return from this method.
795 * Returns the task queue used by this executor. Access to the
796 * task queue is intended primarily for debugging and monitoring.
797 * This queue may be in active use. Retrieving the task queue
800 * <p>Each element of this queue is a {@link ScheduledFuture}.
806 * <p>Iteration over this queue is <em>not</em> guaranteed to traverse
809 * @return the task queue
816 * Specialized delay queue. To mesh with TPE declarations, this
831 * before clearing. But because the queue may also hold
841 * appear at most once in the queue (this need not be true for
847 private RunnableScheduledFuture<?>[] queue =
854 * queue. This variant of the Leader-Follower pattern
861 * interim. Whenever the head of the queue is replaced with a
872 * head of the queue or a new thread may need to become leader.
891 RunnableScheduledFuture<?> e = queue[parent];
894 queue[k] = e;
898 queue[k] = key;
910 RunnableScheduledFuture<?> c = queue[child];
912 if (right < size && c.compareTo(queue[right]) > 0)
913 c = queue[child = right];
916 queue[k] = c;
920 queue[k] = key;
928 int oldCapacity = queue.length;
932 queue = Arrays.copyOf(queue, newCapacity);
944 if (i >= 0 && i < size && queue[i] == x)
948 if (x.equals(queue[i]))
973 setIndex(queue[i], -1);
975 RunnableScheduledFuture<?> replacement = queue[s];
976 queue[s] = null;
979 if (queue[i] == replacement)
1010 return queue[0];
1024 if (i >= queue.length)
1028 queue[0] = e;
1033 if (queue[0] == e) {
1063 RunnableScheduledFuture<?> x = queue[s];
1064 queue[s] = null;
1075 RunnableScheduledFuture<?> first = queue[0];
1089 RunnableScheduledFuture<?> first = queue[0];
1112 if (leader == null && queue[0] != null)
1125 RunnableScheduledFuture<?> first = queue[0];
1154 if (leader == null && queue[0] != null)
1165 RunnableScheduledFuture<?> t = queue[i];
1167 queue[i] = null;
1183 RunnableScheduledFuture<?> first = queue[0];
1236 return Arrays.copyOf(queue, size, Object[].class);
1248 return (T[]) Arrays.copyOf(queue, size, a.getClass());
1249 System.arraycopy(queue, 0, a, 0, size);
1259 return new Itr(Arrays.copyOf(queue, size));