Package io.micronaut.core.value
Interface OptionalMultiValues<V>
- Type Parameters:
V- The generic value
- All Superinterfaces:
Iterable<CharSequence>,OptionalValues<List<V>>
- Since:
- 1.0
- Author:
- Graeme Rocher
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic <T> OptionalMultiValues<T>empty()An emptyOptionalValues.getFirst(CharSequence name) Retrieve a value if it is present.static <T> OptionalMultiValues<T>of(Map<CharSequence, List<T>> values) Creates a newOptionalValuesfor the given type and values.Methods inherited from interface java.lang.Iterable
forEach, iterator, spliteratorMethods inherited from interface io.micronaut.core.value.OptionalValues
forEach, get, isEmpty, values
-
Field Details
-
EMPTY_VALUES
Constant for empty values.
-
-
Method Details
-
getFirst
Retrieve a value if it is present.- Parameters:
name- The name of the value- Returns:
- An
Optionalof the value
-
empty
An emptyOptionalValues.- Type Parameters:
T- The generic type- Returns:
- The empty values
-
of
Creates a newOptionalValuesfor the given type and values.- Type Parameters:
T- The target generic type- Parameters:
values- A map of values- Returns:
- The values
-