Package ch.qos.logback.core.joran.util
Class StringToObjectConverter
- java.lang.Object
-
- ch.qos.logback.core.joran.util.StringToObjectConverter
-
public class StringToObjectConverter extends java.lang.ObjectUtility class which can convert string into objects.
-
-
Field Summary
Fields Modifier and Type Field Description private static java.lang.Class<?>[]STING_CLASS_PARAMETER
-
Constructor Summary
Constructors Constructor Description StringToObjectConverter()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static booleancanBeBuiltFromSimpleString(java.lang.Class<?> parameterClass)static java.lang.ObjectconvertArg(ContextAware ca, java.lang.String val, java.lang.Class<?> type)Convertvala String parameter to an object of a given type.private static java.lang.ObjectconvertByValueOfMethod(ContextAware ca, java.lang.Class<?> type, java.lang.String val)private static java.nio.charset.CharsetconvertToCharset(ContextAware ca, java.lang.String val)private static java.lang.ObjectconvertToEnum(ContextAware ca, java.lang.String val, java.lang.Class<? extends java.lang.Enum> enumType)private static booleanfollowsTheValueOfConvention(java.lang.Class<?> parameterClass)static java.lang.reflect.MethodgetValueOfMethod(java.lang.Class<?> type)(package private) booleanisBuildableFromSimpleString()private static booleanisOfTypeCharset(java.lang.Class<?> type)
-
-
-
Method Detail
-
canBeBuiltFromSimpleString
public static boolean canBeBuiltFromSimpleString(java.lang.Class<?> parameterClass)
-
convertArg
public static java.lang.Object convertArg(ContextAware ca, java.lang.String val, java.lang.Class<?> type)
Convertvala String parameter to an object of a given type.
-
isOfTypeCharset
private static boolean isOfTypeCharset(java.lang.Class<?> type)
-
convertToCharset
private static java.nio.charset.Charset convertToCharset(ContextAware ca, java.lang.String val)
-
getValueOfMethod
public static java.lang.reflect.Method getValueOfMethod(java.lang.Class<?> type)
-
followsTheValueOfConvention
private static boolean followsTheValueOfConvention(java.lang.Class<?> parameterClass)
-
convertByValueOfMethod
private static java.lang.Object convertByValueOfMethod(ContextAware ca, java.lang.Class<?> type, java.lang.String val)
-
convertToEnum
private static java.lang.Object convertToEnum(ContextAware ca, java.lang.String val, java.lang.Class<? extends java.lang.Enum> enumType)
-
isBuildableFromSimpleString
boolean isBuildableFromSimpleString()
-
-