edu.stanford.slac.aida.lib.util.common
Class _PersistentDaObject

java.lang.Object
  extended by edu.stanford.slac.aida.lib.util.common._DaObjectBase
      extended by edu.stanford.slac.aida.lib.util.common._DaObject
          extended by edu.stanford.slac.aida.lib.util.common._PersistentDaObject

public class _PersistentDaObject
extends _DaObject

Data Access Object for persistent servers. This object is a sub- class of _DaObject and is not related to _PersistentDaObjectBase. Implemented in this fashion due to unavailability of multiple inheritance in java. Sadly corespondence between methods in _PersistentDaObject and _PersistentDaObjectBase must be maintained manually.

Version:
24-Jun-2002, George McIntyre, 31-Jul-2005, Greg White (greg): added NO_IMPLICIT_ACTIVATION policy to correct init for "perisistent" servers.

Field Summary
 org.omg.PortableServer.POA m_childPersistentPOA
          Persistent POA
 java.lang.String m_childPersistentPOAName
          Persistent POA Name
static java.lang.String PDO_SERVER_NAME
          Default name if cannot be determined from either command line or properties Also used by DaObject to determine the Persistent name for the DaServer
 
Fields inherited from class edu.stanford.slac.aida.lib.util.common._DaObject
m_args
 
Fields inherited from class edu.stanford.slac.aida.lib.util.common._DaObjectBase
DAO_PROPS, m_consumerPOA, m_err, m_event_channel, m_orb, m_POA_manager, m_props, m_rootPOA
 
Constructor Summary
_PersistentDaObject()
          Constructs a _PersistentDaObject without EventService
_PersistentDaObject(java.lang.String[] args, java.lang.String childPersistentPOAName)
          Constructs a _PersistentDaObject without EventService
_PersistentDaObject(java.lang.String[] args, java.lang.String childPersistentPOAName, boolean events)
          Constructs a _PersistentDaObject including EventService initialization if desired
 
Method Summary
 org.omg.PortableServer.POA getChildPersistentPOA()
           
protected  void init(java.lang.String childPersistentPOAName)
          Initialises a _PersistentDaObject.
 void terminate()
          Shuts down the server via a call to orb.destroy()
 
Methods inherited from class edu.stanford.slac.aida.lib.util.common._DaObject
concatArgs, getAidaServerI, getArgs, getNameServerI, GetObjRef, getTargetRef, init, StoreObjRef, toStringArgs
 
Methods inherited from class edu.stanford.slac.aida.lib.util.common._DaObjectBase
EventConnect, getNameServerIOR, getORB, getPPConsumer, initEventService, setNameServerIOR, Start
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PDO_SERVER_NAME

public static final java.lang.String PDO_SERVER_NAME
Default name if cannot be determined from either command line or properties Also used by DaObject to determine the Persistent name for the DaServer

See Also:
Constant Field Values

m_childPersistentPOA

public org.omg.PortableServer.POA m_childPersistentPOA
Persistent POA


m_childPersistentPOAName

public java.lang.String m_childPersistentPOAName
Persistent POA Name

Constructor Detail

_PersistentDaObject

public _PersistentDaObject()
                    throws edu.stanford.slac.except.AidaInitException
Constructs a _PersistentDaObject without EventService

Throws:
edu.stanford.slac.except.AidaInitException

_PersistentDaObject

public _PersistentDaObject(java.lang.String[] args,
                           java.lang.String childPersistentPOAName)
                    throws edu.stanford.slac.except.AidaInitException
Constructs a _PersistentDaObject without EventService

Parameters:
args - a list of CORBA properties name value pairs
childPersistentPOAName - a text string with which to name the child POA created.
Throws:
edu.stanford.slac.except.AidaInitException

_PersistentDaObject

public _PersistentDaObject(java.lang.String[] args,
                           java.lang.String childPersistentPOAName,
                           boolean events)
                    throws edu.stanford.slac.except.AidaInitException
Constructs a _PersistentDaObject including EventService initialization if desired

Parameters:
args - a list of CORBA properties name value pairs
childPersistentPOAName - a text string with which to name the child POA created.
events - whether to initialize EventService.
Throws:
edu.stanford.slac.except.AidaInitException
Method Detail

getChildPersistentPOA

public org.omg.PortableServer.POA getChildPersistentPOA()

init

protected void init(java.lang.String childPersistentPOAName)
             throws edu.stanford.slac.except.AidaInitException
Initialises a _PersistentDaObject. Notably, creates a policy to govern its existence based on the user id associated with the calling process

Overrides:
init in class _DaObjectBase
Throws:
edu.stanford.slac.except.AidaInitException - up-translated exception from CORBA initialization.

terminate

public void terminate()
               throws edu.stanford.slac.except.TerminateException
Shuts down the server via a call to orb.destroy()

Throws:
edu.stanford.slac.except.TerminateException - error terminating