|
qflib 0.99 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.qfs.lib.transaction.CommitableStateChange
As part of a Transaction
the CommitableStateChange
tells a StateHolder
when to save and restore
its state.
Field Summary | |
protected java.lang.Object |
saved
Some information handed back by saveState . |
protected StateHolder |
stateHolder
The StateHolder whose state is about to change. |
Constructor Summary | |
CommitableStateChange(StateHolder stateHolder)
Create a new CommitableStateChange. |
Method Summary | |
void |
commit()
Tell the StateHolder that its saved state will no longer be needed. |
void |
rollback()
Undo the StateHolder's change of state. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected StateHolder stateHolder
StateHolder
whose state is about to change.
protected java.lang.Object saved
saveState
.
Constructor Detail |
public CommitableStateChange(StateHolder stateHolder)
stateHolder
- The StateHolder whose state is about to change.Method Detail |
public void commit() throws FatalTransactionException
commit
in interface Commitable
FatalTransactionException
- If the StateHolder fails to commit
its state in a way that corrupts the whole Transaction.public void rollback() throws FatalTransactionException
rollback
in interface Commitable
FatalTransactionException
- If the StateHolder fails to restore
its state in a way that corrupts the whole Transaction.
|
qflib 0.99 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |