com.arjuna.ats.jts
Class OTSManager

java.lang.Object
  extended bycom.arjuna.ats.jts.OTSManager

public class OTSManager
extends java.lang.Object

This class is essentially here for convenience purposes, and until all ORBs provide a means to set their initial references for Current and the TransactionFactory.

Since:
JTS 1.0.
Version:
$Id: OTSManager.java 2342 2006-03-30 13:06:17Z $
Author:
Mark Little (mark_little@hp.com)

Field Summary
static int serviceId
           
 
Constructor Summary
OTSManager()
           
 
Method Summary
static void destroyControl(org.omg.CosTransactions.Control control)
          Destroy the transaction control.
static void destroyControl(com.arjuna.ats.internal.jts.orbspecific.ControlImple control)
          Used to destroy a transaction control.
static com.arjuna.ats.internal.jts.orbspecific.TransactionFactoryImple factory()
           
static org.omg.CosTransactions.Current get_current()
           
static org.omg.CosTransactions.TransactionFactory get_factory()
           
static int getLocalSlotId()
           
static int getReceivedSlotId()
           
static void setLocalSlotId(int slotId)
           
static void setORB(ORB theOrb)
           
static void setPOA(OA thePoa)
           
static void setReceivedSlotId(int slotId)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

serviceId

public static final int serviceId
See Also:
Constant Field Values
Constructor Detail

OTSManager

public OTSManager()
Method Detail

get_current

public static org.omg.CosTransactions.Current get_current()
                                                   throws org.omg.CORBA.SystemException
Returns:
the Current object.
Throws:
org.omg.CORBA.SystemException

factory

public static com.arjuna.ats.internal.jts.orbspecific.TransactionFactoryImple factory()
                                                                               throws org.omg.CORBA.SystemException
Returns:
the TransactionFactory object implementation. This has the advantage of not needing to register the object withm the ORB, which can affect performance.
Throws:
org.omg.CORBA.SystemException

get_factory

public static org.omg.CosTransactions.TransactionFactory get_factory()
                                                              throws org.omg.CORBA.SystemException
Returns:
the TransactionFactory object.
Throws:
org.omg.CORBA.SystemException

destroyControl

public static void destroyControl(com.arjuna.ats.internal.jts.orbspecific.ControlImple control)
                           throws com.arjuna.ArjunaOTS.ActiveTransaction,
                                  com.arjuna.ArjunaOTS.ActiveThreads,
                                  com.arjuna.ArjunaOTS.BadControl,
                                  com.arjuna.ArjunaOTS.Destroyed,
                                  org.omg.CORBA.SystemException
Used to destroy a transaction control. Normally garbage collection will take care of this, but in certain circumstances (e.g., a context is propagated implicitly but we do not use interposition and we have to manufacture a local control object) it is not possible for the OTS to know when controls can be removed. This is a problem with the specification and CORBA in general.

Throws:
com.arjuna.ArjunaOTS.ActiveTransaction
com.arjuna.ArjunaOTS.ActiveThreads
com.arjuna.ArjunaOTS.BadControl
com.arjuna.ArjunaOTS.Destroyed
org.omg.CORBA.SystemException

destroyControl

public static void destroyControl(org.omg.CosTransactions.Control control)
                           throws com.arjuna.ArjunaOTS.ActiveTransaction,
                                  com.arjuna.ArjunaOTS.ActiveThreads,
                                  com.arjuna.ArjunaOTS.BadControl,
                                  com.arjuna.ArjunaOTS.Destroyed,
                                  org.omg.CORBA.SystemException
Destroy the transaction control.

Throws:
com.arjuna.ArjunaOTS.ActiveTransaction
com.arjuna.ArjunaOTS.ActiveThreads
com.arjuna.ArjunaOTS.BadControl
com.arjuna.ArjunaOTS.Destroyed
org.omg.CORBA.SystemException

setLocalSlotId

public static final void setLocalSlotId(int slotId)

getLocalSlotId

public static final int getLocalSlotId()

setReceivedSlotId

public static final void setReceivedSlotId(int slotId)

getReceivedSlotId

public static final int getReceivedSlotId()

setORB

public static final void setORB(ORB theOrb)

setPOA

public static final void setPOA(OA thePoa)