jPOS 1.6.1 API Documentation

org.jpos.transaction.participant
Class Join

java.lang.Object
  extended by org.jpos.transaction.participant.Join
All Implemented Interfaces:
Configurable, XmlConfigurable, AbortParticipant, TransactionConstants, TransactionParticipant

public class Join
extends java.lang.Object
implements TransactionConstants, AbortParticipant, Configurable, XmlConfigurable


Nested Class Summary
static class Join.Runner
           
 
Field Summary
 
Fields inherited from interface org.jpos.transaction.TransactionConstants
ABORTED, NO_JOIN, PAUSE, PREPARED, READONLY, RETRY
 
Constructor Summary
Join()
           
 
Method Summary
 void abort(long id, java.io.Serializable o)
          Called by TransactionManager upon transaction commit.
 void commit(long id, java.io.Serializable o)
          Called by TransactionManager upon transaction commit.
 int prepare(long id, java.io.Serializable o)
          Called by TransactionManager in preparation for a transaction
 int prepareForAbort(long id, java.io.Serializable o)
          Called by TransactionManager in preparation for a transaction that is known to abort.
 void setConfiguration(Configuration cfg)
           
 void setConfiguration(org.jdom.Element e)
           
 void setTransactionManager(TransactionManager mgr)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Join

public Join()
Method Detail

prepare

public int prepare(long id,
                   java.io.Serializable o)
Description copied from interface: TransactionParticipant
Called by TransactionManager in preparation for a transaction

Specified by:
prepare in interface TransactionParticipant
Parameters:
id - the Transaction identifier
o - transaction context
Returns:
PREPARED or ABORTED (| NO_JOIN | READONLY)

prepareForAbort

public int prepareForAbort(long id,
                           java.io.Serializable o)
Description copied from interface: AbortParticipant
Called by TransactionManager in preparation for a transaction that is known to abort.

Specified by:
prepareForAbort in interface AbortParticipant
Parameters:
id - the Transaction identifier
o - transaction context
Returns:
0 [| NO_JOIN | READONLY)

commit

public void commit(long id,
                   java.io.Serializable o)
Description copied from interface: TransactionParticipant
Called by TransactionManager upon transaction commit. Warning: implementation should be able to handle multiple calls with the same transaction id (rare crash recovery)

Specified by:
commit in interface TransactionParticipant
Parameters:
id - the Transaction identifier
o - transaction context

abort

public void abort(long id,
                  java.io.Serializable o)
Description copied from interface: TransactionParticipant
Called by TransactionManager upon transaction commit. Warning: implementation should be able to handle multiple calls with the same transaction id (rare crash recovery)

Specified by:
abort in interface TransactionParticipant
Parameters:
id - the Transaction identifier
o - transaction context

setConfiguration

public void setConfiguration(Configuration cfg)
Specified by:
setConfiguration in interface Configurable
Parameters:
cfg - Configuration object

setConfiguration

public void setConfiguration(org.jdom.Element e)
                      throws ConfigurationException
Specified by:
setConfiguration in interface XmlConfigurable
Throws:
ConfigurationException

setTransactionManager

public void setTransactionManager(TransactionManager mgr)

jPOS.org