|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.nakedobjects.runtime.transaction.NakedObjectTransactionAbstract
org.nakedobjects.runtime.persistence.objectstore.transaction.ObjectStoreTransaction
public class ObjectStoreTransaction
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface org.nakedobjects.runtime.transaction.NakedObjectTransaction |
|---|
NakedObjectTransaction.State |
| Constructor Summary | |
|---|---|
ObjectStoreTransaction(NakedObjectTransactionManager transactionManager,
MessageBroker messageBroker,
UpdateNotifier updateNotifier,
ObjectStoreTransactionManagement objectStore)
|
|
| Method Summary | |
|---|---|
void |
addCommand(PersistenceCommand command)
Add the non-null command to the list of commands to execute at the end of the transaction. |
protected ToString |
appendTo(ToString str)
|
void |
doAbort()
Mandatory hook method for subclasses to perform additional processing on abort. |
void |
doFlush()
Mandatory hook method for subclasses to persist all pending changes. |
| Methods inherited from class org.nakedobjects.runtime.transaction.NakedObjectTransactionAbstract |
|---|
abort, commit, flush, getAbortCause, getMessageBroker, getState, getTransactionManager, getUpdateNotifier, setAbortCause, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public ObjectStoreTransaction(NakedObjectTransactionManager transactionManager,
MessageBroker messageBroker,
UpdateNotifier updateNotifier,
ObjectStoreTransactionManagement objectStore)
| Method Detail |
|---|
public void addCommand(PersistenceCommand command)
public void doAbort()
NakedObjectTransactionAbstract
After this call the state will always be set to
State#ABORTED, irrespective of whether an exception is thrown or not.
doAbort in class NakedObjectTransactionAbstractpublic void doFlush()
NakedObjectTransactionAbstract
Called by both NakedObjectTransactionAbstract.commit() and by NakedObjectTransactionAbstract.flush():
| called from | next state if ok | next state if exception |
|---|---|---|
NakedObjectTransactionAbstract.commit() | State#COMMITTED | State#ABORTED |
NakedObjectTransactionAbstract.flush() | State#IN_PROGRESS | State#MUST_ABORT |
doFlush in class NakedObjectTransactionAbstractprotected ToString appendTo(ToString str)
appendTo in class NakedObjectTransactionAbstract
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||