Package com.rosetta.model.lib.mapper
Class MapperListOfLists<T>
java.lang.Object
com.rosetta.model.lib.mapper.MapperListOfLists<T>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<F> Fapply(Function<MapperListOfLists<T>, F> f) Apply a function to this mapperfilterList(Predicate<MapperC<T>> predicate) Filter a list of lists based on the given predicate.filterListNullSafe(Function<MapperC<T>, Boolean> predicate) Filter a list of lists based on the given predicate.Flatten a list of lists to a list.<F> MapperC<F> mapListToItem(Function<MapperC<T>, MapperS<F>> mappingFunc) Map a list of lists to a list based on the given mapping function.<F> MapperListOfLists<F> mapListToList(Function<MapperC<T>, MapperC<F>> mappingFunc) Map list of lists to a different list of lists based on the given mapping function.static <T> MapperListOfLists<T>
-
Constructor Details
-
MapperListOfLists
-
-
Method Details
-
of
-
filterList
Filter a list of lists based on the given predicate.- Parameters:
predicate- - test that determines whether to filter list item. True to include in list, and false to exclude.- Returns:
- filtered list
-
filterListNullSafe
Filter a list of lists based on the given predicate.- Parameters:
predicate- - test that determines whether to filter list item. True to include in list, and false to exclude.- Returns:
- filtered list
-
mapListToItem
Map a list of lists to a list based on the given mapping function.- Type Parameters:
F-- Parameters:
mappingFunc-- Returns:
- mapped list
-
mapListToList
Map list of lists to a different list of lists based on the given mapping function.- Type Parameters:
F-- Parameters:
mappingFunc-- Returns:
- mapped list
-
apply
Apply a function to this mapper -
flattenList
Flatten a list of lists to a list.- Returns:
- flattened list
-