软件包 | 描述 |
---|---|
java.security |
为安全框架提供类和接口。
|
java.util |
包含集合框架、遗留的集合类、事件模型、日期和时间的设施、国际化和各种实用工具类(一个字符串标记,一个随机数发生器,和一位阵列)。
|
java.util.concurrent |
在并发编程中常用的实用类。
|
java.util.function |
功能接口提供目标类型的lambda表达式和方法参考。
|
java.util.stream |
类,以支持元素流上的功能样式操作,如Map减少集合上的转换。
|
Modifier and Type | Method and Description |
---|---|
Object |
Provider.compute(Object key, BiFunction<? super Object,? super Object,? extends Object> remappingFunction)
试图计算出指定键和当前的映射值的映射(或
null 如果没有当前映射)。
|
Object |
Provider.computeIfPresent(Object key, BiFunction<? super Object,? super Object,? extends Object> remappingFunction)
如果指定键的值是存在和非空的,尝试计算一个新的映射,给出了键和它当前的映射值。
|
Object |
Provider.merge(Object key, Object value, BiFunction<? super Object,? super Object,? extends Object> remappingFunction)
如果指定的键已与一个值关联或与空关联,则将其与给定值关联。
|
void |
Provider.replaceAll(BiFunction<? super Object,? super Object,? extends Object> function)
用调用给定函数的结果来替换每个条目的值,在顺序条目中返回一个条目集的迭代器,直到所有的条目被处理或函数抛出异常。
|
Modifier and Type | Method and Description |
---|---|
V |
HashMap.compute(K key, BiFunction<? super K,? super V,? extends V> remappingFunction) |
V |
Hashtable.compute(K key, BiFunction<? super K,? super V,? extends V> remappingFunction) |
default V |
Map.compute(K key, BiFunction<? super K,? super V,? extends V> remappingFunction)
试图计算出指定键和当前的映射值的映射(或
null 如果没有当前映射)。
|
V |
HashMap.computeIfPresent(K key, BiFunction<? super K,? super V,? extends V> remappingFunction) |
V |
Hashtable.computeIfPresent(K key, BiFunction<? super K,? super V,? extends V> remappingFunction) |
default V |
Map.computeIfPresent(K key, BiFunction<? super K,? super V,? extends V> remappingFunction)
如果指定键的值是存在和非空的,尝试计算一个新的映射,给出了键和它当前的映射值。
|
V |
HashMap.merge(K key, V value, BiFunction<? super V,? super V,? extends V> remappingFunction) |
V |
Hashtable.merge(K key, V value, BiFunction<? super V,? super V,? extends V> remappingFunction) |
default V |
Map.merge(K key, V value, BiFunction<? super V,? super V,? extends V> remappingFunction)
如果指定的键已与值相关联的值或与空值相关联的,则将其与给定的非空值关联。
|
void |
IdentityHashMap.replaceAll(BiFunction<? super K,? super V,? extends V> function) |
void |
WeakHashMap.replaceAll(BiFunction<? super K,? super V,? extends V> function) |
void |
HashMap.replaceAll(BiFunction<? super K,? super V,? extends V> function) |
void |
LinkedHashMap.replaceAll(BiFunction<? super K,? super V,? extends V> function) |
void |
Hashtable.replaceAll(BiFunction<? super K,? super V,? extends V> function) |
void |
TreeMap.replaceAll(BiFunction<? super K,? super V,? extends V> function) |
default void |
Map.replaceAll(BiFunction<? super K,? super V,? extends V> function)
将每个条目的值替换为在该项上调用给定函数的结果,直到所有的条目都被处理或函数抛出异常。
|
Modifier and Type | Method and Description |
---|---|
V |
ConcurrentSkipListMap.compute(K key, BiFunction<? super K,? super V,? extends V> remappingFunction)
试图计算出指定键和当前的映射值的映射(或
null 如果没有当前映射)。
|
default V |
ConcurrentMap.compute(K key, BiFunction<? super K,? super V,? extends V> remappingFunction)
试图计算出指定键和当前的映射值的映射(或
null 如果没有当前映射)。
|
V |
ConcurrentHashMap.compute(K key, BiFunction<? super K,? super V,? extends V> remappingFunction)
试图计算出指定键和当前的映射值的映射(或
null 如果没有当前映射)。
|
V |
ConcurrentSkipListMap.computeIfPresent(K key, BiFunction<? super K,? super V,? extends V> remappingFunction)
如果指定键的值存在,则尝试计算给定键的一个新的映射和它当前的映射值。
|
default V |
ConcurrentMap.computeIfPresent(K key, BiFunction<? super K,? super V,? extends V> remappingFunction)
如果指定键的值是存在和非空的,尝试计算一个新的映射,给出了键和它当前的映射值。
|
V |
ConcurrentHashMap.computeIfPresent(K key, BiFunction<? super K,? super V,? extends V> remappingFunction)
如果指定键的值存在,则尝试计算给定键的一个新的映射和它当前的映射值。
|
<U> void |
ConcurrentHashMap.forEach(long parallelismThreshold, BiFunction<? super K,? super V,? extends U> transformer, Consumer<? super U> action)
执行每个非空转换的给定动作(键,值)。
|
<U> CompletionStage<U> |
CompletionStage.handle(BiFunction<? super T,Throwable,? extends U> fn)
返回一个新的completionstage,当此阶段完成正常或异常,进行这一阶段的结果和异常作为提供的函数参数。
|
<U> CompletableFuture<U> |
CompletableFuture.handle(BiFunction<? super T,Throwable,? extends U> fn) |
<U> CompletionStage<U> |
CompletionStage.handleAsync(BiFunction<? super T,Throwable,? extends U> fn)
返回一个新的completionstage,当此阶段完成正常或异常,利用这个阶段的默认的异步执行机构执行,这个阶段的结果和异常作为提供的函数参数。
|
<U> CompletableFuture<U> |
CompletableFuture.handleAsync(BiFunction<? super T,Throwable,? extends U> fn) |
<U> CompletionStage<U> |
CompletionStage.handleAsync(BiFunction<? super T,Throwable,? extends U> fn, Executor executor)
返回一个新的completionstage,当此阶段完成正常或异常,是使用提供的遗嘱执行人执行,这个阶段的结果和异常作为提供的函数参数。
|
<U> CompletableFuture<U> |
CompletableFuture.handleAsync(BiFunction<? super T,Throwable,? extends U> fn, Executor executor) |
V |
ConcurrentSkipListMap.merge(K key, V value, BiFunction<? super V,? super V,? extends V> remappingFunction)
如果指定的键已不与某个值关联,则将其与给定值关联。
|
default V |
ConcurrentMap.merge(K key, V value, BiFunction<? super V,? super V,? extends V> remappingFunction)
如果指定的键已与值相关联的值或与空值相关联的,则将其与给定的非空值关联。
|
V |
ConcurrentHashMap.merge(K key, V value, BiFunction<? super V,? super V,? extends V> remappingFunction)
如果指定的键已与(非空)值关联,则将其与给定值关联。
|
<U> U |
ConcurrentHashMap.reduce(long parallelismThreshold, BiFunction<? super K,? super V,? extends U> transformer, BiFunction<? super U,? super U,? extends U> reducer)
返回累积给定的转换所有(键,值)对使用给定的减速器结合值,或为空,如果没有的结果。
|
<U> U |
ConcurrentHashMap.reduce(long parallelismThreshold, BiFunction<? super K,? super V,? extends U> transformer, BiFunction<? super U,? super U,? extends U> reducer)
返回累积给定的转换所有(键,值)对使用给定的减速器结合值,或为空,如果没有的结果。
|
Map.Entry<K,V> |
ConcurrentHashMap.reduceEntries(long parallelismThreshold, BiFunction<Map.Entry<K,V>,Map.Entry<K,V>,? extends Map.Entry<K,V>> reducer)
返回积累所有条目使用给定的减速器结合值,或为空,如果没有的结果。
|
<U> U |
ConcurrentHashMap.reduceEntries(long parallelismThreshold, Function<Map.Entry<K,V>,? extends U> transformer, BiFunction<? super U,? super U,? extends U> reducer)
返回积累给定的转换所有条目使用给定的减速器结合值,或为空,如果没有的结果。
|
K |
ConcurrentHashMap.reduceKeys(long parallelismThreshold, BiFunction<? super K,? super K,? extends K> reducer)
返回累积所有键的结果,使用给定的减速器组合值,或为空,如果没有。
|
<U> U |
ConcurrentHashMap.reduceKeys(long parallelismThreshold, Function<? super K,? extends U> transformer, BiFunction<? super U,? super U,? extends U> reducer)
返回累积给定的转换所有键的结果,使用给定的减速器组合值,或为零,如果没有。
|
V |
ConcurrentHashMap.reduceValues(long parallelismThreshold, BiFunction<? super V,? super V,? extends V> reducer)
返回累积所有值的结果,使用给定的减速器组合值,或为空,如果没有。
|
<U> U |
ConcurrentHashMap.reduceValues(long parallelismThreshold, Function<? super V,? extends U> transformer, BiFunction<? super U,? super U,? extends U> reducer)
返回累积给定的所有值转换的结果,使用给定的减速器组合值,或为零,如果没有。
|
void |
ConcurrentSkipListMap.replaceAll(BiFunction<? super K,? super V,? extends V> function) |
default void |
ConcurrentMap.replaceAll(BiFunction<? super K,? super V,? extends V> function)
将每个条目的值替换为在该项上调用给定函数的结果,直到所有的条目都被处理或函数抛出异常。
|
void |
ConcurrentHashMap.replaceAll(BiFunction<? super K,? super V,? extends V> function) |
<U> U |
ConcurrentHashMap.search(long parallelismThreshold, BiFunction<? super K,? super V,? extends U> searchFunction)
返回一个非空的结果,从应用给定的搜索功能上的每个(键,值),或空,如果没有。
|
<U,V> CompletionStage<V> |
CompletionStage.thenCombine(CompletionStage<? extends U> other, BiFunction<? super T,? super U,? extends V> fn)
返回一个新的completionstage,当和其他阶段都完全正常,是执行了两结果提供的函数参数。
|
<U,V> CompletableFuture<V> |
CompletableFuture.thenCombine(CompletionStage<? extends U> other, BiFunction<? super T,? super U,? extends V> fn) |
<U,V> CompletionStage<V> |
CompletionStage.thenCombineAsync(CompletionStage<? extends U> other, BiFunction<? super T,? super U,? extends V> fn)
返回一个新的completionstage,当这种和其他特定阶段的正常完成,利用这个阶段的默认的异步执行机构执行,与两结果提供的函数参数。
|
<U,V> CompletableFuture<V> |
CompletableFuture.thenCombineAsync(CompletionStage<? extends U> other, BiFunction<? super T,? super U,? extends V> fn) |
<U,V> CompletionStage<V> |
CompletionStage.thenCombineAsync(CompletionStage<? extends U> other, BiFunction<? super T,? super U,? extends V> fn, Executor executor)
返回一个新的completionstage,当这种和其他特定阶段的正常完成,使用提供的遗嘱执行人执行,与两结果提供的函数参数。
|
<U,V> CompletableFuture<V> |
CompletableFuture.thenCombineAsync(CompletionStage<? extends U> other, BiFunction<? super T,? super U,? extends V> fn, Executor executor) |
Modifier and Type | Interface and Description |
---|---|
interface |
BinaryOperator<T>
表示同一类型的两个操作数的操作,产生与操作数相同的结果。
|
Modifier and Type | Method and Description |
---|---|
default <V> BiFunction<T,U,V> |
BiFunction.andThen(Function<? super R,? extends V> after)
返回一个由功能首次采用该函数的输入,然后将
after 函数的结果。
|
Modifier and Type | Method and Description |
---|---|
<U> U |
Stream.reduce(U identity, BiFunction<U,? super T,U> accumulator, BinaryOperator<U> combiner)
对这一
reduction流元素,使用提供的身份,积累和组合功能。
|
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.