java.lang.Object
io.smallrye.beanbag.Util
Shared utilities.
-
Method Summary
Modifier and TypeMethodDescriptionstatic <R,T> List <R> mapList(List<T> input, Function<T, R> mapper, IntFunction<R[]> generator) Efficiently create a copy of the input list with each list element being transformed by the given function.
-
Method Details
-
mapList
public static <R,T> List<R> mapList(List<T> input, Function<T, R> mapper, IntFunction<R[]> generator) Efficiently create a copy of the input list with each list element being transformed by the given function.- Type Parameters:
R- the output list element typeT- the input list element type- Parameters:
input- the input list (must not benull)mapper- the mapping function (must not benull)generator- the generator for an array of typeR(must not benull)- Returns:
- the transformed list (not
null)
-