Merge pull request #1844 from jrw972/monterey
[ACE_TAO.git] / TAO / orbsvcs / ImplRepo_Service / Adapter_Activator.h
blob6c09829728118cdfa0a2f6f2fb7fbb79166f83d7
1 // -*- C++ -*-
2 //=============================================================================
3 /**
4 * @file Adapter_Activator.h
6 * @brief This class implements ImR's Adapter Activator.
8 * @author Darrell Brunsch <brunsch@cs.wustl.edu>
9 */
10 //=============================================================================
12 #ifndef IMR_ADAPTER_ACTIVATOR_H
13 #define IMR_ADAPTER_ACTIVATOR_H
15 #include "tao/PortableServer/PortableServer.h"
16 #include "tao/PortableServer/AdapterActivatorC.h"
18 #if !defined (ACE_LACKS_PRAGMA_ONCE)
19 # pragma once
20 #endif /* ACE_LACKS_PRAGMA_ONCE */
22 #include "tao/LocalObject.h"
24 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
25 class TAO_ServantBase;
26 TAO_END_VERSIONED_NAMESPACE_DECL
28 /**
29 * @class ImR_Adapter_Activator
31 * @brief Implementation Repository Adapter Activator
33 * Part of the DefaultServant/AdapterActivator combination that is used to
34 * receive forwardable requests from clients. The Adapter Activator creates
35 * the POA structure that the request expects. For each POA created, the
36 * same DefaultServant will be registered in each one.
38 class ImR_Adapter
39 : public PortableServer::AdapterActivator,
40 public CORBA::LocalObject
42 public:
43 ImR_Adapter();
45 /// Called when a POA needs to be created.
46 virtual CORBA::Boolean unknown_adapter (
47 PortableServer::POA_ptr parent,
48 const char *name);
50 void init(TAO_ServantBase * servant);
51 private:
52 /// the default servant used.
53 TAO_ServantBase *default_servant_;
56 #endif /* IMR_ADAPTER_ACTIVATOR_H */