Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

FactoryLibrary_ltdl Class Reference

List of all members.

Detailed Description

An edu::utah::pces::FactoryLibrary implementation that uses libltdl.

See also:
AllupImpl

libtool

Definition at line 39 of file FactoryLibrary_ltdl.hh.

Public Member Functions

virtual ~FactoryLibrary_ltdl (void)
 Deconstruct a FactoryLibrary_ltdl object.
virtual char * Name (void) throw (CORBA::SystemException)
 
Returns:
The name of this library.

virtual CORBA::Long Hey (const edu::utah::pces::ArgV &args, CORBA::String_out o, CORBA::String_out e) throw (CORBA::SystemException)
 
See also:
HeyParser
Parameters:
args The command line arguments that the library should act on. Note that this includes the command name and server IOR!
o String to send to standard output.
e String to send to standard error.

virtual PortableServer::POA_ptr _default_POA (void) throw (CORBA::SystemException)

Static Public Member Functions

edu::utah::pces::FactoryLibrary_ptr OpenLibrary (PortableServer::POA_ptr poa, const char *name) throw (edu::utah::pces::NoSuchLibrary, CORBA::SystemException)
 Open a library with the given name.
void Shutdown (void)
 Shutdown the library interface.

Protected Member Functions

 FactoryLibrary_ltdl (PortableServer::POA_ptr poa, const char *name, lt_dlhandle dlh, factory_method_t fm)
 Construct a FactoryLibrary_ltdl object with the given arguments.

Private Member Functions

 FactoryLibrary_ltdl (const char *name, lt_dlhandle library, factory_method_t fm)
 Construct a FactoryLibrary_ltdl object with the given values.

Private Attributes

PortableServer::POA_var fl_POA
 The POA this object was activated under and any new objects should be activated under.
CORBA::String_var fl_Name
 The name of the library being managed by this object.
unsigned int fl_OpenCount
 The number of times this library has been opened.
lt_dlhandle fl_Library
 Libtool handle on the shared library.
factory_method_t fl_Method
 Cached reference to the factory_method_t in the shared library.

Static Private Attributes

map< string, FactoryLibrary_ltdl * > open_libraries
 Map of library names to FactoryLibrary_ltdl objects.
CORBA::ORB_var orb
 Cached reference to the ORB object.


Constructor & Destructor Documentation

FactoryLibrary_ltdl::FactoryLibrary_ltdl PortableServer::POA_ptr  poa,
const char *  name,
lt_dlhandle  dlh,
factory_method_t  fm
[protected]
 

Construct a FactoryLibrary_ltdl object with the given arguments.

Parameters:
poa The POA this object was activated under and any new objects should be activated under.
name The name of this shared library.
dlh The libtool handle on the shared library.
fm The library's factory_method_t.

Definition at line 40 of file FactoryLibrary_ltdl.cc.

References require.

FactoryLibrary_ltdl::FactoryLibrary_ltdl const char *  name,
lt_dlhandle  library,
factory_method_t  fm
[private]
 

Construct a FactoryLibrary_ltdl object with the given values.

Parameters:
name The name of the library.
library The libtool handle on the library.
fm The reference to the library's factory_method_t function.


Member Function Documentation

virtual PortableServer::POA_ptr FactoryLibrary_ltdl::_default_POA void   )  throw (CORBA::SystemException) [inline, virtual]
 

Exceptions:
CORBA::BAD_INV_ORDER when called. This object should always be activated under a single threaded POA.

Definition at line 84 of file FactoryLibrary_ltdl.hh.

edu::utah::pces::FactoryLibrary_ptr FactoryLibrary_ltdl::OpenLibrary PortableServer::POA_ptr  poa,
const char *  name
throw (edu::utah::pces::NoSuchLibrary, CORBA::SystemException) [static]
 

Open a library with the given name.

Parameters:
poa The POA to use when activating any new objects.
name The name of the library.
Returns:
A CORBA object reference to the new FactoryLibrary_ltdl object.
Exceptions:
edu::utah::pces::NoSuchLibrary if the library could not be found or loaded.

Definition at line 112 of file FactoryLibrary_ltdl.cc.

References __XSTRING, FACTORY_METHOD_SYMBOL, factory_method_t, fl_OpenCount, open_libraries, orb, and require.

Referenced by AllupImpl::OpenLibrary().


The documentation for this class was generated from the following files:
Generated on Fri Oct 22 07:51:00 2004 for CPU Broker by  doxygen 1.3.9.1