T - Type of object to hold.public class ObjectHolder<T> extends Object implements Supplier<T>, Consumer<T>
| Constructor and Description |
|---|
ObjectHolder()
Constructor
|
ObjectHolder(T value)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
apply(T value)
Applies this function to
input |
T |
get()
Retrieves an instance of the appropriate type.
|
String |
toString() |
public ObjectHolder(T value)
value - initial valuepublic ObjectHolder()
public T get()
Supplierpublic void apply(T value)
ConsumerinputCopyright © 2011-2020 The Apache Software Foundation. All Rights Reserved.