Package com.arjuna.orbportability
Class OA
java.lang.Object
com.arjuna.orbportability.OA
An attempt at some ORB portable ways of interacting with the OA. NOTE:
initPOA *must* be called if you want to use the pre- and post- initialisation
mechanisms.
- Since:
- JTS 2.1.
- Version:
- $Id: OA.java 2342 2006-03-30 13:06:17Z $
- Author:
- Mark Little (mark@arjuna.com)
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
void
void
abstract org.omg.CORBA.Object
corbaReference
(org.omg.PortableServer.Servant obj) org.omg.CORBA.Object
corbaReference
(org.omg.PortableServer.Servant obj, org.omg.PortableServer.POA poa) abstract void
destroy()
static RootOA
Retrieve an OA instance given a unique name, if an OA instance with this name doesn't exist then create it.void
init()
Ensure that all OA specific initialisation is done even if the programmer uses the OA specific init routines.void
initOA()
void
void
initPOA()
void
abstract boolean
objectIsReady
(org.omg.PortableServer.Servant obj) abstract boolean
objectIsReady
(org.omg.PortableServer.Servant obj, byte[] id) Register the object with the ORB.protected void
performPostInit
(String oaName) Loads and runs the configured post-initialisation classesprotected void
performPostSet
(String oaName) protected void
performPreInit
(String oaName) Loads and runs the configured pre-initialisation classesorg.omg.PortableServer.POA
org.omg.PortableServer.POA
rootPoa()
void
run()
void
Place the server into a state where it can begin to accept requests for objects from clients.boolean
void
setPOA
(org.omg.PortableServer.POA p) abstract boolean
shutdownObject
(org.omg.CORBA.Object obj) Dispose of the object, i.e., unregister it from the ORB.abstract boolean
shutdownObject
(org.omg.PortableServer.Servant obj)
-
Field Details
-
_defaultAdapterName
-
_oaName
-
_preOAShutdown
-
_postOAShutdown
-
_preOAInitProperty
-
_postOAInitProperty
-
-
Method Details
-
init
public void init() throws org.omg.CORBA.SystemExceptionEnsure that all OA specific initialisation is done even if the programmer uses the OA specific init routines. This method does not need to be called if using initOA methods.- Throws:
org.omg.CORBA.SystemException
- Since:
- JTS 2.1.1.
-
initPOA
public void initPOA() throws org.omg.CORBA.ORBPackage.InvalidName, org.omg.CORBA.SystemException- Throws:
org.omg.CORBA.ORBPackage.InvalidName
org.omg.CORBA.SystemException
-
getAssociatedORB
-
setPOA
public void setPOA(org.omg.PortableServer.POA p) throws org.omg.CORBA.SystemException - Throws:
org.omg.CORBA.SystemException
-
performPreInit
Loads and runs the configured pre-initialisation classes -
performPostSet
-
performPostInit
Loads and runs the configured post-initialisation classes -
initPOA
public void initPOA(String[] args) throws org.omg.CORBA.ORBPackage.InvalidName, org.omg.CORBA.SystemException - Throws:
org.omg.CORBA.ORBPackage.InvalidName
org.omg.CORBA.SystemException
-
createPOA
public ChildOA createPOA(String adapterName, org.omg.CORBA.Policy[] policies) throws org.omg.PortableServer.POAPackage.AdapterAlreadyExists, org.omg.PortableServer.POAPackage.InvalidPolicy, org.omg.PortableServer.POAManagerPackage.AdapterInactive - Throws:
org.omg.PortableServer.POAPackage.AdapterAlreadyExists
org.omg.PortableServer.POAPackage.InvalidPolicy
org.omg.PortableServer.POAManagerPackage.AdapterInactive
-
initOA
public void initOA() throws org.omg.CORBA.ORBPackage.InvalidName, org.omg.CORBA.SystemException- Throws:
org.omg.CORBA.ORBPackage.InvalidName
org.omg.CORBA.SystemException
-
initOA
public void initOA(String[] args) throws org.omg.CORBA.ORBPackage.InvalidName, org.omg.CORBA.SystemException - Throws:
org.omg.CORBA.ORBPackage.InvalidName
org.omg.CORBA.SystemException
-
addAttribute
-
destroy
public abstract void destroy() throws org.omg.CORBA.SystemException- Throws:
org.omg.CORBA.SystemException
-
rootPoa
public org.omg.PortableServer.POA rootPoa() -
poa
-
setPoa
-
addPreShutdown
-
addPostShutdown
-
corbaReference
public abstract org.omg.CORBA.Object corbaReference(org.omg.PortableServer.Servant obj) - Returns:
- a CORBA object reference for the Servant/Implementation.
-
corbaReference
public org.omg.CORBA.Object corbaReference(org.omg.PortableServer.Servant obj, org.omg.PortableServer.POA poa) -
objectIsReady
public abstract boolean objectIsReady(org.omg.PortableServer.Servant obj, byte[] id) throws org.omg.CORBA.SystemException Register the object with the ORB.- Throws:
org.omg.CORBA.SystemException
-
objectIsReady
public abstract boolean objectIsReady(org.omg.PortableServer.Servant obj) throws org.omg.CORBA.SystemException - Throws:
org.omg.CORBA.SystemException
-
shutdownObject
public abstract boolean shutdownObject(org.omg.CORBA.Object obj) Dispose of the object, i.e., unregister it from the ORB. -
shutdownObject
public abstract boolean shutdownObject(org.omg.PortableServer.Servant obj) -
run
Place the server into a state where it can begin to accept requests for objects from clients.- Throws:
org.omg.CORBA.SystemException
-
run
public void run() throws org.omg.CORBA.SystemException- Throws:
org.omg.CORBA.SystemException
-
getRootOA
Retrieve an OA instance given a unique name, if an OA instance with this name doesn't exist then create it.- Parameters:
associatedORB
- The ORB this OA is being created for.- Returns:
- The OA instance referred to by the name given.
-