public final class Options extends Object
Modifier and Type | Method and Description |
---|---|
static Options |
copyOf(Options options)
Returns a copy of the provided set of options.
|
static Options |
defaultOptions()
Returns a new set of options with default settings.
|
<T> T |
get(Option<T> option)
Returns the value associated with the provided option, or its default
value if the option has not been configured.
|
<T> Options |
reset(Option<T> option)
Resets an option to its default behavior.
|
<T> Options |
set(Option<T> option,
T value)
Sets an option to the provided value.
|
static Options |
unmodifiableCopyOf(Options options)
Returns an unmodifiable copy of the provided set of options.
|
static Options |
unmodifiableDefaultOptions()
Returns an unmodifiable set of options with default settings.
|
public static Options copyOf(Options options)
options
- The options to be copied.public static Options defaultOptions()
public static Options unmodifiableCopyOf(Options options)
options
- The options to be copied.public static Options unmodifiableDefaultOptions()
public <T> T get(Option<T> option)
T
- The option type.option
- The option whose associated value is to be returned.public <T> Options reset(Option<T> option)
T
- The option type.option
- The option whose value is to be reset.UnsupportedOperationException
- If this set of options is unmodifiable.public <T> Options set(Option<T> option, T value)
T
- The option type.option
- The option whose value is to be set.value
- The option value.UnsupportedOperationException
- If this set of options is unmodifiable.Copyright 2010-2022 ForgeRock AS.