本文整理了Java中java.util.TreeSet.removeIf()
方法的一些代码示例,展示了TreeSet.removeIf()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。TreeSet.removeIf()
方法的具体详情如下:
包路径:java.util.TreeSet
类名称:TreeSet
方法名:removeIf
暂无
代码示例来源:origin: at.bestsolution.eclipse/org.eclipse.fx.core
/**
* Unregister an object
*
* @param object
* the object
*/
public synchronized void unregisterObject(T object) {
this.objectList.removeIf(r -> r.object == object);
}
代码示例来源:origin: visallo/vertexium
public void removeData(ExtendedDataRowId rowId) {
rows.removeIf(row -> row.getId().equals(rowId));
}
代码示例来源:origin: anba/es6draft
ids.removeIf(id -> id.startsWith("SystemV/"));
代码示例来源:origin: org.kie.workbench/kie-wb-common-dmn-client
public void removeChild(final DecisionNavigatorItem item) {
getChildren().removeIf(i -> i.getUUID().equals(item.getUUID()));
}
代码示例来源:origin: cc.redberry/rings
TreeSet<SyzygyPair<Term, Poly>> c = it.next();
c.removeIf(sPair -> dividesQ(newLeadTerm, sPair.syzygyGamma)
&& !Arrays.equals(sPair.fi == basis.get(sPair.i) ? lcm[sPair.i] : lcm(sPair.fi.lt().exponents, newLeadTerm.exponents), sPair.syzygyGamma.exponents)
&& !Arrays.equals(sPair.fj == basis.get(sPair.j) ? lcm[sPair.j] : lcm(sPair.fj.lt().exponents, newLeadTerm.exponents), sPair.syzygyGamma.exponents));
代码示例来源:origin: SmartDataAnalytics/DL-Learner
@Override
protected TreeSet<OWLClassExpression> getSubClassesImpl(OWLClassExpression ce) {
NodeSet<OWLClass> classes;
try {
classes = reasoner.getSubClasses(ce, true);
} catch (UnsupportedOperationException e) {
if (useFallbackReasoner) {
classes = fallbackReasoner.getSubClasses(ce, true);
} else {
throw e;
}
}
TreeSet<OWLClassExpression> subClasses = getFirstClasses(classes);
subClasses.remove(df.getOWLNothing());
// remove built-in entities sometimes returned as subclasses of
// owl:Thing
if (ce.isOWLThing()) {
subClasses.removeIf(_ce -> !_ce.isAnonymous() &&
_ce.asOWLClass().getIRI().isReservedVocabulary());
}
return subClasses;
}
代码示例来源:origin: cc.redberry/rings
/** remove redundant S-pairs using Hilbert function */
private static <Term extends AMonomial<Term>, Poly extends MonomialSetView<Term>>
HilbertUpdate updateWithHPS(HilbertSeries hilbertSeries,
HilbertSeries currentHPS,
GradedSyzygyTreeSet<Term, Poly> sPairs) {
if (currentHPS.equals(hilbertSeries))
// we are done
return new HilbertUpdate();
// since Mon(current) ⊆ Mon(ideal) we can use only numerators of HPS
int currentDegree = 0;
for (; ; ++currentDegree)
if (!hilbertSeries.initialNumerator.get(currentDegree).equals(currentHPS.initialNumerator.get(currentDegree)))
break;
Rational<BigInteger> delta = currentHPS.initialNumerator.get(currentDegree).subtract(hilbertSeries.initialNumerator.get(currentDegree));
assert delta.isIntegral() && delta.numerator().signum() > 0;
int hilbertDelta = delta.numerator().intValueExact();
// remove redundant S-pairs
final int mDegree = currentDegree;
int sizeBefore = sPairs.size();
sPairs.allSets().forEach(set -> set.removeIf(s -> s.degree() < mDegree));
return new HilbertUpdate(currentDegree, hilbertDelta, sizeBefore - sPairs.size());
}
内容来源于网络,如有侵权,请联系作者删除!