blob: 8ce81ca1db6715fb88749c7cd9324fecaea1559e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
|
// -*- C++ -*-
//=============================================================================
/**
* @file ServerActivator_Impl.h
*
* $Id$
*
* @Brief Implementation of Deployment::ServerActivator
*
* @author Erwin Gottlieb <eg@prismtech.com>
*/
//=============================================================================
#ifndef SERVERACTIVATOR_IMPL_H_
#define SERVERACTIVATOR_IMPL_H_
#include "ace/Map_Manager.h"
#include "tao/ORB.h"
#include "orbsvcs/orbsvcs/CosNamingC.h"
#include "Cdmw/CDMW_IDLS.h"
#include "ComponentServer/ComponentServerS.h"
#include "NodeApplication_Export.h"
namespace DAnCE
{
class NodeApplication_Export ServerActivator_Impl : public virtual POA_Components::Deployment::ServerActivator
{
public:
ServerActivator_Impl (CORBA::ORB_ptr orb,
PortableServer::POA_ptr poa_,
Components::Deployment::ComponentInstallation_ptr compInst);
virtual ~ServerActivator_Impl();
//
// IDL:omg.org/Components/Deployment/ServerActivator/create_component_server:1.0
//
/**
* Creates a ComponentServer object on the host on which the
* ServerActivator is located.
*
* @param config ConfigValues for creation of ComponentServer.
* For CDMW CCM, this sequence should contain a
* PROCESS_DESTINATION ConfigValue which specify the
* destination of an already started ComponentServer process.
*
* @throws CreateFailure
* INVALID_PROCESS_DESTINATION: raised if the destination
* specified in PROCESS_DESTINATION ConfigValue is not valid.<br>
* COMPONENT_SERVER_NOT_CREATED: raised if the ComponentServer could
* not be contacted (it should be started by PlatformManagement before
* the call to ServerActivator).<br>
* COMPONENT_SERVER_ALREADY_CREATED: raised if this method has already
* been called with the same PROCESS_DESTINATION ConfigValue.
* @throws InvalidConfiguration
* raised if the config parameter doesn't contain a single
* PROCESS_DESTINATION ConfigValue.
*/
virtual ::Components::Deployment::ComponentServer_ptr create_component_server (
const ::Components::ConfigValues & config
);
//
// IDL:omg.org/Components/Deployment/ServerActivator/remove_component_server:1.0
//
virtual void remove_component_server (
::Components::Deployment::ComponentServer_ptr server
);
//
// IDL:omg.org/Components/Deployment/ServerActivator/get_component_servers:1.0
//
virtual ::Components::Deployment::ComponentServers * get_component_servers (
);
private:
typedef ACE_Map_Manager<ACE_CString, ::Components::Deployment::ComponentServer_var, ACE_Null_Mutex > TCompServers;
TCompServers servers_;
CORBA::ORB_var orb_;
PortableServer::POA_var poa_;
CosNaming::NamingContext_var naming_;
Components::Deployment::ComponentInstallation_var compInst_;
private:
void initializeComponentServer (::Components::Deployment::ComponentServer_ptr server);
};
};
#endif /*SERVERACTIVATOR_IMPL_H_*/
|