summaryrefslogtreecommitdiff
path: root/TAO/orbsvcs/ImplRepo_Service/ImplRepo_i.h
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/orbsvcs/ImplRepo_Service/ImplRepo_i.h')
-rw-r--r--TAO/orbsvcs/ImplRepo_Service/ImplRepo_i.h139
1 files changed, 48 insertions, 91 deletions
diff --git a/TAO/orbsvcs/ImplRepo_Service/ImplRepo_i.h b/TAO/orbsvcs/ImplRepo_Service/ImplRepo_i.h
index 009ec7aeb52..f3470b5e0de 100644
--- a/TAO/orbsvcs/ImplRepo_Service/ImplRepo_i.h
+++ b/TAO/orbsvcs/ImplRepo_Service/ImplRepo_i.h
@@ -49,7 +49,7 @@ public:
virtual CORBA::Boolean unknown_adapter (PortableServer::POA_ptr parent,
const char *name,
CORBA_Environment &ACE_TRY_ENV
- = TAO_default_environment ());
+ = CORBA_Environment::default_environment ());
// Called by the POA when the incoming requested object/POA isn't found. This will
// create POAs when needed and will also put a DSI object (IR_Forwarder) in that POA
// as a default servant to handle that request
@@ -61,13 +61,14 @@ private:
// POA Manager
};
-class ImplRepo_i : public POA_ImplementationRepository::Administration
+class ImplRepo_i : public POA_Implementation_Repository
{
// = TITLE
// Implementation Repository
//
// = DESCRIPTION
- // This provides the interface to Administer the Implementation Repository.
+ // This provides the interface to communicate directly with the
+ // Implementation Repository.
public:
// = Constructor and destructor
ImplRepo_i (void);
@@ -75,78 +76,70 @@ public:
// = Interface methods
- virtual void activate_server (const char * server,
- CORBA::Environment &ACE_TRY_ENV = TAO_default_environment ())
+ virtual CORBA::Object_ptr activate_object (CORBA::Object_ptr obj,
+ CORBA_Environment &ACE_TRY_ENV
+ = TAO_default_environment ())
ACE_THROW_SPEC ((CORBA::SystemException,
- ImplementationRepository::Administration::NotFound,
- ImplementationRepository::Administration::CannotActivate));
+ Implementation_Repository::Not_Found,
+ Implementation_Repository::Cannot_Activate));
+ // Starts up the server containing the object <obj> if not already running.
+
+ virtual Implementation_Repository::INET_Addr *activate_server (const char *server,
+ CORBA::Environment &env = TAO_default_environment ())
+ ACE_THROW_SPEC ((CORBA::SystemException,
+ Implementation_Repository::Not_Found,
+ Implementation_Repository::Cannot_Activate));
// Starts up the server <server> if not already running.
virtual void register_server (const char *server,
- const ImplementationRepository::StartupOptions &options,
- CORBA_Environment &ACE_TRY_ENV = TAO_default_environment ())
+ const Implementation_Repository::Process_Options &options,
+ CORBA_Environment &ACE_TRY_ENV
+ = TAO_default_environment ())
ACE_THROW_SPEC ((CORBA::SystemException,
- ImplementationRepository::Administration::AlreadyRegistered));
- // Adds the server to the repository and registers the startup information about
- // the server <server>.
+ Implementation_Repository::Already_Registered));
+ // Adds the server to the repository and registers the startup
+ // information about the server <server>.
virtual void reregister_server (const char *server,
- const ImplementationRepository::StartupOptions &options,
- CORBA_Environment &ACE_TRY_ENV = TAO_default_environment ())
+ const Implementation_Repository::Process_Options &options,
+ CORBA_Environment &ACE_TRY_ENV
+ = TAO_default_environment ())
ACE_THROW_SPEC ((CORBA::SystemException));
// Updates the startup information about the server <server>.
virtual void remove_server (const char *server,
- CORBA_Environment &ACE_TRY_ENV = TAO_default_environment ())
+ CORBA_Environment &ACE_TRY_ENV
+ = TAO_default_environment ())
ACE_THROW_SPEC ((CORBA::SystemException,
- ImplementationRepository::Administration::NotFound));
+ Implementation_Repository::Not_Found));
// Removes the server <server> from the repository.
- virtual void shutdown_server (const char * server,
- CORBA::Environment &ACE_TRY_ENV = TAO_default_environment ())
- ACE_THROW_SPEC ((CORBA::SystemException,
- ImplementationRepository::Administration::NotFound));
- // Attempts to gracefully shut down the server, if that fails, will try
- // to do it ungracefully.
-
- virtual ImplementationRepository::Address *
- server_is_running (const char * server,
- const ImplementationRepository::Address &addr,
- ImplementationRepository::ServerObject_ptr server_object,
- CORBA::Environment &ACE_TRY_ENV = TAO_default_environment ())
+ virtual Implementation_Repository::INET_Addr
+ *server_is_running (const char *server,
+ const Implementation_Repository::INET_Addr &addr,
+ CORBA::Object_ptr ping,
+ CORBA_Environment &ACE_TRY_ENV
+ = TAO_default_environment ())
ACE_THROW_SPEC ((CORBA::SystemException,
- ImplementationRepository::Administration::NotFound));
- // Called by the server to update transient information such as current location of
- // the <server> and its ServerObject.
+ Implementation_Repository::Not_Found));
+ // Called by the server to update transient information such as
+ // current location of the <server> and its ping object.
virtual void server_is_shutting_down (const char * server,
- CORBA_Environment &ACE_TRY_ENV = TAO_default_environment ())
+ CORBA_Environment &ACE_TRY_ENV
+ = TAO_default_environment ())
ACE_THROW_SPEC ((CORBA::SystemException,
- ImplementationRepository::Administration::NotFound));
- // What the server should call before it shuts down.
-
- virtual void find (const char * server,
- ImplementationRepository::ServerInformation_out info,
- CORBA::Environment &ACE_TRY_ENV = TAO_default_environment ())
- ACE_THROW_SPEC ((CORBA::SystemException,
- ImplementationRepository::Administration::NotFound));
- // Returns the startup information for a server
-
- virtual void list (CORBA::ULong how_many,
- ImplementationRepository::ServerInformationList_out server_list,
- ImplementationRepository::ServerInformationIterator_out server_iterator,
- CORBA::Environment &ACE_TRY_ENV = TAO_default_environment ())
- ACE_THROW_SPEC ((CORBA::SystemException));
- // Used to access the list of servers registered. May also return an
- // iterator which can be used to access more than <how_many> of them.
+ Implementation_Repository::Not_Found));
+ // What the server should call before it shutsdown.
// = Other methods
- int init (int argc, char **argv,
- CORBA_Environment &ACE_TRY_ENV = TAO_default_environment ());
+ int init (int argc, char **argv,
+ CORBA_Environment &ACE_TRY_ENV
+ = TAO_default_environment ());
// Initialize the Server state - parsing arguments and waiting.
- int run (CORBA_Environment &ACE_TRY_ENV = TAO_default_environment ());
+ int run (CORBA_Environment &ACE_TRY_ENV = CORBA_Environment::default_environment ());
// Runs the orb.
CORBA::String get_forward_host (const char *server);
@@ -162,7 +155,7 @@ private:
IR_Adapter_Activator *activator_;
// Used for the forwarding of any type of POA.
- Server_Repository repository_;
+ Repository repository_;
// Repository containing information about each server.
TAO_ORB_Manager orb_manager_;
@@ -181,13 +174,7 @@ private:
// The command line arguments.
};
-class IR_Forwarder: public PortableServer::DynamicImplementation
- // = TITLE
- // Implementation Repository Forwarder
- //
- // = DESCRIPTION
- // This class is provides a DSI implementation that is used to handle
- // arbitrary calls and forward them to the correct place.
+class IR_Forwarder: public PortableServer::DynamicImplementation
{
public:
IR_Forwarder (CORBA::ORB_ptr orb_ptr,
@@ -203,7 +190,7 @@ public:
CORBA::RepositoryId _primary_interface (const PortableServer::ObjectId &oid,
PortableServer::POA_ptr poa,
- CORBA::Environment &env = TAO_default_environment ());
+ CORBA::Environment &env);
// DynamicImplementation stuff
private:
@@ -217,34 +204,4 @@ private:
// POA reference.
};
-class IR_Iterator : public POA_ImplementationRepository::ServerInformationIterator
-{
-public:
- IR_Iterator (Server_Repository::HASH_IR_ITER *iterator,
- PortableServer::POA_ptr poa);
- // Constructor
- // Ownership of iterator is transfered to this class (we'll delete it)
-
- ~IR_Iterator ();
- // Destructor
-
- virtual CORBA::Boolean next_n (CORBA::ULong how_many,
- ImplementationRepository::ServerInformationList_out server_list,
- CORBA::Environment &ACE_TRY_ENV = CORBA::Environment::default_environment ())
- ACE_THROW_SPEC ((CORBA::SystemException));
- // Returns the next list of up to <how_many> servers. If empty, will return
- // false.
-
- virtual void destroy (CORBA::Environment &ACE_TRY_ENV = CORBA::Environment::default_environment ())
- ACE_THROW_SPEC ((CORBA::SystemException));
- // Destroys the iterator.
-
-private:
- Server_Repository::HASH_IR_ITER *iterator_;
- // Our very own iterator for transversing the server repository.
-
- PortableServer::POA_var poa_;
- // Our lovely POA.
-};
-
#endif /* IMPLREPO_I_H */