java.lang.Object
de.s42.base.conversion.ConversionHelper
-
Feldübersicht
Felder -
Konstruktorübersicht
Konstruktoren -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungstatic voidaddConverter(Class sourceClass, Class targetClass, Function<?, ?> converter) static StringbytesToHex(byte[] bytes) static booleancanConvert(Class sourceClass, Class targetClass) static <ReturnType>
ReturnTypestatic <ReturnType>
ReturnTypestatic <ReturnType>
ReturnType[]convertArray(Object[] values, Class<? extends ReturnType> targetClass) static <ReturnType>
ReturnType[]convertArray(ReturnType[] values, Class<? extends ReturnType>[] targetClasses) static <ReturnType>
List<ReturnType> convertList(Object[] values, Class<? extends ReturnType> targetClass) static <ReturnType>
List<ReturnType> convertList(List values, Class<? extends ReturnType> targetClass) static <ReturnType>
Set<ReturnType> convertSet(Object[] values, Class<? extends ReturnType> targetClass) static Class<?> unwrapPrimitives(Class<?> clazz) static Class<?> wrapPrimitives(Class<?> clazz)
-
Felddetails
-
converters
-
HEX_ARRAY
private static final char[] HEX_ARRAY -
DATE_FORMAT
-
-
Konstruktordetails
-
ConversionHelper
private ConversionHelper()
-
-
Methodendetails
-
wrapPrimitives
-
unwrapPrimitives
-
bytesToHex
-
addConverter
public static void addConverter(Class sourceClass, Class targetClass, Function<?, ?> converter) throws RuntimeException- Löst aus:
RuntimeException
-
convert
public static <ReturnType> ReturnType convert(Object value, Class<? extends ReturnType> targetClass, ReturnType defaultValue) throws RuntimeException - Löst aus:
RuntimeException
-
convert
public static <ReturnType> ReturnType convert(Object value, Class<? extends ReturnType> targetClass) throws RuntimeException - Löst aus:
RuntimeException
-
convertArray
public static <ReturnType> ReturnType[] convertArray(Object[] values, Class<? extends ReturnType> targetClass) throws RuntimeException - Löst aus:
RuntimeException
-
convertList
public static <ReturnType> List<ReturnType> convertList(Object[] values, Class<? extends ReturnType> targetClass) throws RuntimeException - Löst aus:
RuntimeException
-
convertList
public static <ReturnType> List<ReturnType> convertList(List values, Class<? extends ReturnType> targetClass) throws RuntimeException - Löst aus:
RuntimeException
-
convertSet
public static <ReturnType> Set<ReturnType> convertSet(Object[] values, Class<? extends ReturnType> targetClass) throws RuntimeException - Löst aus:
RuntimeException
-
convertArray
public static <ReturnType> ReturnType[] convertArray(ReturnType[] values, Class<? extends ReturnType>[] targetClasses) throws RuntimeException - Löst aus:
RuntimeException
-
canConvert
-