|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.dasein.persist.Memento<K>
public class Memento<K>
Provides state translation for persistent objects. By capturing
the state information automatically in a hash map, this class
decouples the implementation from its data structures in the persistent
store.
Last modified: $Date: 2006/02/18 22:47:10 $
| Constructor Summary | |
|---|---|
Memento(K p)
Constructs a memento for the specified persistent object. |
|
| Method Summary | |
|---|---|
Map<String,Object> |
getState()
|
void |
load(Map<String,Object> data)
Loads the data values into the persistent object. |
void |
save(Map<String,Object> data)
Saves the current state of the persistent object. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Memento(K p)
p - the persistent object| Method Detail |
|---|
public Map<String,Object> getState()
public void load(Map<String,Object> data)
throws PersistenceException
data - the data to load into the persistent object
PersistenceException - values from
the data map could not be loaded into the persistent object
public void save(Map<String,Object> data)
throws PersistenceException
data - values that should be used to override any
current state
PersistenceException - an error occurred
reading values from the persistent object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||