java.util.LinkedList.removeAll()方法的使用及代码示例

x33g5p2x  于2022-01-17 转载在 其他  
字(5.3k)|赞(0)|评价(0)|浏览(250)

本文整理了Java中java.util.LinkedList.removeAll()方法的一些代码示例,展示了LinkedList.removeAll()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。LinkedList.removeAll()方法的具体详情如下:
包路径:java.util.LinkedList
类名称:LinkedList
方法名:removeAll

LinkedList.removeAll介绍

暂无

代码示例

代码示例来源:origin: hankcs/HanLP

  1. @Override
  2. public boolean removeAll(Collection<?> c)
  3. {
  4. return pipeList.removeAll(c);
  5. }

代码示例来源:origin: apache/hbase

  1. private void swapSuffix(List<? extends Segment> suffix, ImmutableSegment segment,
  2. boolean closeSegmentsInSuffix) {
  3. pipeline.removeAll(suffix);
  4. if(segment != null) pipeline.addLast(segment);
  5. // During index merge we won't be closing the segments undergoing the merge. Segment#close()
  6. // will release the MSLAB chunks to pool. But in case of index merge there wont be any data copy
  7. // from old MSLABs. So the new cells in new segment also refers to same chunks. In case of data
  8. // compaction, we would have copied the cells data from old MSLAB chunks into a new chunk
  9. // created for the result segment. So we can release the chunks associated with the compacted
  10. // segments.
  11. if (closeSegmentsInSuffix) {
  12. for (Segment itemInSuffix : suffix) {
  13. itemInSuffix.close();
  14. }
  15. }
  16. }

代码示例来源:origin: apache/geode

  1. /**
  2. * Remove all the specified pending requests.
  3. * <p>
  4. * Caller must synchronize on this grant token.
  5. *
  6. * @param requestsToRemove the pending requests to remove guarded.By this
  7. */
  8. private void removeRequests(Collection requestsToRemove) {
  9. if (!requestsToRemove.isEmpty()) {
  10. synchronized (this) {
  11. this.pendingRequests.removeAll(requestsToRemove);
  12. }
  13. this.dlock.getStats().incPendingRequests(-requestsToRemove.size());
  14. }
  15. }

代码示例来源:origin: apache/incubator-pinot

  1. segmentsToAdd.removeAll(currentCoveredSegments);

代码示例来源:origin: apache/ignite

  1. delimQueue.removeAll(delimQueue.subList(replaceIdx, delimQueue.size()));

代码示例来源:origin: apache/geode

  1. suspendQueue.removeAll(timeouts);

