public class PluginUtils extends Object
| Constructor and Description |
|---|
PluginUtils() |
| Modifier and Type | Method and Description |
|---|---|
static <T,R> List<R> |
collectionMapping(Collection<T> sourceCollection,
Function<T,R> function)
Generalized method for collection mapping.
|
static <T extends Enum<T>,R extends Enum<R>> |
enumCollectionMapping(Collection<T> sourceCollection,
Class<R> clazz)
Generalized method for enum collection mapping.
|
static <T extends Enum<T>,R extends Enum<R>> |
enumMapping(T sourceEnum,
Class<R> clazz)
Generalized method for enum mapping.
|
public static <T,R> List<R> collectionMapping(Collection<T> sourceCollection, Function<T,R> function)
T - Input class typeR - Output class typesourceCollection - Input collectionfunction - Lambda expression for collection mappingpublic static <T extends Enum<T>,R extends Enum<R>> R enumMapping(T sourceEnum, Class<R> clazz)
T - Input enum typeR - Output enum typesourceEnum - Input enumclazz - Class type of output enumpublic static <T extends Enum<T>,R extends Enum<R>> List<R> enumCollectionMapping(Collection<T> sourceCollection, Class<R> clazz)
T - Input enum typeR - Output enum typesourceCollection - Input enum collectionclazz - Class type in output enum collectionCopyright © 2021. All rights reserved.