public class DefaultPersistenceDelegate extends PersistenceDelegate
DefaultPersistenceDelegate is a PersistenceDelegate
implementation that can be used to serialize objects which adhere to the
Java Beans naming convention.
| Constructor and Description |
|---|
DefaultPersistenceDelegate()
Using this constructor the object to be serialized will be instantiated
with the default non-argument constructor.
|
DefaultPersistenceDelegate(java.lang.String[] constructorPropertyNames)
This constructor allows to specify which Bean properties appear
in the constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
initialize(java.lang.Class<?> type,
java.lang.Object oldInstance,
java.lang.Object newInstance,
Encoder out) |
protected Expression |
instantiate(java.lang.Object oldInstance,
Encoder out) |
protected boolean |
mutatesTo(java.lang.Object oldInstance,
java.lang.Object newInstance) |
writeObjectpublic DefaultPersistenceDelegate()
public DefaultPersistenceDelegate(java.lang.String[] constructorPropertyNames)
The implementation reads the mentioned properties from the Bean instance and applies it in the given order to a corresponding constructor.
constructorPropertyNames - The properties the Bean's constructor
should be given to.protected boolean mutatesTo(java.lang.Object oldInstance, java.lang.Object newInstance)
mutatesTo in class PersistenceDelegateprotected Expression instantiate(java.lang.Object oldInstance, Encoder out)
instantiate in class PersistenceDelegateprotected void initialize(java.lang.Class<?> type, java.lang.Object oldInstance, java.lang.Object newInstance, Encoder out)
initialize in class PersistenceDelegate