00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014 #ifndef TAO_PG_OBJECT_GROUP_MANIPULATOR_H
00015 #define TAO_PG_OBJECT_GROUP_MANIPULATOR_H
00016
00017 #include "ace/pre.h"
00018
00019 #include "orbsvcs/PortableGroup/portablegroup_export.h"
00020
00021 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00022 #pragma once
00023 #endif
00024
00025 #include "orbsvcs/PortableGroupS.h"
00026
00027 #include "tao/IORManipulation/IORManip_Loader.h"
00028
00029 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00030
00031 namespace TAO
00032 {
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042 class TAO_PortableGroup_Export PG_Object_Group_Manipulator
00043 {
00044 public:
00045
00046
00047 PG_Object_Group_Manipulator ();
00048
00049
00050 ~PG_Object_Group_Manipulator ();
00051
00052
00053
00054
00055 void init (CORBA::ORB_ptr orb,
00056 PortableServer::POA_ptr poa);
00057
00058
00059
00060
00061 PortableGroup::ObjectGroup_ptr create_object_group (
00062 const char * type_id,
00063 const char * domain_id,
00064 PortableGroup::ObjectGroupId & group_id);
00065
00066 PortableGroup::ObjectGroup_ptr remove_profiles (
00067 PortableGroup::ObjectGroup_ptr group,
00068 PortableGroup::ObjectGroup_ptr profile) const;
00069
00070 PortableGroup::ObjectGroup_ptr merge_iors (
00071 TAO_IOP::TAO_IOR_Manipulation::IORList & iors) const;
00072
00073 int set_primary (
00074 TAO_IOP::TAO_IOR_Property * prop,
00075 PortableGroup::ObjectGroup_ptr reference,
00076 CORBA::Object_ptr new_primary) const;
00077
00078 void dump_membership (const char * label,
00079 PortableGroup::ObjectGroup_ptr member) const;
00080
00081 private:
00082
00083
00084
00085
00086 void allocate_ogid (PortableGroup::ObjectGroupId & ogid);
00087
00088
00089
00090
00091 PortableServer::ObjectId *
00092 convert_ogid_to_oid (PortableGroup::ObjectGroupId ogid) const;
00093
00094 private:
00095
00096
00097 CORBA::ORB_var orb_;
00098
00099
00100 PortableServer::POA_var poa_;
00101
00102
00103 TAO_IOP::TAO_IOR_Manipulation_var iorm_;
00104
00105
00106 TAO_SYNCH_MUTEX lock_ogid_;
00107
00108
00109 PortableGroup::ObjectGroupId next_ogid_;
00110
00111 };
00112 }
00113
00114 TAO_END_VERSIONED_NAMESPACE_DECL
00115
00116 #include "ace/post.h"
00117
00118 #endif