V - the type of instance that can be containedpublic final class Input<V>
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static <V> Input<V> |
absent()
Creates a new
Input instance that is always undefined. |
static <V> Input<V> |
fromNullable(V value)
Creates a new
Input instance that is always defined. |
static <V> Input<V> |
optional(V value)
Creates a new
Input instance that is defined in case if value is not-null and undefined otherwise. |
public final V value
public final boolean defined
public static <V> Input<V> optional(@Nullable V value)
Input instance that is defined in case if value is not-null and undefined otherwise.value - to be wrappedInput instancepublic static <V> Input<V> fromNullable(@Nullable V value)
Input instance that is always defined.value - to be wrappedInput instance