Home
last modified time | relevance | path

Searched refs:U (Results 1 – 25 of 86) sorted by relevance

1234

/libcore/ojluni/src/test/java/util/stream/bootlib/java/util/stream/
DStreamTestScenario.java46 <T, U, S_IN extends BaseStream<T, S_IN>> in STREAM_FOR_EACH_WITH_CLOSE()
47 void _run(TestData<T, S_IN> data, Consumer<U> b, Function<S_IN, Stream<U>> m) { in STREAM_FOR_EACH_WITH_CLOSE()
48 Stream<U> s = m.apply(data.stream()); in STREAM_FOR_EACH_WITH_CLOSE()
59 <T, U, S_IN extends BaseStream<T, S_IN>> in STREAM_COLLECT()
60 void _run(TestData<T, S_IN> data, Consumer<U> b, Function<S_IN, Stream<U>> m) { in STREAM_COLLECT()
61 for (U t : m.apply(data.stream()).collect(Collectors.toList())) { in STREAM_COLLECT()
69 <T, U, S_IN extends BaseStream<T, S_IN>> in STREAM_TO_ARRAY()
70 void _run(TestData<T, S_IN> data, Consumer<U> b, Function<S_IN, Stream<U>> m) { in STREAM_TO_ARRAY()
72 b.accept((U) t); in STREAM_TO_ARRAY()
79 <T, U, S_IN extends BaseStream<T, S_IN>> in STREAM_ITERATOR()
[all …]
DOpTestCase.java97 <T, U, S_IN extends BaseStream<T, S_IN>, S_OUT extends BaseStream<U, S_OUT>>
98 void run(TestData<T, S_IN> data, Consumer<U> b, Function<S_IN, S_OUT> m); in run()
101 protected <T, U, S_IN extends BaseStream<T, S_IN>, S_OUT extends BaseStream<U, S_OUT>>
102 Collection<U> exerciseOps(TestData<T, S_IN> data, Function<S_IN, S_OUT> m) { in exerciseOps()
109 protected final<T, U, S_IN extends BaseStream<T, S_IN>, S_OUT extends BaseStream<U, S_OUT>>
110 Collection<U> exerciseOpsMulti(TestData<T, S_IN> data, in exerciseOpsMulti()
112 Collection<U> result = null; in exerciseOpsMulti()
117 Collection<U> r2 = withData(data).stream(m).exercise(); in exerciseOpsMulti()
144 protected final<T, U, R, S_IN extends BaseStream<T, S_IN>, S_OUT extends BaseStream<U, S_OUT>>
185 protected <T, U, S_OUT extends BaseStream<U, S_OUT>>
[all …]
/libcore/ojluni/src/test/java/util/stream/testlib/org/openjdk/testlib/java/util/stream/
DStreamTestScenario.java49 <T, U, S_IN extends BaseStream<T, S_IN>> in STREAM_FOR_EACH_WITH_CLOSE()
50 void _run(TestData<T, S_IN> data, Consumer<U> b, Function<S_IN, Stream<U>> m) { in STREAM_FOR_EACH_WITH_CLOSE()
51 Stream<U> s = m.apply(data.stream()); in STREAM_FOR_EACH_WITH_CLOSE()
62 <T, U, S_IN extends BaseStream<T, S_IN>> in STREAM_COLLECT()
63 void _run(TestData<T, S_IN> data, Consumer<U> b, Function<S_IN, Stream<U>> m) { in STREAM_COLLECT()
64 for (U t : m.apply(data.stream()).collect(Collectors.toList())) { in STREAM_COLLECT()
72 <T, U, S_IN extends BaseStream<T, S_IN>> in STREAM_TO_ARRAY()
73 void _run(TestData<T, S_IN> data, Consumer<U> b, Function<S_IN, Stream<U>> m) { in STREAM_TO_ARRAY()
75 b.accept((U) t); in STREAM_TO_ARRAY()
82 <T, U, S_IN extends BaseStream<T, S_IN>> in STREAM_ITERATOR()
[all …]
DOpTestCase.java98 <T, U, S_IN extends BaseStream<T, S_IN>, S_OUT extends BaseStream<U, S_OUT>>
99 void run(TestData<T, S_IN> data, Consumer<U> b, Function<S_IN, S_OUT> m); in run()
102 protected <T, U, S_IN extends BaseStream<T, S_IN>, S_OUT extends BaseStream<U, S_OUT>>
103 Collection<U> exerciseOps(TestData<T, S_IN> data, Function<S_IN, S_OUT> m) { in exerciseOps()
110 protected final<T, U, S_IN extends BaseStream<T, S_IN>, S_OUT extends BaseStream<U, S_OUT>>
111 Collection<U> exerciseOpsMulti(TestData<T, S_IN> data, in exerciseOpsMulti()
113 Collection<U> result = null; in exerciseOpsMulti()
118 Collection<U> r2 = withData(data).stream(m).exercise(); in exerciseOpsMulti()
145 protected final<T, U, R, S_IN extends BaseStream<T, S_IN>, S_OUT extends BaseStream<U, S_OUT>>
186 protected <T, U, S_OUT extends BaseStream<U, S_OUT>>
[all …]
/libcore/ojluni/src/main/java/java/util/concurrent/
DCompletionStage.java170 public <U> CompletionStage<U> thenApply(Function<? super T,? extends U> fn); in thenApply()
186 public <U> CompletionStage<U> thenApplyAsync in thenApplyAsync()
187 (Function<? super T,? extends U> fn); in thenApplyAsync()
203 public <U> CompletionStage<U> thenApplyAsync in thenApplyAsync()
204 (Function<? super T,? extends U> fn, in thenApplyAsync()
308 public <U,V> CompletionStage<V> thenCombine in thenCombine()
309 (CompletionStage<? extends U> other, in thenCombine()
310 BiFunction<? super T,? super U,? extends V> fn); in thenCombine() argument
328 public <U,V> CompletionStage<V> thenCombineAsync in thenCombineAsync()
329 (CompletionStage<? extends U> other, in thenCombineAsync()
[all …]
DThreadLocalRandom.java174 U.putLong(t, SEED, seed); in localInit()
175 U.putInt(t, PROBE, probe); in localInit()
186 if (U.getInt(Thread.currentThread(), PROBE) == 0) in current()
220 U.putLong(t = Thread.currentThread(), SEED, in nextSeed()
221 r = U.getLong(t, SEED) + (t.getId() << 1) + GOLDEN_GAMMA); in nextSeed()
263 return U.getInt(Thread.currentThread(), PROBE); in getProbe()
274 U.putInt(Thread.currentThread(), PROBE, probe); in advanceProbe()
284 if ((r = U.getInt(t, SECONDARY)) != 0) { in nextSecondarySeed()
291 U.putInt(t, SECONDARY, r); in nextSecondarySeed()
301 U.putReference(thread, THREADLOCALS, null); in eraseThreadLocals()
[all …]
DCompletableFuture.java1063 static final class UniRelay<U, T extends U> extends UniCompletion<T,U> {
1064 UniRelay(CompletableFuture<U> dep, CompletableFuture<T> src) { in UniRelay()
1067 final CompletableFuture<U> tryFire(int mode) { in tryFire()
1068 CompletableFuture<U> d; CompletableFuture<T> a; Object r; in tryFire()
1079 private static <U, T extends U> CompletableFuture<U> uniCopyStage( in uniCopyStage()
1082 CompletableFuture<U> d = src.newIncompleteFuture(); in uniCopyStage()
1086 src.unipush(new UniRelay<U,T>(d, src)); in uniCopyStage()
1180 abstract static class BiCompletion<T,U,V> extends UniCompletion<T,V> {
1181 CompletableFuture<U> snd; // second source for action
1183 CompletableFuture<T> src, CompletableFuture<U> snd) { in BiCompletion()
[all …]
DConcurrentHashMap.java760 return (Node<K,V>)U.getReferenceAcquire(tab, ((long)i << ASHIFT) + ABASE); in tabAt()
765 return U.compareAndSetReference(tab, ((long)i << ASHIFT) + ABASE, c, v); in casTabAt()
769 U.putReferenceRelease(tab, ((long)i << ASHIFT) + ABASE, v); in setTabAt()
2301 else if (U.compareAndSetInt(this, SIZECTL, sc, -1)) { in initTable()
2332 !U.compareAndSetLong(this, BASECOUNT, b = baseCount, s = b + x)) { in addCount()
2338 U.compareAndSetLong(c, CELLVALUE, v = c.value, v + x))) { in addCount()
2355 if (U.compareAndSetInt(this, SIZECTL, sc, sc + 1)) in addCount()
2358 else if (U.compareAndSetInt(this, SIZECTL, sc, rs + 2)) in addCount()
2378 if (U.compareAndSetInt(this, SIZECTL, sc, sc + 1)) { in helpTransfer()
2401 if (U.compareAndSetInt(this, SIZECTL, sc, -1)) { in tryPresize()
[all …]
/libcore/luni/src/test/java/libcore/java/util/concurrent/
DCompletionStageTest.java100 public <U> CompletionStage<U> thenApply(Function<? super T,? extends U> fn) { in thenApply()
104 public <U> CompletionStage<U> thenApplyAsync(Function<? super T,? extends U> fn) { in thenApplyAsync()
108 public <U> CompletionStage<U> thenApplyAsync(Function<? super T,? extends U> fn, in thenApplyAsync()
139 public <U,V> CompletionStage<V> thenCombine(CompletionStage<? extends U> other, in thenCombine()
140 BiFunction<? super T,? super U,? extends V> fn) { in thenCombine() argument
144 public <U,V> CompletionStage<V> thenCombineAsync(CompletionStage<? extends U> other, in thenCombineAsync()
145 BiFunction<? super T,? super U,? extends V> fn) { in thenCombineAsync() argument
149 public <U,V> CompletionStage<V> thenCombineAsync(CompletionStage<? extends U> other, in thenCombineAsync()
150 BiFunction<? super T,? super U,? extends V> fn, in thenCombineAsync() argument
155 public <U> CompletionStage<Void> thenAcceptBoth(CompletionStage<? extends U> other, in thenAcceptBoth()
[all …]
/libcore/ojluni/annotations/mmodule/java/util/concurrent/
DCompletableFuture.annotated.java46 public static <U> java.util.concurrent.CompletableFuture<U> supplyAsync(java.util.function.Supplier… in supplyAsync()
48 public static <U> java.util.concurrent.CompletableFuture<U> supplyAsync(java.util.function.Supplier… in supplyAsync()
54 public static <U> java.util.concurrent.CompletableFuture<U> completedFuture(U value) { throw new Ru… in completedFuture()
70 public <U> java.util.concurrent.CompletableFuture<U> thenApply(java.util.function.Function<? super … in thenApply()
72 public <U> java.util.concurrent.CompletableFuture<U> thenApplyAsync(java.util.function.Function<? s… in thenApplyAsync()
74 public <U> java.util.concurrent.CompletableFuture<U> thenApplyAsync(java.util.function.Function<? s… in thenApplyAsync()
88U, V> java.util.concurrent.CompletableFuture<V> thenCombine(java.util.concurrent.CompletionStage<?… in thenCombine() argument
90U, V> java.util.concurrent.CompletableFuture<V> thenCombineAsync(java.util.concurrent.CompletionSt… in thenCombineAsync() argument
92U, V> java.util.concurrent.CompletableFuture<V> thenCombineAsync(java.util.concurrent.CompletionSt… in thenCombineAsync() argument
94U> java.util.concurrent.CompletableFuture<java.lang.Void> thenAcceptBoth(java.util.concurrent.Comp… in thenAcceptBoth()
[all …]
/libcore/ojluni/src/main/java/java/util/concurrent/locks/
DLockSupport.java143 U.putReferenceOpaque(t, PARKBLOCKER, arg); in setBlocker()
161 U.putReferenceOpaque(Thread.currentThread(), PARKBLOCKER, blocker); in setCurrentBlocker()
177 U.unpark(thread); in unpark()
211 U.park(false, 0L); in park()
252 U.park(false, nanos); in parkNanos()
293 U.park(true, deadline); in parkUntil()
312 return U.getReferenceOpaque(t, PARKBLOCKER); in getBlocker()
341 U.park(false, 0L); in park()
376 U.park(false, nanos); in parkNanos()
410 U.park(true, deadline); in parkUntil()
[all …]
DStampedLock.java357 return U.weakCompareAndSetReference(this, PREV, c, v); in casPrev()
360 return U.weakCompareAndSetReference(this, NEXT, c, v); in casNext()
363 return U.getAndBitwiseAndInt(this, STATUS, ~v); in getAndUnsetStatus()
366 U.putReference(this, PREV, p); in setPrevRelaxed()
369 U.putInt(this, STATUS, s); in setStatusRelaxed()
372 U.putIntOpaque(this, STATUS, 0); in clearStatus()
376 = U.objectFieldOffset(Node.class, "status");
378 = U.objectFieldOffset(Node.class, "next");
380 = U.objectFieldOffset(Node.class, "prev");
389 return U.weakCompareAndSetReference(this, COWAITERS, c, v); in casCowaiters()
[all …]
/libcore/ojluni/src/main/java/java/util/function/
DBiPredicate.java43 public interface BiPredicate<T, U> {
53 boolean test(T t, U u); in test()
71 default BiPredicate<T, U> and(BiPredicate<? super T, ? super U> other) { in and()
73 return (T t, U u) -> test(t, u) && other.test(t, u); in and()
83 default BiPredicate<T, U> negate() { in negate()
84 return (T t, U u) -> !test(t, u); in negate()
103 default BiPredicate<T, U> or(BiPredicate<? super T, ? super U> other) { in or()
105 return (T t, U u) -> test(t, u) || other.test(t, u); in or()
DBiConsumer.java45 public interface BiConsumer<T, U> {
53 void accept(T t, U u); in accept()
67 default BiConsumer<T, U> andThen(BiConsumer<? super T, ? super U> after) { in andThen()
DBiFunction.java44 public interface BiFunction<T, U, R> {
53 R apply(T t, U u); in apply()
68 default <V> BiFunction<T, U, V> andThen(Function<? super R, ? extends V> after) { in andThen()
70 return (T t, U u) -> after.apply(apply(t, u)); in andThen()
DToDoubleBiFunction.java42 public interface ToDoubleBiFunction<T, U> {
51 double applyAsDouble(T t, U u); in applyAsDouble()
DToLongBiFunction.java42 public interface ToLongBiFunction<T, U> {
51 long applyAsLong(T t, U u); in applyAsLong()
/libcore/ojluni/annotations/flagged_api/java/util/stream/
DCollectors.annotated.java49 …T, U, A, R> java.util.stream.Collector<T,?,R> mapping(java.util.function.Function<? super T,? exte… in mapping() argument
51U, A, R> java.util.stream.Collector<T,?,R> flatMapping(java.util.function.Function<? super T,? ext… in flatMapping() argument
79U> java.util.stream.Collector<T,?,U> reducing(U identity, java.util.function.Function<? super T,? … in reducing()
97U> java.util.stream.Collector<T,?,java.util.Map<K,U>> toMap(java.util.function.Function<? super T,… in toMap()
99U> java.util.stream.Collector<T,?,java.util.Map<K,U>> toUnmodifiableMap(java.util.function.Functio… in toUnmodifiableMap()
101U> java.util.stream.Collector<T,?,java.util.Map<K,U>> toMap(java.util.function.Function<? super T,… in toMap()
103U> java.util.stream.Collector<T,?,java.util.Map<K,U>> toUnmodifiableMap(java.util.function.Functio… in toUnmodifiableMap()
105U, M extends java.util.Map<K, U>> java.util.stream.Collector<T,?,M> toMap(java.util.function.Funct… in toMap()
107U> java.util.stream.Collector<T,?,java.util.concurrent.ConcurrentMap<K,U>> toConcurrentMap(java.ut… in toConcurrentMap()
109U> java.util.stream.Collector<T,?,java.util.concurrent.ConcurrentMap<K,U>> toConcurrentMap(java.ut… in toConcurrentMap()
[all …]
/libcore/ojluni/src/main/java/java/util/
DComparator.java242 default <U> Comparator<T> thenComparing( in thenComparing()
243 Function<? super T, ? extends U> keyExtractor, in thenComparing()
244 Comparator<? super U> keyComparator) in thenComparing()
266 default <U extends Comparable<? super U>> Comparator<T> thenComparing( in thenComparing()
267 Function<? super T, ? extends U> keyExtractor) in thenComparing()
433 public static <T, U> Comparator<T> comparing( in comparing()
434 Function<? super T, ? extends U> keyExtractor, in comparing()
435 Comparator<? super U> keyComparator) in comparing()
468 public static <T, U extends Comparable<? super U>> Comparator<T> comparing( in comparing()
469 Function<? super T, ? extends U> keyExtractor) in comparing()
DOptional.java255 public <U> Optional<U> map(Function<? super T, ? extends U> mapper) { in map()
283 public <U> Optional<U> flatMap(Function<? super T, ? extends Optional<? extends U>> mapper) { in flatMap()
289 Optional<U> r = (Optional<U>) mapper.apply(value); in flatMap()
/libcore/ojluni/src/main/java/java/util/concurrent/atomic/
DAtomicLongFieldUpdater.java90 public static <U> AtomicLongFieldUpdater<U> newUpdater(Class<U> tclass, in newUpdater()
94 return new CASUpdater<U>(tclass, fieldName, caller); in newUpdater()
96 return new LockedUpdater<U>(tclass, fieldName, caller); in newUpdater()
377 private static final Unsafe U = Unsafe.getUnsafe(); field in AtomicLongFieldUpdater.CASUpdater
442 this.offset = U.objectFieldOffset(field); in CASUpdater()
474 return U.compareAndSetLong(obj, offset, expect, update); in compareAndSet()
479 return U.compareAndSetLong(obj, offset, expect, update); in weakCompareAndSet()
484 U.putLongVolatile(obj, offset, newValue); in set()
489 U.putLongRelease(obj, offset, newValue); in lazySet()
494 return U.getLongVolatile(obj, offset); in get()
[all …]
DAtomicReferenceFieldUpdater.java111 public static <U,W> AtomicReferenceFieldUpdater<U,W> newUpdater(Class<U> tclass, in newUpdater()
114 return new AtomicReferenceFieldUpdaterImpl<U,W> in newUpdater()
299 private static final Unsafe U = Unsafe.getUnsafe(); field in AtomicReferenceFieldUpdater.AtomicReferenceFieldUpdaterImpl
385 this.offset = U.objectFieldOffset(field); in AtomicReferenceFieldUpdaterImpl()
455 return U.compareAndSetReference(obj, offset, expect, update); in compareAndSet()
462 return U.compareAndSetReference(obj, offset, expect, update); in weakCompareAndSet()
468 U.putReferenceVolatile(obj, offset, newValue); in set()
474 U.putReferenceRelease(obj, offset, newValue); in lazySet()
480 return (V)U.getReferenceVolatile(obj, offset); in get()
487 return (V)U.getAndSetReference(obj, offset, newValue); in getAndSet()
DAtomicIntegerFieldUpdater.java90 public static <U> AtomicIntegerFieldUpdater<U> newUpdater(Class<U> tclass, in newUpdater()
92 return new AtomicIntegerFieldUpdaterImpl<U> in newUpdater()
378 private static final Unsafe U = Unsafe.getUnsafe(); field in AtomicIntegerFieldUpdater.AtomicIntegerFieldUpdaterImpl
447 this.offset = U.objectFieldOffset(field); in AtomicIntegerFieldUpdaterImpl()
508 return U.compareAndSetInt(obj, offset, expect, update); in compareAndSet()
513 return U.compareAndSetInt(obj, offset, expect, update); in weakCompareAndSet()
518 U.putIntVolatile(obj, offset, newValue); in set()
523 U.putIntRelease(obj, offset, newValue); in lazySet()
528 return U.getIntVolatile(obj, offset); in get()
533 return U.getAndSetInt(obj, offset, newValue); in getAndSet()
[all …]
/libcore/ojluni/annotations/sdk/nullability/java/util/concurrent/
DConcurrentHashMap.annotated.java132U> void forEach(long parallelismThreshold, @libcore.util.NonNull java.util.function.BiFunction<? s… in forEach()
134U> U search(long parallelismThreshold, @libcore.util.NonNull java.util.function.BiFunction<? super… in search()
136U> U reduce(long parallelismThreshold, @libcore.util.NonNull java.util.function.BiFunction<? super… in reduce() argument
146U> void forEachKey(long parallelismThreshold, @libcore.util.NonNull java.util.function.Function<? … in forEachKey()
148U> U searchKeys(long parallelismThreshold, @libcore.util.NonNull java.util.function.Function<? sup… in searchKeys()
152U> U reduceKeys(long parallelismThreshold, @libcore.util.NonNull java.util.function.Function<? sup… in reduceKeys() argument
162U> void forEachValue(long parallelismThreshold, @libcore.util.NonNull java.util.function.Function<… in forEachValue()
164U> U searchValues(long parallelismThreshold, @libcore.util.NonNull java.util.function.Function<? s… in searchValues()
168U> U reduceValues(long parallelismThreshold, @libcore.util.NonNull java.util.function.Function<? s… in reduceValues() argument
178U> void forEachEntry(long parallelismThreshold, @libcore.util.NonNull java.util.function.Function<… in forEachEntry()
[all …]
/libcore/ojluni/src/main/java/java/util/stream/
DCollectors.java465 public static <T, U, A, R>
466 Collector<T, ?, R> mapping(Function<? super T, ? extends U> mapper,
467 Collector<? super U, A, R> downstream) {
468 BiConsumer<A, ? super U> downstreamAccumulator = downstream.accumulator();
510 public static <T, U, A, R>
511 Collector<T, ?, R> flatMapping(Function<? super T, ? extends Stream<? extends U>> mapper,
512 Collector<? super U, A, R> downstream) {
513 BiConsumer<A, ? super U> downstreamAccumulator = downstream.accumulator();
516 try (Stream<? extends U> result = mapper.apply(t)) {
986 public static <T, U>
[all …]

1234