public abstract class TypeConversionUtils extends Object
Modifier and Type | Method and Description |
---|---|
static <T> T |
convertIfNecessary(Object target,
Class<T> type)
Converts target object to required type if necessary.
|
static <T> T |
convertStringToType(String value,
Class<T> type)
Convert value string to required type.
|
static <T> T |
convertStringToType(String value,
Class<T> type,
TestContext context)
Convert value string to required type or read bean of type from application context.
|
public static <T> T convertIfNecessary(Object target, Class<T> type)
T
- target
- type
- public static <T> T convertStringToType(String value, Class<T> type)
value
- type
- public static <T> T convertStringToType(String value, Class<T> type, TestContext context)
value
- type
- context
- Copyright © 2008–2017 ConSol Software GmbH. All rights reserved.