代码示例来源:origin: apache/hbase

  1. } else {
  2. finished.addAll(local_finished);
  3. outstanding.removeAll(local_finished);
  4. LOG.debug(local_finished.size() + " outstanding splits finished");
  5. Thread.sleep(30 * 1000);
  6. } else {
  7. outstanding.removeAll(finished);
  8. for (Pair<byte[], byte[]> region : finished) {
  9. splitOut.writeChars("- " + splitAlgo.rowToStr(region.getFirst())

代码示例来源:origin: org.netbeans.api/org-openide-nodes

  1. @Override public boolean add(T e) {
  2. if (cancelled || Thread.interrupted()) {
  3. throw new Stop();
  4. }
  5. super.add(e);
  6. LinkedList<Object> newKeys = new LinkedList<Object>(this);
  7. Node n = factory.getWaitNode();
  8. if (n != null) {
  9. newKeys.add(n);
  10. }
  11. newKeys.removeAll(Collections.singleton(null)); // #206958
  12. if (newKeys.size() > minimalCount) {
  13. setKeys(newKeys);
  14. }
  15. return true;
  16. }
  17. // #206556 Y02 - could override other mutator methods if ever needed

代码示例来源:origin: io.snappydata/gemfire-jgroups

  1. /**
  2. * removes all the members contained in v from this membership
  3. *
  4. * @param v - a vector containing all the members to be removed
  5. */
  6. public void remove(Collection v) {
  7. if(v != null) {
  8. synchronized(members) {
  9. members.removeAll(v);
  10. }
  11. }
  12. }

代码示例来源:origin: com.sshtools/maverick-common

  1. public synchronized void removeEntry(KeyEntry... keys) {
  2. List<KeyEntry> toRemove = Arrays.asList(keys);
  3. keyEntries.removeAll(toRemove);
  4. revokedEntries.removeAll(toRemove);
  5. entries.removeAll(toRemove);
  6. for(Map.Entry<SshPublicKey, List<KeyEntry>> entry : entriesByPublicKey.entrySet()) {
  7. entry.getValue().removeAll(toRemove);
  8. }
  9. certificateAuthorities.removeAll(toRemove);
  10. }

代码示例来源:origin: ontop/ontop

  1. @Override
  2. public boolean removeAll(Collection<?> c) {
  3. boolean r = super.removeAll(c);
  4. riseListChanged();
  5. return r;
  6. }

代码示例来源:origin: org.apache.openjpa/openjpa-all

  1. @Override
  2. public boolean removeAll(Collection paramCollection) {
  3. if (_directAccess) {
  4. return super.removeAll(paramCollection);
  5. }
  6. return ProxyCollections.removeAll(this, paramCollection);
  7. }

代码示例来源:origin: org.apache.openejb.patch/openjpa-kernel

  1. @Override
  2. public boolean removeAll(Collection paramCollection) {
  3. if (_directAccess) {
  4. return super.removeAll(paramCollection);
  5. }
  6. return ProxyCollections.removeAll(this, paramCollection);
  7. }

代码示例来源:origin: it.unibz.inf.ontop/ontop-model

  1. @Override
  2. public boolean removeAll(Collection<?> c) {
  3. boolean r = super.removeAll(c);
  4. riseListChanged();
  5. return r;
  6. }

代码示例来源:origin: org.apache.openejb.patch/openjpa

  1. @Override
  2. public boolean removeAll(Collection paramCollection) {
  3. if (_directAccess) {
  4. return super.removeAll(paramCollection);
  5. }
  6. return ProxyCollections.removeAll(this, paramCollection);
  7. }

代码示例来源:origin: org.apache.openjpa/openjpa-kernel

  1. @Override
  2. public boolean removeAll(Collection paramCollection) {
  3. if (_directAccess) {
  4. return super.removeAll(paramCollection);
  5. }
  6. return ProxyCollections.removeAll(this, paramCollection);
  7. }

代码示例来源:origin: RS485/LogisticsPipes

  1. public void removeAll(List<E> orders) {
  2. list.removeAll(orders);
  3. for(E order:orders) {
  4. elemRemove(order);
  5. }
  6. }

代码示例来源:origin: it.unibz.inf.ontop/ontop-obdalib-core

  1. @Override
  2. public boolean removeAll(Collection<?> c) {
  3. boolean r = super.removeAll(c);
  4. riseListChanged();
  5. return r;
  6. }

代码示例来源:origin: shunfei/indexr

  1. @Override
  2. public Set<Attribute> producedAttributes() {
  3. LinkedList<NamedExpression> resultExpressionsCopy = new LinkedList<>(resultExpressions);
  4. resultExpressionsCopy.removeAll(groupingExpressions);
  5. return concatToSet(aggregateAttributes,
  6. mapToList(resultExpressionsCopy, NamedExpression::toAttribute),
  7. aggregateBufferAttributes);
  8. }

代码示例来源:origin: BiglySoftware/BiglyBT

  1. protected void deregisterHelper( UploadHelper helper ) {
  2. try { next_optimistics_mon.enter();
  3. helpers.remove( helper );
  4. boolean rem = next_optimistics.removeAll( Collections.singleton( helper ) );
  5. if( !rem ) Debug.out( "!rem" );
  6. }
  7. finally { next_optimistics_mon.exit(); }
  8. }

相关文章