diff options
author | Johnny Willemsen <jwillemsen@remedy.nl> | 2004-08-18 12:28:22 +0000 |
---|---|---|
committer | Johnny Willemsen <jwillemsen@remedy.nl> | 2004-08-18 12:28:22 +0000 |
commit | 6674520fcef99f221dd336e60805455c4b2c745f (patch) | |
tree | 8df4cd08d9ca6675f846fbc5a1329da2aac5ef13 | |
parent | 8dac372c202b4872378a2e3f3c66c571c46a93fc (diff) | |
download | ATCD-6674520fcef99f221dd336e60805455c4b2c745f.tar.gz |
ChangeLogTag: Wed Aug 18 12:26:12 UTC 2004 Johnny Willemsen <jwillemsen@remedy.nl>
-rw-r--r-- | TAO/tao/ObjRefTemplate/ObjectReferenceTemplate_i.h | 2 | ||||
-rw-r--r-- | TAO/tao/PortableServer/IORInfo.cpp | 4 | ||||
-rw-r--r-- | TAO/tao/PortableServer/ORTRework.txt | 28 | ||||
-rwxr-xr-x | TAO/tao/PortableServer/ObjectReferenceTemplate_Adapter.h | 10 | ||||
-rw-r--r-- | TAO/tao/PortableServer/ObjectReferenceTemplate_Adapter_Factory.h | 8 | ||||
-rw-r--r-- | TAO/tao/PortableServer/POA.cpp | 32 |
6 files changed, 49 insertions, 35 deletions
diff --git a/TAO/tao/ObjRefTemplate/ObjectReferenceTemplate_i.h b/TAO/tao/ObjRefTemplate/ObjectReferenceTemplate_i.h index 91c0f3d8864..adb849a60b9 100644 --- a/TAO/tao/ObjRefTemplate/ObjectReferenceTemplate_i.h +++ b/TAO/tao/ObjRefTemplate/ObjectReferenceTemplate_i.h @@ -46,7 +46,6 @@ class TAO_ORT_Export TAO_ObjectReferenceTemplate public virtual CORBA::DefaultValueRefCountBase { public: - /// Constructor TAO_ObjectReferenceTemplate (const char *server_id, const char *orb_id, @@ -107,7 +106,6 @@ protected: ~TAO_ObjectReferenceTemplate (void); private: - const char *server_id_; const char *orb_id_; PortableInterceptor::AdapterName_var adapter_name_; diff --git a/TAO/tao/PortableServer/IORInfo.cpp b/TAO/tao/PortableServer/IORInfo.cpp index 4047aa792ce..005b850cbdd 100644 --- a/TAO/tao/PortableServer/IORInfo.cpp +++ b/TAO/tao/PortableServer/IORInfo.cpp @@ -147,8 +147,6 @@ TAO_IORInfo::adapter_template (ACE_ENV_SINGLE_ARG_DECL) 0); } - //CORBA::add_ref (adapter_template); - return adapter_template; } @@ -174,8 +172,6 @@ TAO_IORInfo::current_factory (ACE_ENV_SINGLE_ARG_DECL) 0); } - //CORBA::add_ref (adapter_factory); - return adapter_factory; } diff --git a/TAO/tao/PortableServer/ORTRework.txt b/TAO/tao/PortableServer/ORTRework.txt index 3d838aa0297..7ab71066bfa 100644 --- a/TAO/tao/PortableServer/ORTRework.txt +++ b/TAO/tao/PortableServer/ORTRework.txt @@ -1,3 +1,31 @@ +Wed Aug 18 12:28:12 UTC 2004 Johnny Willemsen <jwillemsen@remedy.nl> + + * tao/IORInterceptor/IORInterceptor.pidl: + * tao/IORInterceptor/IORInterceptorC.{h,cpp,i,inl}: + Regenerated these files, no need to apply patches anymore, and use + .inl file instead of .i files. + + * tao/PortableServer/ObjectReferenceTemplate_Adapter.h: + Added typedef for a list of ORT Adapter pointers + + * tao/IORInterceptor/IORInterceptor_List.{h,cpp}: + Removed typedef of array of ObjectReferenceTemplate*, include the + ORT Adapter header file instead + + * tao/PorableServer.mpc: + * tao/ObjRefTemplate.mpc: + PortableServer library is not dependent on objreftemplate anymore + but objreftemplate is dependent on portableserver + + * tao/ObjRefTemplate/ObjectReferneceTemplate_Adapter_Impl.{h,cpp,i}: + * tao/ObjRefTemplate/ObjectReferenceTemplate_i.{h,cpp,i}: + Split the adapter implementation and the ort_factory and + ort_template. The adapter creates a TAO_ObjectReferenceTemplate + which is a ort_template, which then also a ort_factory. The + ort_factory can be replaced using IORInfo, for the identity methods + the ort_template is used, until the ort_factory is changed from + outside the ort_template is used, after that the new set one. + Tue Aug 17 14:30:12 UTC 2004 Johnny Willemsen <jwillemsen@remedy.nl> Checkin of rework until now, not happy with the interfaces yet, now diff --git a/TAO/tao/PortableServer/ObjectReferenceTemplate_Adapter.h b/TAO/tao/PortableServer/ObjectReferenceTemplate_Adapter.h index 0724dfcd88d..f388ed026e0 100755 --- a/TAO/tao/PortableServer/ObjectReferenceTemplate_Adapter.h +++ b/TAO/tao/PortableServer/ObjectReferenceTemplate_Adapter.h @@ -58,12 +58,12 @@ public: virtual int activate (const char *server_id, const char *orb_id, PortableInterceptor::AdapterName *, - TAO_POA *poa) = 0; + TAO_POA *poa + ACE_ENV_ARG_DECL_WITH_DEFAULTS) = 0; - virtual int activate (PortableInterceptor::ObjectReferenceFactory *current_factory, - TAO_POA *poa) = 0; - - virtual int destroy (void) = 0; + /// Set a different ort_factory to be used. + virtual int set_obj_ref_factory (PortableInterceptor::ObjectReferenceFactory *current_factory + ACE_ENV_ARG_DECL_WITH_DEFAULTS) = 0; /// Set the underlying POA pointer. /** diff --git a/TAO/tao/PortableServer/ObjectReferenceTemplate_Adapter_Factory.h b/TAO/tao/PortableServer/ObjectReferenceTemplate_Adapter_Factory.h index 17048f4c9ba..69c61062cc9 100644 --- a/TAO/tao/PortableServer/ObjectReferenceTemplate_Adapter_Factory.h +++ b/TAO/tao/PortableServer/ObjectReferenceTemplate_Adapter_Factory.h @@ -44,8 +44,12 @@ public: virtual ~TAO_ObjectReferenceTemplate_Adapter_Factory (void); virtual TAO_ObjectReferenceTemplate_Adapter * create ( - ACE_ENV_SINGLE_ARG_DECL - ) + ACE_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((CORBA::SystemException)) = 0; + + virtual void destroy ( + TAO_ObjectReferenceTemplate_Adapter * adapter + ACE_ENV_ARG_DECL) ACE_THROW_SPEC ((CORBA::SystemException)) = 0; }; diff --git a/TAO/tao/PortableServer/POA.cpp b/TAO/tao/PortableServer/POA.cpp index 8fac6414dc6..4c9f7b936e6 100644 --- a/TAO/tao/PortableServer/POA.cpp +++ b/TAO/tao/PortableServer/POA.cpp @@ -174,26 +174,11 @@ TAO_POA::set_obj_ref_factory ( PortableInterceptor::ObjectReferenceFactory *current_factory ACE_ENV_ARG_DECL) { - if (ort_adapter_ != 0) - { - ort_adapter_->destroy(); - ort_adapter_ = 0; - } - - TAO_ObjectReferenceTemplate_Adapter_Factory * ort_ap_factory = - this->object_reference_template_adapter_factory(); - - if (ort_ap_factory) + if (this->object_reference_template_adapter ()) { - this->ort_adapter_ = - ort_ap_factory->create (ACE_ENV_SINGLE_ARG_PARAMETER); - ACE_TRY_CHECK; - - if (ort_adapter_) - { - ort_adapter_->activate (current_factory, - this); - } + // Activate a different factory + this->ort_adapter_->set_obj_ref_factory (current_factory + ACE_ENV_ARG_PARAMETER); } } @@ -432,10 +417,13 @@ TAO_POA::complete_destruction_i (ACE_ENV_SINGLE_ARG_DECL) } - if (ort_adapter_ != 0) + if (this->ort_adapter_ != 0) { - ort_adapter_->destroy (); - ort_adapter_ = 0; + TAO_ObjectReferenceTemplate_Adapter_Factory *ort_factory = + this->object_reference_template_adapter_factory (); + + ort_factory->destroy (this->ort_adapter_); + this->ort_adapter_ = 0; } CORBA::release (this); |