public class Functions extends Object
| Modifier and Type | Method and Description |
|---|---|
static <T> BinaryOperator<T> |
firstWinsMerger()
A merger operation upon two operands of the same type, typically for handling
collisions between values associated with the same key in a Map, where the first object
is always applied.
|
static <T> BinaryOperator<T> |
lastWinsMerger()
A merger operation upon two operands of the same type, typically for handling
collisions between values associated with the same key in a Map, where the second
object is always applied.
|
public static <T> BinaryOperator<T> firstWinsMerger()
T - the type of the operands and result of the operatorpublic static <T> BinaryOperator<T> lastWinsMerger()
T - the type of the operands and result of the operatorCopyright © 2021. All rights reserved.