public final class LambdaUtil
extends java.lang.Object
Modifier | Constructor and Description |
---|---|
private |
LambdaUtil()
Private constructor: this class is not intended to be instantiated.
|
Modifier and Type | Method and Description |
---|---|
static Message |
get(MessageSupplier supplier)
Returns the Message supplied by the specified function.
|
static java.lang.Object |
get(Supplier<?> supplier)
Returns the result of evaluating the specified function.
|
static java.lang.Object[] |
getAll(Supplier<?>... suppliers)
Converts an array of lambda expressions into an array of their evaluation results.
|
static Message |
getMessage(Supplier<?> supplier,
MessageFactory messageFactory)
Returns a Message, either the value supplied by the specified function, or a new Message created by the specified
Factory.
|
private LambdaUtil()
public static java.lang.Object[] getAll(Supplier<?>... suppliers)
suppliers
- an array of lambda expressions or null
null
if the suppliers
array was null
public static java.lang.Object get(Supplier<?> supplier)
#getFormattedMessage
on that Message.supplier
- a lambda expression or null
null
if the supplier
was null
public static Message get(MessageSupplier supplier)
supplier
- a lambda expression or null
null
if the supplier was
null
public static Message getMessage(Supplier<?> supplier, MessageFactory messageFactory)
supplier
- a lambda expression or null