本文整理匯總了Java中java.util.Spliterator.OfDouble方法的典型用法代碼示例。如果您正苦於以下問題:Java Spliterator.OfDouble方法的具體用法?Java Spliterator.OfDouble怎麽用?Java Spliterator.OfDouble使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類java.util.Spliterator
的用法示例。
在下文中一共展示了Spliterator.OfDouble方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: trySplit
import java.util.Spliterator; //導入方法依賴的package包/類
@Override
public Spliterator.OfDouble trySplit() {
splits++;
Spliterator.OfDouble prefix = psp.trySplit();
if (prefix != null)
prefixSplits++;
return prefix;
}
示例2: truncate
import java.util.Spliterator; //導入方法依賴的package包/類
@Override
default Node.OfDouble truncate(long from, long to, IntFunction<Double[]> generator) {
if (from == 0 && to == count())
return this;
long size = to - from;
Spliterator.OfDouble spliterator = spliterator();
Node.Builder.OfDouble nodeBuilder = Nodes.doubleBuilder(size);
nodeBuilder.begin(size);
for (int i = 0; i < from && spliterator.tryAdvance((DoubleConsumer) e -> { }); i++) { }
for (int i = 0; (i < size) && spliterator.tryAdvance((DoubleConsumer) nodeBuilder); i++) { }
nodeBuilder.end();
return nodeBuilder.build();
}
示例3: spliterator
import java.util.Spliterator; //導入方法依賴的package包/類
@Override
Spliterator.OfDouble spliterator();
示例4: lazySpliterator
import java.util.Spliterator; //導入方法依賴的package包/類
@Override
@SuppressWarnings("unchecked")
final Spliterator.OfDouble lazySpliterator(Supplier<? extends Spliterator<Double>> supplier) {
return new StreamSpliterators.DelegatingSpliterator.OfDouble((Supplier<Spliterator.OfDouble>) supplier);
}
示例5: testDoubleForEach
import java.util.Spliterator; //導入方法依賴的package包/類
@Test(dataProvider = "Spliterator.OfDouble")
public void testDoubleForEach(String description, Collection<Double> exp, Supplier<Spliterator.OfDouble> s) {
testForEach(exp, s, doubleBoxingConsumer());
}
示例6: add
import java.util.Spliterator; //導入方法依賴的package包/類
void add(String description, Supplier<Spliterator.OfDouble> s) {
add(description, exp, s);
}
示例7: OfDouble
import java.util.Spliterator; //導入方法依賴的package包/類
OfDouble(Spliterator.OfDouble s, UnorderedWhileSpliterator.OfDouble parent) {
super(s, parent);
this.p = parent.p;
}
示例8: testDoubleNullPointerException
import java.util.Spliterator; //導入方法依賴的package包/類
@Test(dataProvider = "Spliterator.OfDouble")
public void testDoubleNullPointerException(String description, Collection<Double> exp, Supplier<Spliterator.OfDouble> s) {
executeAndCatch(NullPointerException.class, () -> s.get().forEachRemaining((DoubleConsumer) null));
executeAndCatch(NullPointerException.class, () -> s.get().tryAdvance((DoubleConsumer) null));
}
示例9: OfDouble
import java.util.Spliterator; //導入方法依賴的package包/類
OfDouble(Spliterator.OfDouble s, long skip, long limit) {
super(s, skip, limit);
}
示例10: spliterator
import java.util.Spliterator; //導入方法依賴的package包/類
@Override
public Spliterator.OfDouble spliterator() {
assert !building : "during building";
return super.spliterator();
}
示例11: OfDouble
import java.util.Spliterator; //導入方法依賴的package包/類
OfDouble(Spliterator.OfDouble s, long sliceOrigin, long sliceFence) {
super(s, sliceOrigin, sliceFence);
}
示例12: OfDouble
import java.util.Spliterator; //導入方法依賴的package包/類
private OfDouble(Spliterator.OfDouble sp, boolean proxyEstimateSize) {
super(sp, proxyEstimateSize);
this.psp = sp;
}
示例13: spliterator
import java.util.Spliterator; //導入方法依賴的package包/類
@Override
public Spliterator.OfDouble spliterator() {
return Spliterators.emptyDoubleSpliterator();
}
示例14: testDoubleMixedTraverseAndSplit
import java.util.Spliterator; //導入方法依賴的package包/類
@Test(dataProvider = "Spliterator.OfDouble")
public void testDoubleMixedTraverseAndSplit(String description, Collection<Double> exp, Supplier<Spliterator.OfDouble> s) {
testMixedTraverseAndSplit(exp, s, doubleBoxingConsumer());
}
示例15: makeSpliterator
import java.util.Spliterator; //導入方法依賴的package包/類
@Override
protected Spliterator.OfDouble makeSpliterator(Spliterator.OfDouble s) {
return new UnorderedSliceSpliterator.OfDouble(s, this);
}