public void removeAll(Collection<PrioritizedSplitRunner> splits) { lock.lock(); try { for (PriorityQueue<PrioritizedSplitRunner> level : levelWaitingSplits) { level.removeAll(splits); } } finally { lock.unlock(); } }
@Override public boolean removeAll(Collection<?> c) { return queue.removeAll(c); }
q.removeAll(Collections.singletonList(i)); q.add(i);
@Override public boolean removeAll(Collection<?> c) { this.best = null; return this.queue.removeAll(c); }
public void removeAll(Collection<PrioritizedSplitRunner> splits) { lock.lock(); try { for (PriorityQueue<PrioritizedSplitRunner> level : levelWaitingSplits) { level.removeAll(splits); } } finally { lock.unlock(); } }
public void removeAll(Collection<PrioritizedSplitRunner> splits) { lock.lock(); try { for (PriorityQueue<PrioritizedSplitRunner> level : levelWaitingSplits) { level.removeAll(splits); } } finally { lock.unlock(); } }
@Override public boolean removeAll(Collection paramCollection) { if (_directAccess) { return super.removeAll(paramCollection); } return ProxyCollections.removeAll(this, paramCollection); }
@Override public boolean removeAll(Collection paramCollection) { if (_directAccess) { return super.removeAll(paramCollection); } return ProxyCollections.removeAll(this, paramCollection); }
@Override public boolean retainAll(Collection<?> c) { ArrayList<StableWrapper<E>> removeThese = new ArrayList<>(); for (StableWrapper<E> swe : queue) { if (!c.contains(swe.object)) { removeThese.add(swe); } } if (removeThese.isEmpty()) { return false; } if (queue.size() == removeThese.size()) { counter = 0; } return queue.removeAll(removeThese); }
@Override public boolean removeAll(Collection paramCollection) { if (_directAccess) { return super.removeAll(paramCollection); } return ProxyCollections.removeAll(this, paramCollection); }
@Override public boolean removeAll(Collection paramCollection) { if (_directAccess) { return super.removeAll(paramCollection); } return ProxyCollections.removeAll(this, paramCollection); }
/** * Write all the queued items to the writer. */ public final void doWrites() { QueuedData[] slice = null; writeLock.lock(); try { slice = queue.toArray(new QueuedData[0]); if (queue.removeAll(Arrays.asList(slice))) { log.debug("Queued writes transfered, count: {}", slice.length); } } finally { writeLock.unlock(); } // sort Arrays.sort(slice); // write doWrites(slice); }
/** * Write all the queued items to the writer. */ public final void doWrites() { QueuedMediaData[] slice = null; writeLock.lock(); try { slice = queue.toArray(new QueuedMediaData[0]); if (queue.removeAll(Arrays.asList(slice))) { log.debug("Queued writes transfered, count: {}", slice.length); } } finally { writeLock.unlock(); } // sort Arrays.sort(slice); // write doWrites(slice); }
private void connectionRemoved(RestConnectionPattern con) { ConnectionConfiguration connection = connections.remove(con.model); if (connection == null) { logger.warn("Connection removed callback for non-existent configuration {}",con); return; } tasks.removeAll(connection.getTasks()); connection.close(); resetTimer(); }
/** * Method to remove a Collection of elements. * @param c The collection to remove * @return Whether they were removed successfully. **/ public synchronized boolean removeAll(java.util.Collection c) { makeDirty(); if (useCache) { loadFromStore(); } boolean delegateSuccess = delegate.removeAll(c); boolean backingSuccess = false; if (backingStore != null) { try { backingSuccess = backingStore.removeAll(ownerSM, c); } catch (JDODataStoreException dse) { backingSuccess = false; } } return (backingStore != null ? backingSuccess : delegateSuccess); }