summaryrefslogtreecommitdiff
path: root/TAO/CIAO/DAnCE/RepositoryManager/Update_Plan.h
blob: 3a67955bd2f64cef582fc880c11ee1691166f657 (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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
/*=======================================================================
 *
 * @file Update_Plan.h
 *
 * $Id$
 *
 * @brief This file contains declarations for helper functions
 * used in updating the deployment plan data structure from
 * PackageConfiguration data structure.
 *
 * @author Jaiganesh Balasubramanian <jai@dre.vanderbilt.edu>
 *
 *======================================================================*/

#ifndef CIAO_REPOSITORY_MANAGER_UPDATE_PLAN_H
#define CIAO_REPOSITORY_MANAGER_UPDATE_PLAN_H
#include /**/ "ace/pre.h"

#include "ace/Hash_Map_Manager.h"

#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */


namespace Deployment
{
  struct SubcomponentInstantiationDescription;
  struct DeploymentPlan;
  struct ComponentAssemblyDescription;
  struct SubcomponentInstantiationDescription;
  struct AssemblyConnectionDescription;
}

namespace CIAO
{
  class Null_Dom_Document { };
  // exception thrown when we have a null dom document.

  typedef ACE_Hash_Map_Manager<ACE_TString, int, ACE_Null_Mutex> REF_MAP;
  typedef ACE_Hash_Map_Manager<int, int, ACE_Null_Mutex> ART_REF_MAP;

  void
  traverse_assembly_instance (Deployment::
                              SubcomponentInstantiationDescription &instance,
                              Deployment::DeploymentPlan &plan,
                              int l,
                              REF_MAP &ref_map,
                              REF_MAP &primary_ref_map);

  void traverse_assembly (Deployment::ComponentAssemblyDescription &assembly,
                          Deployment::DeploymentPlan &plan,
                          REF_MAP &ref_map, REF_MAP &primary_ref_map);

  void traverse_interface (Deployment::SubcomponentInstantiationDescription
                           &instance,
                           Deployment::PlanSubcomponentPortEndpoint
                           &pspe);

  void traverse_assembly_connection (Deployment::ComponentAssemblyDescription
                                     &assembly,
                                     Deployment::AssemblyConnectionDescription
                                     &assembly_connection,
                                     Deployment::DeploymentPlan &plan);

  void traverse_package (Deployment::PackageConfiguration* &pc,
                         Deployment::DeploymentPlan &plan,
                         REF_MAP &ref_map, REF_MAP &primary_ref_map);

  void update_artifacts (Deployment::MonolithicImplementationDescription &mid,
                         Deployment::DeploymentPlan &plan,
                         Deployment::InstanceDeploymentDescription &instance,
                         REF_MAP &ref_map, REF_MAP &primary_ref_map,
                         ART_REF_MAP &art_ref_map,
                         Deployment::MonolithicDeploymentDescription &mdd);

  void update_artifact_location (Deployment::ImplementationArtifactDescription
                                 &pack_iad,
                                 Deployment::ArtifactDeploymentDescription
                                 &plan_artifact);

  void update_artifact_property (Deployment::ImplementationArtifactDescription
                                 &pack_iad,
                                 Deployment::ArtifactDeploymentDescription
                                 &plan_artifact);

  void update_impl_art_ref (Deployment::MonolithicDeploymentDescription
                            &mid, int art_len);

  void update_impl_config_property (Deployment::
                                    PackagedComponentImplementation &impl,
                                    Deployment::
                                    MonolithicDeploymentDescription &mid,
                                    Deployment::
                                    InstanceDeploymentDescription
                                    &instance);

  void update_common_artifact_and_art_ref (Deployment::
                                           ImplementationArtifactDescription &pack_iad,
                                           REF_MAP &primary_ref_map,
                                           REF_MAP &ref_map,
                                           ART_REF_MAP &art_ref_map,
                                           Deployment::MonolithicDeploymentDescription
                                           &mid,
                                           Deployment::DeploymentPlan &plan,
                                           Deployment::
                                           InstanceDeploymentDescription
                                           &instance);
}

#include /**/ "ace/post.h"
#endif /* CIAO_REPOSITORY_MANAGER_UPDATE_PLAN_H*/