public class ObjectToAnyTransform extends Transform
| Modifier and Type | Field and Description |
|---|---|
static ObjectToAnyTransform |
INSTANCE |
| Constructor and Description |
|---|
ObjectToAnyTransform(Class targetClass) |
| Modifier and Type | Method and Description |
|---|---|
static Class<?> |
convertPrimitiveToObject(Class<?> clazz)
Convert a primitive class to the corresponding object class
|
Class |
getSourceType()
Type of the incoming value.
|
Class |
getTargetType()
Type of the outgoing value.
|
boolean |
isExplicit() |
Object |
transform(Object value,
Class<?> targetType)
This method transforms a value of the source type into a value
of the target type.
|
protected Object |
transformDirect(Object value) |
getDescription, getDisplayName, getSourceTypeName, getTargetTypeName, toStringpublic static final ObjectToAnyTransform INSTANCE
public ObjectToAnyTransform(Class targetClass)
public Class getSourceType()
getSourceType in class Transformpublic Class getTargetType()
TransformgetTargetType in class Transformpublic Object transform(Object value, Class<?> targetType) throws TransformationException
Transformtransform in class Transformvalue - Incoming value of source typeTransformationException - if value is an incorrect input type or
the transformation failsprotected Object transformDirect(Object value) throws TransformationException
transformDirect in class TransformTransformationExceptionpublic boolean isExplicit()
isExplicit in class TransformTransform.isExplicit()Copyright © 2017 JBoss by Red Hat. All rights reserved.