public class TransientFieldHandler<T> extends AbstractFieldHandler<T>
_properties
Constructor and Description |
---|
TransientFieldHandler() |
Modifier and Type | Method and Description |
---|---|
T |
getValue(Object target)
Returns the value of the field from the object.
|
T |
newInstance(Object target)
Creates a new instance of the object described by this field.
|
Object |
newInstance(Object target,
Object[] args)
Creates a new instance of the object described by this field.
|
void |
resetValue(Object target)
Sets the value of the field to a default value.
|
void |
setValue(Object target,
Object value)
Sets the value of the field on the object.
|
getFieldDescriptor, hasValue, setConfiguration, setFieldDescriptor
checkValidity
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
checkValidity
public T getValue(Object target)
FieldHandler
target
- The objectpublic T newInstance(Object target)
FieldHandler
target
- The object for which the field is createdpublic Object newInstance(Object target, Object[] args)
ExtendedFieldHandler
newInstance
in class ExtendedFieldHandler<T>
target
- The object for which the field is createdargs
- the set of constructor argumentspublic void setValue(Object target, Object value)
FieldHandler
target
- The object.value
- The new value.public void resetValue(Object target)
FieldHandler
Reference fields are set to null, primitive fields are set to their default value, collection fields are emptied of all elements.
target
- The object.Copyright © 2017. All rights reserved.