本文整理了Java中java.util.TreeSet.removeAll()
方法的一些代码示例,展示了TreeSet.removeAll()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。TreeSet.removeAll()
方法的具体详情如下:
包路径:java.util.TreeSet
类名称:TreeSet
方法名:removeAll
暂无
代码示例来源:origin: wdullaer/MaterialDateTimePicker
@NonNull private TreeSet<Timepoint> getExclusiveSelectableTimes(@NonNull TreeSet<Timepoint> selectable, @NonNull TreeSet<Timepoint> disabled) {
TreeSet<Timepoint> output = new TreeSet<>(selectable);
output.removeAll(disabled);
return output;
}
代码示例来源:origin: apache/geode
@Override
public boolean removeAll(Collection c) {
if (c instanceof StructSet) {
return removeAll((StructSet) c);
}
return super.removeAll(c);
}
代码示例来源:origin: lealone/Lealone
private void removeUnusedChunks(TreeSet<Long> removedPages) {
int size = removedPages.size();
for (BTreeChunk c : findUnusedChunks(removedPages)) {
c.fileStorage.close();
c.fileStorage.delete();
chunks.remove(c.id);
chunkIds.clear(c.id);
removedPages.removeAll(c.pagePositions);
}
if (size > removedPages.size()) {
writeChunkMetaData(lastChunk.id, removedPages);
}
}
代码示例来源:origin: google/error-prone
unsupportedClasses.removeAll(support.allowedClasses);
unsupportedClasses.addAll(support.bannedClasses);
support.allowedClasses.forEach(unsupportedMembers::removeAll);
代码示例来源:origin: apache/activemq
gcCandidateSet.removeAll(new TreeSet<Integer>(gcCandidateSet.tailSet(lastUpdate.getDataFileId())));
gcCandidateSet.removeAll(journalFilesBeingReplicated);
代码示例来源:origin: org.apache.poi/poi-ooxml
trackedCols.removeAll(overlapping);
for (CTCol existing : overlapping) {
代码示例来源:origin: spotbugs/spotbugs
notInitializedInConstructors.retainAll(data.writtenNonNullFields);
notInitializedInConstructors.retainAll(data.assumedNonNull.keySet());
notInitializedInConstructors.removeAll(data.writtenInConstructorFields);
notInitializedInConstructors.removeAll(data.writtenInInitializationFields);
readOnlyFields.removeAll(data.writtenFields);
nullOnlyFields.removeAll(data.writtenNonNullFields);
readOnlyFields.removeAll(assumeReflective);
nullOnlyFields.removeAll(assumeReflective);
notInitializedInConstructors.removeAll(assumeReflective);
代码示例来源:origin: ankidroid/Anki-Android
boolean changed = false;
if (mCurrentTags.containsAll(mTagsArrayAdapter.mTagsList)) {
mCurrentTags.removeAll(mTagsArrayAdapter.mTagsList);
changed = true;
} else {
代码示例来源:origin: geotools/geotools
public void addRange(Range<T> range) {
if (range.isEmpty()) {
return;
}
List<Range<T>> overlapping = getOverlappingRanges(range);
if (overlapping != null && !overlapping.isEmpty()) {
ranges.removeAll(overlapping);
Range combined = range;
for (Range r : overlapping) {
combined = combined.union(r);
}
ranges.add(combined);
} else {
ranges.add(range);
}
}
代码示例来源:origin: apache/accumulo
static synchronized void listInstances(String keepers, boolean printAll, boolean printErrors) {
errors = 0;
System.out.println("INFO : Using ZooKeepers " + keepers);
ZooReader rdr = new ZooReader(keepers, ZOOKEEPER_TIMER_MILLIS);
ZooCache cache = new ZooCache(keepers, ZOOKEEPER_TIMER_MILLIS);
TreeMap<String,UUID> instanceNames = getInstanceNames(rdr, printErrors);
System.out.println();
printHeader();
for (Entry<String,UUID> entry : instanceNames.entrySet()) {
printInstanceInfo(cache, entry.getKey(), entry.getValue(), printErrors);
}
TreeSet<UUID> instancedIds = getInstanceIDs(rdr, printErrors);
instancedIds.removeAll(instanceNames.values());
if (printAll) {
for (UUID uuid : instancedIds) {
printInstanceInfo(cache, null, uuid, printErrors);
}
} else if (instancedIds.size() > 0) {
System.out.println();
System.out.println("INFO : " + instancedIds.size()
+ " unamed instances were not printed, run with --print-all to see all instances");
} else {
System.out.println();
}
if (!printErrors && errors > 0) {
System.err.println(
"WARN : There were " + errors + " errors, run with --print-errors to see more info");
}
}
代码示例来源:origin: geogebra/geogebra
/**
*
* @return list of undefined variables (repeats removed)
*/
public TreeSet<String> getResult() {
tree.removeAll(localTree);
return tree;
}
代码示例来源:origin: org.apache.openjpa/openjpa-all
@Override
public boolean removeAll(Collection paramCollection) {
if (_directAccess) {
return super.removeAll(paramCollection);
}
return ProxyCollections.removeAll(this, paramCollection);
}
代码示例来源:origin: org.apache.openjpa/openjpa-kernel
@Override
public boolean removeAll(Collection paramCollection) {
if (_directAccess) {
return super.removeAll(paramCollection);
}
return ProxyCollections.removeAll(this, paramCollection);
}
代码示例来源:origin: org.apache.openejb.patch/openjpa
@Override
public boolean removeAll(Collection paramCollection) {
if (_directAccess) {
return super.removeAll(paramCollection);
}
return ProxyCollections.removeAll(this, paramCollection);
}
代码示例来源:origin: org.apache.openejb.patch/openjpa-kernel
@Override
public boolean removeAll(Collection paramCollection) {
if (_directAccess) {
return super.removeAll(paramCollection);
}
return ProxyCollections.removeAll(this, paramCollection);
}
代码示例来源:origin: org.apache.geode/gemfire-core
@Override
public boolean removeAll(Collection c) {
if (c instanceof StructSet) {
return removeAll((StructSet) c);
}
return super.removeAll(c);
}
代码示例来源:origin: usc-isi-i2/Web-Karma
/**
* @param e steiner edge to be removed
*/
public void deleteEdge(SteinerEdge e){
Set<SteinerEdge> badEdges= new TreeSet<>();
for(SteinerEdge e1: edges)
if(e1.sinkNode.equals(e.sinkNode)&& e1.sourceNode.equals(e.sourceNode))
badEdges.add(e1);
edges.removeAll(badEdges);
}
代码示例来源:origin: themadcreator/rabinfingerprint
/**
* Computes (this ^ that) in GF(2^k)
*/
public Polynomial xor(Polynomial that) {
TreeSet<BigInteger> dgrs0 = this.createDegreesCollectionCopy();
dgrs0.removeAll(that.degrees);
TreeSet<BigInteger> dgrs1 = that.createDegreesCollectionCopy();
dgrs1.removeAll(this.degrees);
dgrs1.addAll(dgrs0);
return new Polynomial(dgrs1);
}
代码示例来源:origin: org.kill-bill.commons/killbill-queue
public void markProcessedNotifications(final List<NotificationEventModelDao> toBeremoved, final List<NotificationEventModelDao> toBeAdded) {
synchronized (notifications) {
notifications.removeAll(toBeremoved);
notifications.addAll(toBeAdded);
}
}
代码示例来源:origin: org.eclipse.scout.rt/org.eclipse.scout.rt.client
@Override
public void deselectRows(List<? extends ITableRow> rows) {
rows = resolveRows(rows);
if (CollectionUtility.hasElements(rows)) {
TreeSet<ITableRow> newSelection = new TreeSet<>(new RowIndexComparator());
newSelection.addAll(m_selectedRows);
if (newSelection.removeAll(rows)) {
m_selectedRows = new ArrayList<>(newSelection);
fireRowsSelected(m_selectedRows);
}
}
}
内容来源于网络,如有侵权,请联系作者删除!