| Modifier and Type | Method and Description |
|---|---|
Class<T> |
getType()
Returns the type of this option.
|
T |
getValue(Object value)
Returns the provided value if not
null, otherwise returns the
default one. |
static <T> Option<T> |
of(Class<T> type,
T defaultValue)
Defines a new option of the provided type with the provided default
value.
|
static Option<Boolean> |
withDefault(boolean defaultValue)
Defines a new
Boolean option with the provided default value. |
public static Option<Boolean> withDefault(boolean defaultValue)
Boolean option with the provided default value.public static <T> Option<T> of(Class<T> type, T defaultValue)
T - The type of this option.type - The type of the option.defaultValue - The new option default value.Copyright © 2011-2015 ForgeRock AS. All Rights Reserved.