org.h2.store
Class PageStoreInDoubtTransaction

java.lang.Object
  extended by org.h2.store.PageStoreInDoubtTransaction
All Implemented Interfaces:
InDoubtTransaction

public class PageStoreInDoubtTransaction
extends java.lang.Object
implements InDoubtTransaction

Represents an in-doubt transaction (a transaction in the prepare phase).


Field Summary
 
Fields inherited from interface org.h2.store.InDoubtTransaction
COMMIT, IN_DOUBT, ROLLBACK
 
Constructor Summary
PageStoreInDoubtTransaction(PageStore store, int sessionId, int pos, java.lang.String transaction)
          Create a new in-doubt transaction info object.
 
Method Summary
 java.lang.String getState()
          Get the state of this transaction as a text.
 java.lang.String getTransactionName()
          Get the name of the transaction.
 void setState(int state)
          Change the state of this transaction.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PageStoreInDoubtTransaction

public PageStoreInDoubtTransaction(PageStore store,
                                   int sessionId,
                                   int pos,
                                   java.lang.String transaction)
Create a new in-doubt transaction info object.

Parameters:
store - the page store
sessionId - the session id
pos - the position
transaction - the transaction name
Method Detail

setState

public void setState(int state)
Description copied from interface: InDoubtTransaction
Change the state of this transaction. This will also update the transaction log.

Specified by:
setState in interface InDoubtTransaction
Parameters:
state - the new state

getState

public java.lang.String getState()
Description copied from interface: InDoubtTransaction
Get the state of this transaction as a text.

Specified by:
getState in interface InDoubtTransaction
Returns:
the transaction state text

getTransactionName

public java.lang.String getTransactionName()
Description copied from interface: InDoubtTransaction
Get the name of the transaction.

Specified by:
getTransactionName in interface InDoubtTransaction
Returns:
the transaction name