abstract class AbstractSpecifying<T extends Specifying<T>> extends java.lang.Object implements Specifying<T>
| Modifier and Type | Field and Description |
|---|---|
protected java.lang.Object |
defaultValue |
protected boolean |
hasDefault |
protected boolean |
keysIgnoreCase |
protected boolean |
liveView |
protected java.lang.Class<?> |
sourceAsClass |
protected boolean |
sourceAsDTO |
protected boolean |
sourceAsJavaBean |
protected java.lang.Class<?> |
targetAsClass |
protected boolean |
targetAsDTO |
protected boolean |
targetAsJavaBean |
| Constructor and Description |
|---|
AbstractSpecifying() |
| Modifier and Type | Method and Description |
|---|---|
private T |
castThis() |
T |
defaultValue(java.lang.Object defVal)
The default value to use when the object cannot be converted or in case
of conversion from a
null value. |
T |
keysIgnoreCase()
When converting between map-like types use case-insensitive mapping of
keys.
|
T |
sourceAs(java.lang.Class<?> cls)
Treat the source object as the specified class.
|
T |
sourceAsBean()
Treat the source object as a JavaBean.
|
T |
sourceAsDTO()
Treat the source object as a DTO even if the source object has methods or
is otherwise not recognized as a DTO.
|
T |
targetAs(java.lang.Class<?> cls)
Treat the target object as the specified class.
|
T |
targetAsBean()
Treat the target object as a JavaBean.
|
T |
targetAsDTO()
Treat the target object as a DTO even if it has methods or is otherwise
not recognized as a DTO.
|
T |
view()
Return a live view over the backing object that reflects any changes to
the original object.
|
protected volatile java.lang.Object defaultValue
protected volatile boolean hasDefault
protected volatile boolean liveView
protected volatile boolean keysIgnoreCase
protected volatile java.lang.Class<?> sourceAsClass
protected volatile boolean sourceAsDTO
protected volatile boolean sourceAsJavaBean
protected volatile java.lang.Class<?> targetAsClass
protected volatile boolean targetAsDTO
protected volatile boolean targetAsJavaBean
private T castThis()
public T defaultValue(java.lang.Object defVal)
Specifyingnull value.defaultValue in interface Specifying<T extends Specifying<T>>defVal - The default value.Converting object so that additional calls
can be chained.public T keysIgnoreCase()
SpecifyingkeysIgnoreCase in interface Specifying<T extends Specifying<T>>Converting object so that additional calls
can be chained.public T sourceAs(java.lang.Class<?> cls)
SpecifyingsourceAs in interface Specifying<T extends Specifying<T>>cls - The class to treat the object as.Converting object so that additional calls
can be chained.public T sourceAsBean()
SpecifyingsourceAsBean in interface Specifying<T extends Specifying<T>>Converting object so that additional calls
can be chained.public T sourceAsDTO()
SpecifyingsourceAsDTO in interface Specifying<T extends Specifying<T>>Converting object so that additional calls
can be chained.public T targetAs(java.lang.Class<?> cls)
SpecifyingtargetAs in interface Specifying<T extends Specifying<T>>cls - The class to treat the object as.Converting object so that additional calls
can be chained.public T targetAsBean()
SpecifyingtargetAsBean in interface Specifying<T extends Specifying<T>>Converting object so that additional calls
can be chained.public T targetAsDTO()
SpecifyingtargetAsDTO in interface Specifying<T extends Specifying<T>>Converting object so that additional calls
can be chained.public T view()
SpecifyingMap, Collection,
List and Set. The live view object
will cease to be live as soon as modifications are made to it. Note that
conversions to an interface or annotation will always produce a live view
that cannot be modified. This modifier has no effect with conversions to
other types.view in interface Specifying<T extends Specifying<T>>Converting object so that additional calls
can be chained.