public class TypeValue extends AbstractValue implements ITypeValue
Modifier and Type | Method and Description |
---|---|
Object |
get()
Return the actual value object.
|
<T> T |
get(Class<T> type)
Get the value by converting it into the given type.
|
<T> T |
get(Class<T> type,
T defaultValue)
Get the value by converting it into the given type.
|
PropertyFormatType |
getFormat()
Returns the
PropertyFormatType of value |
PropertyType |
getPropertyType()
Returns the
PropertyType of value |
Object |
getResult() |
static TypeValue |
of(PropertyType type,
PropertyFormatType formatType,
Object value) |
String |
toString() |
toJson
public Object get()
get
in interface ITypeValue
public PropertyType getPropertyType()
PropertyType
of valuegetPropertyType
in interface ITypeValue
PropertyType
of valuepublic PropertyFormatType getFormat()
PropertyFormatType
of valuegetFormat
in interface ITypeValue
PropertyFormatType
of valuepublic <T> T get(Class<T> type)
get
in interface ITypeValue
type
- The class of the typepublic <T> T get(Class<T> type, T defaultValue)
get
in interface ITypeValue
type
- The class of the typedefaultValue
- The default value to use if the named property does
not exist or cannot be converted to the requested type. The
default value is also used to define the type to convert the
value to. If this is null
any existing property is
not converted.public Object getResult()
public static TypeValue of(PropertyType type, PropertyFormatType formatType, Object value) throws DermisException
DermisException
public String toString()
AbstractValue
toString
in class AbstractValue
Copyright © 1982–2022 Adobe Systems Inc.. All rights reserved.