diff options
author | irfan <irfan@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1998-06-20 09:44:59 +0000 |
---|---|---|
committer | irfan <irfan@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1998-06-20 09:44:59 +0000 |
commit | 6ba91c472d2009d7b52fa429349c245f69970e16 (patch) | |
tree | 5d61877e7f71e7cef04ef15db9bc760f42febe4c | |
parent | 43d4789c2435e8ddcb68a39e1dc68d6052a4b9f4 (diff) | |
download | ATCD-6ba91c472d2009d7b52fa429349c245f69970e16.tar.gz |
*** empty log message ***
-rw-r--r-- | TAO/ChangeLog-98c | 48 | ||||
-rw-r--r-- | TAO/tao/IIOP_Object.cpp | 2 | ||||
-rw-r--r-- | TAO/tao/IIOP_Object.h | 5 | ||||
-rw-r--r-- | TAO/tao/ORB.cpp | 4 | ||||
-rw-r--r-- | TAO/tao/ORB_Core.cpp | 12 | ||||
-rw-r--r-- | TAO/tao/POA.IDL | 26 | ||||
-rw-r--r-- | TAO/tao/POA.cpp | 196 | ||||
-rw-r--r-- | TAO/tao/POA.h | 124 | ||||
-rw-r--r-- | TAO/tao/POA.i | 82 | ||||
-rw-r--r-- | TAO/tao/POAC.cpp | 307 | ||||
-rw-r--r-- | TAO/tao/POAC.h | 361 | ||||
-rw-r--r-- | TAO/tao/POAC.i | 661 | ||||
-rw-r--r-- | TAO/tao/POAS.cpp | 2372 | ||||
-rw-r--r-- | TAO/tao/POAS.h | 877 | ||||
-rw-r--r-- | TAO/tao/POAS.i | 28 | ||||
-rw-r--r-- | TAO/tao/Principal.i | 2 | ||||
-rw-r--r-- | TAO/tao/Sequence.h | 8 | ||||
-rw-r--r-- | TAO/tests/POA/NewPOA/NewPOA.cpp | 8 | ||||
-rw-r--r-- | TAO/tests/POA/locking/Makefile | 229 | ||||
-rw-r--r-- | TAO/tests/POA/locking/locking.cpp | 158 | ||||
-rw-r--r-- | TAO/tests/POA/locking/locking.dsp | 91 | ||||
-rw-r--r-- | TAO/tests/POA/locking/locking.dsw | 29 |
22 files changed, 3408 insertions, 2222 deletions
diff --git a/TAO/ChangeLog-98c b/TAO/ChangeLog-98c index 31f89ecd8d3..714da1c4dab 100644 --- a/TAO/ChangeLog-98c +++ b/TAO/ChangeLog-98c @@ -1,3 +1,51 @@ +Sat Jun 20 03:31:28 1998 Irfan Pyarali <irfan@cs.wustl.edu> + + * tao/POA: + + - Added TAO_POA_locking as a new policy to the POA. This policy + is used to control the kind of lock created for POA state + synchronization. Previously, the user could only specific the + synchronization choice at an application level in the svc.conf + file. This approach did not allow a scheme where some POAs + had thread safe synchronization, while others had no + (null) synchronization. + + The new policy has three options: + + - USE_DEFAULT_LOCK: This option is the default value for this + policy. This option indicates that the application level + choice for POA synchronization specified in the svc.conf + file be used. Currently, this defaults to thread safe + synchronization. + + This option allows the programmer to make application level + decisions about the synchronization in the POA. Hence, + unless specified otherwise in create_POA, all POAs in the + application will have thread safe synchronization or null + (no) synchronization depending on the chioce made in + svc.conf. + + - USE_NULL_LOCK: Use null (no) synchronization to protect the + state of this POA. + + - USE_THREAD_LOCK: Use thread synchronization to protect the + state of this POA. + + - Changed POAC.{h,i,cpp}, POAS.{h,i,cpp} and POA{h,i,cpp} to + support this new policy. + + - Removed Strategy_POA and Strategy_POA_Manager. Both were + rather unnecessary in view of the above changes. + + * tests/POA/locking/locking.cpp: New test for showing off new POA + locking policy. + + * tao/Sequence.h (Octet>): Removed extra operator<< and operator>> + declarations, and changed the implementation to use non-private + members. + + * tao/Principal.i: Added new file (empty). + Sat Jun 20 01:39:35 1998 Nanbor Wang <nanbor@cs.wustl.edu> * tao/TAO4.{mdp,mak}: Defined TAO_BUILD_DLL, undefined diff --git a/TAO/tao/IIOP_Object.cpp b/TAO/tao/IIOP_Object.cpp index bde18872652..c509e9503c4 100644 --- a/TAO/tao/IIOP_Object.cpp +++ b/TAO/tao/IIOP_Object.cpp @@ -365,8 +365,6 @@ IIOP_Object::key (CORBA::Environment &) return new TAO_ObjectKey (this->profile.object_key); } -// It will usually be used by the _bind call. -// // Note that if the repository ID (typeID) is NULL, it will make // narrowing rather expensive, though it does ensure that type-safe // narrowing code gets thoroughly exercised/debugged! Without a diff --git a/TAO/tao/IIOP_Object.h b/TAO/tao/IIOP_Object.h index 253ce73c7af..55de46c6d0f 100644 --- a/TAO/tao/IIOP_Object.h +++ b/TAO/tao/IIOP_Object.h @@ -65,7 +65,7 @@ public: Profile (const char *host, const CORBA::UShort port, const char *object_key); - // Called by client <_bind>. + // Called by client Profile (const char *host, const CORBA::UShort port, @@ -190,8 +190,7 @@ public: const CORBA::UShort p, const char *objkey, char *repository_id = 0); - // This constructor will usually be used by a <_bind> call on the - // client side. + // This constructor will usually be used by the client side. IIOP_Object (char *repository_id, const ACE_INET_Addr &addr, diff --git a/TAO/tao/ORB.cpp b/TAO/tao/ORB.cpp index a3b529ef6cb..5adbe12762b 100644 --- a/TAO/tao/ORB.cpp +++ b/TAO/tao/ORB.cpp @@ -778,10 +778,10 @@ operator<<(TAO_OutputCDR& cdr, const TAO_opaque& x) #if !defined (TAO_NO_COPY_OCTET_SEQUENCES) cdr.write_octet_array (x.get_buffer (), length); #else - if (x.mb_ == 0) + if (x.mb () == 0) cdr.write_octet_array (x.get_buffer (), length); else - cdr.write_octet_array_mb (x.mb_); + cdr.write_octet_array_mb (x.mb ()); #endif /* TAO_NO_COPY_OCTET_SEQUENCES */ return cdr; } diff --git a/TAO/tao/ORB_Core.cpp b/TAO/tao/ORB_Core.cpp index f957e5d0cda..42dad0f76ba 100644 --- a/TAO/tao/ORB_Core.cpp +++ b/TAO/tao/ORB_Core.cpp @@ -882,16 +882,16 @@ TAO_ORB_Core::create_and_set_root_poa (void) // Need to do double-checked locking here to cover the case of // multiple threads using a global resource policy. - TAO_POA_Manager *manager = new TAO_Strategy_POA_Manager; + TAO_POA_Manager *manager = new TAO_POA_Manager; TAO_POA_Policies root_poa_policies; root_poa_policies.implicit_activation (PortableServer::IMPLICIT_ACTIVATION); // Construct a new POA - poa = new TAO_Strategy_POA ("", - *manager, - root_poa_policies, - 0, - env); + poa = new TAO_POA ("", + *manager, + root_poa_policies, + 0, + env); if (env.exception () != 0) return; diff --git a/TAO/tao/POA.IDL b/TAO/tao/POA.IDL index e127b83eb02..75a79d38a16 100644 --- a/TAO/tao/POA.IDL +++ b/TAO/tao/POA.IDL @@ -126,6 +126,22 @@ module PortableServer // ************************************************** // + // TAO spcific POA locking policy (non-standard) + // + // ************************************************** + + enum TAO_POA_LockingPolicyValue { + USE_DEFAULT_LOCK, + USE_NULL_LOCK, + USE_THREAD_LOCK + }; + interface TAO_POA_LockingPolicy : CORBA::Policy + { + readonly attribute TAO_POA_LockingPolicyValue value; + }; + + // ************************************************** + // // POAManager interface // // ************************************************** @@ -262,6 +278,16 @@ module PortableServer create_request_processing_policy (in RequestProcessingPolicyValue value); + // ************************************************** + // + // TAO spcific POA locking policy (non-standard) + // + // ************************************************** + + TAO_POA_LockingPolicy + create_TAO_POA_locking_policy + (in TAO_POA_LockingPolicyValue value); + //-------------------------------------------------- // // POA attributes diff --git a/TAO/tao/POA.cpp b/TAO/tao/POA.cpp index d401cf9f89f..47808985f31 100644 --- a/TAO/tao/POA.cpp +++ b/TAO/tao/POA.cpp @@ -564,6 +564,82 @@ TAO_Request_Processing_Policy::_default_POA (CORBA::Environment &env) return PortableServer::POA::_duplicate (this->poa_.in ()); } +// ************************************************** +// +// TAO spcific POA locking policy (non-standard) +// +// ************************************************** + +TAO_POA_Locking_Policy::TAO_POA_Locking_Policy (PortableServer::TAO_POA_LockingPolicyValue value, + PortableServer::POA_ptr poa) + : value_ (value), + poa_ (PortableServer::POA::_duplicate (poa)) +{ +} + +TAO_POA_Locking_Policy::TAO_POA_Locking_Policy (const TAO_POA_Locking_Policy &rhs) + : value_ (rhs.value_), + poa_ (PortableServer::POA::_duplicate (rhs.poa_.in ())) +{ +} + +PortableServer::TAO_POA_LockingPolicyValue +TAO_POA_Locking_Policy::value (CORBA::Environment &env) +{ + ACE_UNUSED_ARG (env); + return this->value_; +} + +CORBA::Policy_ptr +TAO_POA_Locking_Policy::copy (CORBA::Environment &env) +{ + auto_ptr<TAO_POA_Locking_Policy> new_policy (new TAO_POA_Locking_Policy (*this)); + + CORBA::Policy_var result = new_policy->_this (env); + if (env.exception () != 0) + return CORBA::Policy::_nil (); + else + { + // Make sure that the auto_ptr does not delete the + // implementation object + new_policy.release (); + return result._retn (); + } +} + +void +TAO_POA_Locking_Policy::destroy (CORBA::Environment &env) +{ + // Remove self from POA + // + // Note that there is no real error checking here as we can't do + // much about errors here anyway + // + PortableServer::POA_var poa = this->_default_POA (env); + if (env.exception () == 0) + { + PortableServer::ObjectId_var id = poa->servant_to_id (this, env); + if (env.exception () == 0) + poa->deactivate_object (id.in (), env); + } + + // Commit suicide: must have been dynamically allocated + delete this; +} + +CORBA::PolicyType +TAO_POA_Locking_Policy::policy_type (CORBA::Environment &env) +{ + ACE_UNUSED_ARG (env); + return 0; +} + +PortableServer::POA_ptr +TAO_POA_Locking_Policy::_default_POA (CORBA::Environment &env) +{ + return PortableServer::POA::_duplicate (this->poa_.in ()); +} + TAO_POA_Policies::TAO_POA_Policies (void) : thread_ (PortableServer::ORB_CTRL_MODEL), lifespan_ (PortableServer::TRANSIENT), @@ -571,7 +647,8 @@ TAO_POA_Policies::TAO_POA_Policies (void) id_assignment_ (PortableServer::SYSTEM_ID), implicit_activation_ (PortableServer::NO_IMPLICIT_ACTIVATION), servant_retention_ (PortableServer::RETAIN), - request_processing_ (PortableServer::USE_ACTIVE_OBJECT_MAP_ONLY) + request_processing_ (PortableServer::USE_ACTIVE_OBJECT_MAP_ONLY), + TAO_POA_locking_ (PortableServer::USE_DEFAULT_LOCK) { } @@ -711,6 +788,18 @@ TAO_POA_Policies::parse_policy (const CORBA::Policy_ptr policy, env.clear (); } + PortableServer::TAO_POA_LockingPolicy_var TAO_POA_locking + = PortableServer::TAO_POA_LockingPolicy::_narrow (policy, env); + if (!CORBA::is_nil (TAO_POA_locking.in ())) + { + this->TAO_POA_locking_ = TAO_POA_locking->value (env); + return; + } + else + { + env.clear (); + } + CORBA::Exception *exception = new PortableServer::POA::InvalidPolicy; env.exception (exception); return; @@ -732,11 +821,15 @@ TAO_POA::TAO_POA (const TAO_POA::String &adapter_name, servant_locator_ (), default_servant_ (0), children_ (), - lock_ (), + lock_ (0), closing_down_ (0), counter_ (0), creation_time_ (ACE_OS::gettimeofday ()) { + // Create a lock for ourselves + this->create_internal_lock (); + + // Set the complete name of this POA this->set_complete_name (); // Register self with manager @@ -760,22 +853,42 @@ TAO_POA::TAO_POA (const TAO_POA::String &adapter_name, servant_locator_ (), default_servant_ (0), children_ (), - lock_ (), + lock_ (0), closing_down_ (0), counter_ (0), creation_time_ (ACE_OS::gettimeofday ()) { + // Create a lock for ourselves + this->create_internal_lock (); + + // Set the complete name of this POA this->set_complete_name (); // Register self with manager this->poa_manager_.register_poa (this, env); } +void +TAO_POA::create_internal_lock (void) +{ + if (this->policies ().TAO_POA_locking () == PortableServer::USE_DEFAULT_LOCK) + this->lock_ = TAO_ORB_Core_instance ()->server_factory ()->create_poa_lock (); + else if (this->policies ().TAO_POA_locking () == PortableServer::USE_NULL_LOCK) + ACE_NEW (this->lock_, + ACE_Lock_Adapter<ACE_Null_Mutex>); + else if (this->policies ().TAO_POA_locking () == PortableServer::USE_THREAD_LOCK) + ACE_NEW (this->lock_, + ACE_Lock_Adapter<ACE_Recursive_Thread_Mutex>); +} + TAO_POA::~TAO_POA (void) { if (this->delete_active_object_map_) delete active_object_map_; + // Delete the dynamically allocated lock + delete this->lock_; + // Remove POA from the POAManager // // Note: Errors are ignored here since there is nothing we can do @@ -1860,7 +1973,7 @@ TAO_POA::locate_servant (const TAO_ObjectKey &key, switch (result) { case TAO_POA::FOUND: - // Optimistic attitude + // Optimistic attitude case TAO_POA::DEFAULT_SERVANT: case TAO_POA::SERVANT_MANAGER: return 0; @@ -2751,6 +2864,34 @@ TAO_POA::create_request_processing_policy (PortableServer::RequestProcessingPoli } } +// ************************************************** +// +// TAO spcific POA locking policy (non-standard) +// +// ************************************************** + +PortableServer::TAO_POA_LockingPolicy_ptr +TAO_POA::create_TAO_POA_locking_policy (PortableServer::TAO_POA_LockingPolicyValue value, + CORBA::Environment &env) +{ + PortableServer::POA_var self = this->_this (env); + // Check for exceptions + if (env.exception () != 0) + return PortableServer::TAO_POA_LockingPolicy::_nil (); + + auto_ptr<TAO_POA_Locking_Policy> new_policy (new TAO_POA_Locking_Policy (value, self.in ())); + PortableServer::TAO_POA_LockingPolicy_var result = new_policy->_this (env); + if (env.exception () != 0) + return PortableServer::TAO_POA_LockingPolicy::_nil (); + else + { + // Make sure that the auto_ptr does not delete the + // implementation + new_policy.release (); + return result._retn (); + } +} + void TAO_POA::encode_sequence_to_string (CORBA::String &str, const TAO_Unbounded_Sequence<CORBA::Octet> &seq) @@ -2832,38 +2973,6 @@ TAO_POA::decode_string_to_sequence (TAO_Unbounded_Sequence<CORBA::Octet> &seq, seq.length (i); } -TAO_Strategy_POA::TAO_Strategy_POA (const TAO_POA::String &adapter_name, - TAO_POA_Manager &poa_manager, - const TAO_POA_Policies &policies, - TAO_POA *parent, - CORBA::Environment &env) - : TAO_POA (adapter_name, - poa_manager, - policies, - parent, - env), - lock_ (0) -{ - this->lock_ = TAO_ORB_Core_instance ()->server_factory ()->create_poa_lock (); -} - -TAO_Strategy_POA::TAO_Strategy_POA (const TAO_POA::String &adapter_name, - TAO_POA_Manager &poa_manager, - const TAO_POA_Policies &policies, - TAO_POA *parent, - TAO_Object_Table &active_object_map, - CORBA::Environment &env) - : TAO_POA (adapter_name, - poa_manager, - policies, - parent, - active_object_map, - env), - lock_ (0) -{ - this->lock_ = TAO_ORB_Core_instance ()->server_factory ()->create_poa_lock (); -} - CORBA::Boolean TAO_Adapter_Activator::unknown_adapter (PortableServer::POA_ptr parent, const char *name, @@ -2909,13 +3018,15 @@ TAO_Adapter_Activator::unknown_adapter (PortableServer::POA_ptr parent, TAO_POA_Manager::TAO_POA_Manager (void) : state_ (HOLDING), closing_down_ (0), - lock_ (), + lock_ (0), poa_collection_ () { + this->lock_ = TAO_ORB_Core_instance ()->server_factory ()->create_poa_mgr_lock (); } TAO_POA_Manager::~TAO_POA_Manager (void) { + delete this->lock_; } void @@ -3141,13 +3252,6 @@ TAO_POA_Manager::register_poa_i (TAO_POA *poa, } } -TAO_Strategy_POA_Manager::TAO_Strategy_POA_Manager (void) - : TAO_POA_Manager (), - lock_ (0) -{ - this->lock_ = TAO_ORB_Core_instance ()->server_factory ()->create_poa_mgr_lock (); -} - TAO_POA_Current::TAO_POA_Current (void) : poa_impl_ (0), object_id_ (0), @@ -3211,6 +3315,7 @@ template class ACE_Auto_Basic_Ptr<TAO_Lifespan_Policy>; template class ACE_Auto_Basic_Ptr<TAO_Object_Table_Iterator_Impl>; template class ACE_Auto_Basic_Ptr<TAO_POA>; template class ACE_Auto_Basic_Ptr<TAO_Request_Processing_Policy>; +template class ACE_Auto_Basic_Ptr<TAO_POA_Locking_Policy>; template class ACE_Auto_Basic_Ptr<TAO_Servant_Retention_Policy>; template class ACE_Auto_Basic_Ptr<TAO_Thread_Policy>; template class ACE_Lock_Adapter<ACE_Null_Mutex>; @@ -3235,6 +3340,7 @@ template class auto_ptr<TAO_Lifespan_Policy>; template class auto_ptr<TAO_Object_Table_Iterator_Impl>; template class auto_ptr<TAO_POA>; template class auto_ptr<TAO_Request_Processing_Policy>; +template class auto_ptr<TAO_POA_Locking_Policy>; template class auto_ptr<TAO_Servant_Retention_Policy>; template class auto_ptr<TAO_Thread_Policy>; template class ACE_Map_Entry<ACE_CString, TAO_POA *>; @@ -3248,6 +3354,7 @@ template class ACE_Node<TAO_POA *>; #pragma instantiate ACE_Auto_Basic_Ptr<TAO_Object_Table_Iterator_Impl> #pragma instantiate ACE_Auto_Basic_Ptr<TAO_POA> #pragma instantiate ACE_Auto_Basic_Ptr<TAO_Request_Processing_Policy> +#pragma instantiate ACE_Auto_Basic_Ptr<TAO_POA_Locking_Policy> #pragma instantiate ACE_Auto_Basic_Ptr<TAO_Servant_Retention_Policy> #pragma instantiate ACE_Auto_Basic_Ptr<TAO_Thread_Policy> #pragma instantiate ACE_Lock_Adapter<ACE_Null_Mutex> @@ -3272,6 +3379,7 @@ template class ACE_Node<TAO_POA *>; #pragma instantiate auto_ptr<TAO_Object_Table_Iterator_Impl> #pragma instantiate auto_ptr<TAO_POA> #pragma instantiate auto_ptr<TAO_Request_Processing_Policy> +#pragma instantiate auto_ptr<TAO_POA_Locking_Policy> #pragma instantiate auto_ptr<TAO_Servant_Retention_Policy> #pragma instantiate auto_ptr<TAO_Thread_Policy> #pragma instantiate ACE_Map_Entry<ACE_CString, TAO_POA *> diff --git a/TAO/tao/POA.h b/TAO/tao/POA.h index 87807ac217c..991daaaf9da 100644 --- a/TAO/tao/POA.h +++ b/TAO/tao/POA.h @@ -218,6 +218,36 @@ protected: PortableServer::POA_var poa_; }; +// ************************************************** +// +// TAO spcific POA locking policy (non-standard) +// +// ************************************************** + +class TAO_Export TAO_POA_Locking_Policy : public POA_PortableServer::TAO_POA_LockingPolicy +{ +public: + TAO_POA_Locking_Policy (PortableServer::TAO_POA_LockingPolicyValue value, + PortableServer::POA_ptr poa); + + TAO_POA_Locking_Policy (const TAO_POA_Locking_Policy &rhs); + + virtual PortableServer::TAO_POA_LockingPolicyValue value (CORBA::Environment &env); + + virtual CORBA::Policy_ptr copy (CORBA::Environment &env); + + virtual void destroy (CORBA::Environment &env); + + virtual CORBA::PolicyType policy_type (CORBA::Environment &environment); + + virtual PortableServer::POA_ptr _default_POA (CORBA::Environment &env); + +protected: + PortableServer::TAO_POA_LockingPolicyValue value_; + + PortableServer::POA_var poa_; +}; + class TAO_Export TAO_POA_Policies { public: @@ -245,6 +275,15 @@ public: virtual PortableServer::RequestProcessingPolicyValue request_processing (void) const; virtual void request_processing (PortableServer::RequestProcessingPolicyValue value); + // ************************************************** + // + // TAO spcific POA locking policy (non-standard) + // + // ************************************************** + + virtual PortableServer::TAO_POA_LockingPolicyValue TAO_POA_locking (void) const; + virtual void TAO_POA_locking (PortableServer::TAO_POA_LockingPolicyValue value); + virtual void parse_policies (const CORBA::PolicyList &policies, CORBA::Environment &env); @@ -268,6 +307,14 @@ protected: PortableServer::ServantRetentionPolicyValue servant_retention_; PortableServer::RequestProcessingPolicyValue request_processing_; + + // ************************************************** + // + // TAO spcific POA locking policy (non-standard) + // + // ************************************************** + + PortableServer::TAO_POA_LockingPolicyValue TAO_POA_locking_; }; class TAO_Temporary_Creation_Time; @@ -365,6 +412,15 @@ public: virtual PortableServer::RequestProcessingPolicy_ptr create_request_processing_policy (PortableServer::RequestProcessingPolicyValue value, CORBA::Environment &env); + // ************************************************** + // + // TAO spcific POA locking policy (non-standard) + // + // ************************************************** + + virtual PortableServer::TAO_POA_LockingPolicy_ptr create_TAO_POA_locking_policy (PortableServer::TAO_POA_LockingPolicyValue value, + CORBA::Environment &env); + virtual CORBA::String the_name (CORBA::Environment &env); virtual PortableServer::POA_ptr the_parent (CORBA::Environment &env); @@ -594,7 +650,7 @@ protected: char c, int pos = TAO_POA::String::npos) const; -// Should really be protected, but some compilers complain + // Should really be protected, but some compilers complain public: enum LOCATION_RESULT { @@ -647,6 +703,8 @@ protected: static CORBA::ULong object_key_type_length (void); + virtual void create_internal_lock (void); + String name_; String complete_name_; @@ -673,7 +731,7 @@ protected: CHILDREN children_; - ACE_Lock_Adapter<ACE_Null_Mutex> lock_; + ACE_Lock *lock_; int closing_down_; @@ -738,7 +796,7 @@ protected: int closing_down_; - ACE_Lock_Adapter<ACE_Null_Mutex> lock_; + ACE_Lock *lock_; typedef ACE_Unbounded_Set<TAO_POA *> POA_COLLECTION; @@ -754,66 +812,6 @@ public: CORBA::Environment &env); }; -class TAO_Export TAO_Strategy_POA : public TAO_POA -{ -public: - - TAO_Strategy_POA (const String &adapter_name, - TAO_POA_Manager &poa_manager, - const TAO_POA_Policies &policies, - TAO_POA *parent, - CORBA::Environment &env); - - TAO_Strategy_POA (const String &adapter_name, - TAO_POA_Manager &poa_manager, - const TAO_POA_Policies &policies, - TAO_POA *parent, - TAO_Object_Table &active_object_map, - CORBA::Environment &env); - - virtual TAO_POA *clone (const String &adapter_name, - TAO_POA_Manager &poa_manager, - const TAO_POA_Policies &policies, - TAO_POA *parent, - CORBA::Environment &env); - - virtual TAO_POA *clone (const String &adapter_name, - TAO_POA_Manager &poa_manager, - const TAO_POA_Policies &policies, - TAO_POA *parent, - TAO_Object_Table &active_object_map, - CORBA::Environment &env); - - virtual ~TAO_Strategy_POA (void); - -protected: - - virtual ACE_Lock &lock (void); - - ACE_Lock *lock_; - - typedef TAO_Strategy_POA SELF; -}; - -class TAO_Export TAO_Strategy_POA_Manager : public TAO_POA_Manager -{ -public: - - TAO_Strategy_POA_Manager (void); - - virtual TAO_POA_Manager *clone (void); - - virtual ~TAO_Strategy_POA_Manager (void); - -protected: - - virtual ACE_Lock &lock (void); - - ACE_Lock *lock_; - - typedef TAO_Strategy_POA_Manager SELF; -}; - class TAO_Export TAO_POA_Current : public POA_PortableServer::Current { // = TITLE diff --git a/TAO/tao/POA.i b/TAO/tao/POA.i index 8424c29b3a4..b1d0cdf2ed9 100644 --- a/TAO/tao/POA.i +++ b/TAO/tao/POA.i @@ -87,6 +87,24 @@ TAO_POA_Policies::request_processing (PortableServer::RequestProcessingPolicyVal this->request_processing_ = value; } +// ************************************************** +// +// TAO spcific POA locking policy (non-standard) +// +// ************************************************** + +ACE_INLINE PortableServer::TAO_POA_LockingPolicyValue +TAO_POA_Policies::TAO_POA_locking (void) const +{ + return this->TAO_POA_locking_; +} + +ACE_INLINE void +TAO_POA_Policies::TAO_POA_locking (PortableServer::TAO_POA_LockingPolicyValue value) +{ + this->TAO_POA_locking_ = value; +} + ACE_INLINE int TAO_Creation_Time::creation_time_length (void) { @@ -234,7 +252,7 @@ TAO_POA::clone (const TAO_POA::String &adapter_name, ACE_INLINE ACE_Lock & TAO_POA::lock (void) { - return this->lock_; + return *this->lock_; } ACE_INLINE TAO_POA * @@ -576,7 +594,7 @@ TAO_POA::object_key_type_length (void) ACE_INLINE ACE_Lock & TAO_POA_Manager::lock (void) { - return this->lock_; + return *this->lock_; } ACE_INLINE TAO_POA_Manager * @@ -585,66 +603,6 @@ TAO_POA_Manager::clone (void) return new TAO_POA_Manager; } -ACE_INLINE -TAO_Strategy_POA::~TAO_Strategy_POA (void) -{ - delete this->lock_; -} - -ACE_INLINE TAO_POA * -TAO_Strategy_POA::clone (const TAO_POA::String &adapter_name, - TAO_POA_Manager &poa_manager, - const TAO_POA_Policies &policies, - TAO_POA *parent, - CORBA::Environment &env) -{ - return new SELF (adapter_name, - poa_manager, - policies, - parent, - env); -} - -ACE_INLINE TAO_POA * -TAO_Strategy_POA::clone (const TAO_POA::String &adapter_name, - TAO_POA_Manager &poa_manager, - const TAO_POA_Policies &policies, - TAO_POA *parent, - TAO_Object_Table &active_object_map, - CORBA::Environment &env) -{ - return new SELF (adapter_name, - poa_manager, - policies, - parent, - active_object_map, - env); -} - -ACE_INLINE ACE_Lock & -TAO_Strategy_POA::lock (void) -{ - return *this->lock_; -} - -ACE_INLINE -TAO_Strategy_POA_Manager::~TAO_Strategy_POA_Manager (void) -{ - delete this->lock_; -} - -ACE_INLINE TAO_POA_Manager * -TAO_Strategy_POA_Manager::clone (void) -{ - return new SELF; -} - -ACE_INLINE ACE_Lock & -TAO_Strategy_POA_Manager::lock (void) -{ - return *this->lock_; -} - ACE_INLINE void TAO_POA_Current::clear (void) { diff --git a/TAO/tao/POAC.cpp b/TAO/tao/POAC.cpp index 6c000e040a4..7ffeb9dac6b 100644 --- a/TAO/tao/POAC.cpp +++ b/TAO/tao/POAC.cpp @@ -197,21 +197,6 @@ PortableServer::ThreadPolicy_ptr PortableServer::ThreadPolicy::_narrow ( ); } -PortableServer::ThreadPolicy_ptr PortableServer::ThreadPolicy::_bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env) -{ - IIOP_Object *data = new IIOP_Object (host, port, key); - if (!data) return PortableServer::ThreadPolicy::_nil (); - // create the CORBA level proxy - CORBA::Object_ptr objref = new CORBA_Object (data); - if (objref == 0) - { - data->Release (); - env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); - return PortableServer::ThreadPolicy::_nil (); - } - return PortableServer::ThreadPolicy::_narrow (objref, env); -} - PortableServer::ThreadPolicyValue PortableServer::ThreadPolicy::value(CORBA::Environment &env) { static const TAO_Param_Data _get_PortableServer_ThreadPolicy_value_paramdata [] = @@ -302,21 +287,6 @@ PortableServer::LifespanPolicy_ptr PortableServer::LifespanPolicy::_narrow ( ); } -PortableServer::LifespanPolicy_ptr PortableServer::LifespanPolicy::_bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env) -{ - IIOP_Object *data = new IIOP_Object (host, port, key); - if (!data) return PortableServer::LifespanPolicy::_nil (); - // create the CORBA level proxy - CORBA::Object_ptr objref = new CORBA_Object (data); - if (objref == 0) - { - data->Release (); - env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); - return PortableServer::LifespanPolicy::_nil (); - } - return PortableServer::LifespanPolicy::_narrow (objref, env); -} - PortableServer::LifespanPolicyValue PortableServer::LifespanPolicy::value(CORBA::Environment &env) { static const TAO_Param_Data _get_PortableServer_LifespanPolicy_value_paramdata [] = @@ -407,21 +377,6 @@ PortableServer::IdUniquenessPolicy_ptr PortableServer::IdUniquenessPolicy::_narr ); } -PortableServer::IdUniquenessPolicy_ptr PortableServer::IdUniquenessPolicy::_bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env) -{ - IIOP_Object *data = new IIOP_Object (host, port, key); - if (!data) return PortableServer::IdUniquenessPolicy::_nil (); - // create the CORBA level proxy - CORBA::Object_ptr objref = new CORBA_Object (data); - if (objref == 0) - { - data->Release (); - env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); - return PortableServer::IdUniquenessPolicy::_nil (); - } - return PortableServer::IdUniquenessPolicy::_narrow (objref, env); -} - PortableServer::IdUniquenessPolicyValue PortableServer::IdUniquenessPolicy::value(CORBA::Environment &env) { static const TAO_Param_Data _get_PortableServer_IdUniquenessPolicy_value_paramdata [] = @@ -512,21 +467,6 @@ PortableServer::IdAssignmentPolicy_ptr PortableServer::IdAssignmentPolicy::_narr ); } -PortableServer::IdAssignmentPolicy_ptr PortableServer::IdAssignmentPolicy::_bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env) -{ - IIOP_Object *data = new IIOP_Object (host, port, key); - if (!data) return PortableServer::IdAssignmentPolicy::_nil (); - // create the CORBA level proxy - CORBA::Object_ptr objref = new CORBA_Object (data); - if (objref == 0) - { - data->Release (); - env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); - return PortableServer::IdAssignmentPolicy::_nil (); - } - return PortableServer::IdAssignmentPolicy::_narrow (objref, env); -} - PortableServer::IdAssignmentPolicyValue PortableServer::IdAssignmentPolicy::value(CORBA::Environment &env) { static const TAO_Param_Data _get_PortableServer_IdAssignmentPolicy_value_paramdata [] = @@ -617,21 +557,6 @@ PortableServer::ImplicitActivationPolicy_ptr PortableServer::ImplicitActivationP ); } -PortableServer::ImplicitActivationPolicy_ptr PortableServer::ImplicitActivationPolicy::_bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env) -{ - IIOP_Object *data = new IIOP_Object (host, port, key); - if (!data) return PortableServer::ImplicitActivationPolicy::_nil (); - // create the CORBA level proxy - CORBA::Object_ptr objref = new CORBA_Object (data); - if (objref == 0) - { - data->Release (); - env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); - return PortableServer::ImplicitActivationPolicy::_nil (); - } - return PortableServer::ImplicitActivationPolicy::_narrow (objref, env); -} - PortableServer::ImplicitActivationPolicyValue PortableServer::ImplicitActivationPolicy::value(CORBA::Environment &env) { static const TAO_Param_Data _get_PortableServer_ImplicitActivationPolicy_value_paramdata [] = @@ -722,21 +647,6 @@ PortableServer::ServantRetentionPolicy_ptr PortableServer::ServantRetentionPolic ); } -PortableServer::ServantRetentionPolicy_ptr PortableServer::ServantRetentionPolicy::_bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env) -{ - IIOP_Object *data = new IIOP_Object (host, port, key); - if (!data) return PortableServer::ServantRetentionPolicy::_nil (); - // create the CORBA level proxy - CORBA::Object_ptr objref = new CORBA_Object (data); - if (objref == 0) - { - data->Release (); - env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); - return PortableServer::ServantRetentionPolicy::_nil (); - } - return PortableServer::ServantRetentionPolicy::_narrow (objref, env); -} - PortableServer::ServantRetentionPolicyValue PortableServer::ServantRetentionPolicy::value(CORBA::Environment &env) { static const TAO_Param_Data _get_PortableServer_ServantRetentionPolicy_value_paramdata [] = @@ -829,21 +739,6 @@ PortableServer::RequestProcessingPolicy_ptr PortableServer::RequestProcessingPol ); } -PortableServer::RequestProcessingPolicy_ptr PortableServer::RequestProcessingPolicy::_bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env) -{ - IIOP_Object *data = new IIOP_Object (host, port, key); - if (!data) return PortableServer::RequestProcessingPolicy::_nil (); - // create the CORBA level proxy - CORBA::Object_ptr objref = new CORBA_Object (data); - if (objref == 0) - { - data->Release (); - env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); - return PortableServer::RequestProcessingPolicy::_nil (); - } - return PortableServer::RequestProcessingPolicy::_narrow (objref, env); -} - PortableServer::RequestProcessingPolicyValue PortableServer::RequestProcessingPolicy::value(CORBA::Environment &env) { static const TAO_Param_Data _get_PortableServer_RequestProcessingPolicy_value_paramdata [] = @@ -888,6 +783,103 @@ static const CORBA::Long _oc_PortableServer_RequestProcessingPolicy[] = static CORBA::TypeCode _tc__tc_PortableServer_RequestProcessingPolicy (CORBA::tk_objref, sizeof (_oc_PortableServer_RequestProcessingPolicy), (char *) &_oc_PortableServer_RequestProcessingPolicy, CORBA::B_FALSE); CORBA::TypeCode_ptr PortableServer::_tc_RequestProcessingPolicy = &_tc__tc_PortableServer_RequestProcessingPolicy; +// ************************************************** +// +// TAO spcific POA locking policy (non-standard) +// +// ************************************************** + +static const CORBA::Long _oc_PortableServer_TAO_POA_LockingPolicyValue[] = +{ + TAO_ENCAP_BYTE_ORDER, // byte order + 50, ACE_NTOHL (0x49444c3a), ACE_NTOHL (0x506f7274), ACE_NTOHL (0x61626c65), ACE_NTOHL (0x53657276), ACE_NTOHL (0x65722f54), ACE_NTOHL (0x414f5f50), ACE_NTOHL (0x4f415f4c), ACE_NTOHL (0x6f636b69), ACE_NTOHL (0x6e67506f), ACE_NTOHL (0x6c696379), ACE_NTOHL (0x56616c75), ACE_NTOHL (0x653a312e), ACE_NTOHL (0x3000fdfd), // repository ID = IDL:PortableServer/TAO_POA_LockingPolicyValue:1.0 + 27, ACE_NTOHL (0x54414f5f), ACE_NTOHL (0x504f415f), ACE_NTOHL (0x4c6f636b), ACE_NTOHL (0x696e6750), ACE_NTOHL (0x6f6c6963), ACE_NTOHL (0x7956616c), ACE_NTOHL (0x756500fd), // name = TAO_POA_LockingPolicyValue + 3, // member count + 17, ACE_NTOHL (0x5553455f), ACE_NTOHL (0x44454641), ACE_NTOHL (0x554c545f), ACE_NTOHL (0x4c4f434b), ACE_NTOHL (0xfdfdfd), // name = USE_DEFAULT_LOCK + 14, ACE_NTOHL (0x5553455f), ACE_NTOHL (0x4e554c4c), ACE_NTOHL (0x5f4c4f43), ACE_NTOHL (0x4b00fdfd), // name = USE_NULL_LOCK + 16, ACE_NTOHL (0x5553455f), ACE_NTOHL (0x54485245), ACE_NTOHL (0x41445f4c), ACE_NTOHL (0x4f434b00), // name = USE_THREAD_LOCK +}; +static CORBA::TypeCode _tc__tc_PortableServer_TAO_POA_LockingPolicyValue (CORBA::tk_enum, sizeof (_oc_PortableServer_TAO_POA_LockingPolicyValue), (char *) &_oc_PortableServer_TAO_POA_LockingPolicyValue, CORBA::B_FALSE); +CORBA::TypeCode_ptr PortableServer::_tc_TAO_POA_LockingPolicyValue = &_tc__tc_PortableServer_TAO_POA_LockingPolicyValue; + +PortableServer::TAO_POA_LockingPolicy_ptr PortableServer::TAO_POA_LockingPolicy::_duplicate (PortableServer::TAO_POA_LockingPolicy_ptr obj) +{ + if (!CORBA::is_nil (obj)) + obj->AddRef (); + + return obj; +} // end of _duplicate + +PortableServer::TAO_POA_LockingPolicy_ptr PortableServer::TAO_POA_LockingPolicy::_narrow ( + CORBA::Object_ptr obj, + CORBA::Environment &env + ) +{ + if (CORBA::is_nil (obj)) + return PortableServer::TAO_POA_LockingPolicy::_nil (); + if (!obj->_is_a ("IDL:PortableServer/TAO_POA_LockingPolicy:1.0", env)) + return PortableServer::TAO_POA_LockingPolicy::_nil (); + if (!obj->_is_collocated () || !obj->_servant()) + { + PortableServer::TAO_POA_LockingPolicy_ptr + new_obj = new PortableServer::TAO_POA_LockingPolicy (obj->_get_parent ()); // construct obj ref using the stub object + return new_obj; + } // end of if + + STUB_Object *stub = obj->_servant ()->_create_stub (env); + if (env.exception () != 0) + return PortableServer::TAO_POA_LockingPolicy::_nil (); + void* servant = obj->_servant ()->_downcast ("IDL:PortableServer/TAO_POA_LockingPolicy:1.0"); + return new POA_PortableServer::_tao_collocated_TAO_POA_LockingPolicy( + ACE_reinterpret_cast(POA_PortableServer::TAO_POA_LockingPolicy_ptr, servant), + stub + ); +} + +PortableServer::TAO_POA_LockingPolicyValue PortableServer::TAO_POA_LockingPolicy::value(CORBA::Environment &env) +{ + static const TAO_Param_Data _get_PortableServer_TAO_POA_LockingPolicy_value_paramdata [] = + { + {PortableServer::_tc_TAO_POA_LockingPolicyValue, PARAM_RETURN, 0}}; + + static const TAO_Call_Data _get_PortableServer_TAO_POA_LockingPolicy_value_calldata = + {"_get_value", 1, 1, _get_PortableServer_TAO_POA_LockingPolicy_value_paramdata, 0, 0}; + + PortableServer::TAO_POA_LockingPolicyValue retval = + ACE_static_cast (PortableServer::TAO_POA_LockingPolicyValue, -1); + STUB_Object *istub; + + if (this->QueryInterface (IID_STUB_Object, (void **)&istub) != TAO_NOERROR) + { + env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); + return retval; + } + this->Release (); // QueryInterface has bumped up our refcount + istub->do_static_call (env, &_get_PortableServer_TAO_POA_LockingPolicy_value_calldata, &retval); + return retval; + +} + +CORBA::Boolean PortableServer::TAO_POA_LockingPolicy::_is_a (const CORBA::Char *value, CORBA::Environment &_tao_environment) +{ + if ( + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/TAO_POA_LockingPolicy:1.0")) || + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_environment)))) + return 1; // success using local knowledge + else + return this->CORBA_Object::_is_a (value, _tao_environment); // remote call +} + +static const CORBA::Long _oc_PortableServer_TAO_POA_LockingPolicy[] = +{ + TAO_ENCAP_BYTE_ORDER, // byte order + 45, ACE_NTOHL (0x49444c3a), ACE_NTOHL (0x506f7274), ACE_NTOHL (0x61626c65), ACE_NTOHL (0x53657276), ACE_NTOHL (0x65722f54), ACE_NTOHL (0x414f5f50), ACE_NTOHL (0x4f415f4c), ACE_NTOHL (0x6f636b69), ACE_NTOHL (0x6e67506f), ACE_NTOHL (0x6c696379), ACE_NTOHL (0x3a312e30), ACE_NTOHL (0xfdfdfd), // repository ID = IDL:PortableServer/TAO_POA_LockingPolicy:1.0 + 22, ACE_NTOHL (0x54414f5f), ACE_NTOHL (0x504f415f), ACE_NTOHL (0x4c6f636b), ACE_NTOHL (0x696e6750), ACE_NTOHL (0x6f6c6963), ACE_NTOHL (0x7900fdfd), // name = TAO_POA_LockingPolicy, +}; +static CORBA::TypeCode _tc__tc_PortableServer_TAO_POA_LockingPolicy (CORBA::tk_objref, sizeof (_oc_PortableServer_TAO_POA_LockingPolicy), (char *) &_oc_PortableServer_TAO_POA_LockingPolicy, CORBA::B_FALSE); +CORBA::TypeCode_ptr PortableServer::_tc_TAO_POA_LockingPolicy = &_tc__tc_PortableServer_TAO_POA_LockingPolicy; + PortableServer::POAManager_ptr PortableServer::POAManager::_duplicate (PortableServer::POAManager_ptr obj) { if (!CORBA::is_nil (obj)) @@ -922,21 +914,6 @@ PortableServer::POAManager_ptr PortableServer::POAManager::_narrow ( ); } -PortableServer::POAManager_ptr PortableServer::POAManager::_bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env) -{ - IIOP_Object *data = new IIOP_Object (host, port, key); - if (!data) return PortableServer::POAManager::_nil (); - // create the CORBA level proxy - CORBA::Object_ptr objref = new CORBA_Object (data); - if (objref == 0) - { - data->Release (); - env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); - return PortableServer::POAManager::_nil (); - } - return PortableServer::POAManager::_narrow (objref, env); -} - // default constructor PortableServer::POAManager::AdapterInactive::AdapterInactive (void) : CORBA_SystemException (PortableServer::POAManager::_tc_AdapterInactive, 0xffff0000L, CORBA::COMPLETED_NO) @@ -1078,21 +1055,6 @@ PortableServer::AdapterActivator_ptr PortableServer::AdapterActivator::_narrow ( ); } -PortableServer::AdapterActivator_ptr PortableServer::AdapterActivator::_bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env) -{ - IIOP_Object *data = new IIOP_Object (host, port, key); - if (!data) return PortableServer::AdapterActivator::_nil (); - // create the CORBA level proxy - CORBA::Object_ptr objref = new CORBA_Object (data); - if (objref == 0) - { - data->Release (); - env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); - return PortableServer::AdapterActivator::_nil (); - } - return PortableServer::AdapterActivator::_narrow (objref, env); -} - CORBA::Boolean PortableServer::AdapterActivator::_is_a (const CORBA::Char *value, CORBA::Environment &_tao_environment) { if ( @@ -1146,21 +1108,6 @@ PortableServer::ServantManager_ptr PortableServer::ServantManager::_narrow ( ); } -PortableServer::ServantManager_ptr PortableServer::ServantManager::_bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env) -{ - IIOP_Object *data = new IIOP_Object (host, port, key); - if (!data) return PortableServer::ServantManager::_nil (); - // create the CORBA level proxy - CORBA::Object_ptr objref = new CORBA_Object (data); - if (objref == 0) - { - data->Release (); - env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); - return PortableServer::ServantManager::_nil (); - } - return PortableServer::ServantManager::_narrow (objref, env); -} - CORBA::Boolean PortableServer::ServantManager::_is_a (const CORBA::Char *value, CORBA::Environment &_tao_environment) { if ( @@ -1214,21 +1161,6 @@ PortableServer::ServantActivator_ptr PortableServer::ServantActivator::_narrow ( ); } -PortableServer::ServantActivator_ptr PortableServer::ServantActivator::_bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env) -{ - IIOP_Object *data = new IIOP_Object (host, port, key); - if (!data) return PortableServer::ServantActivator::_nil (); - // create the CORBA level proxy - CORBA::Object_ptr objref = new CORBA_Object (data); - if (objref == 0) - { - data->Release (); - env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); - return PortableServer::ServantActivator::_nil (); - } - return PortableServer::ServantActivator::_narrow (objref, env); -} - CORBA::Boolean PortableServer::ServantActivator::_is_a (const CORBA::Char *value, CORBA::Environment &_tao_environment) { if ( @@ -1283,21 +1215,6 @@ PortableServer::ServantLocator_ptr PortableServer::ServantLocator::_narrow ( ); } -PortableServer::ServantLocator_ptr PortableServer::ServantLocator::_bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env) -{ - IIOP_Object *data = new IIOP_Object (host, port, key); - if (!data) return PortableServer::ServantLocator::_nil (); - // create the CORBA level proxy - CORBA::Object_ptr objref = new CORBA_Object (data); - if (objref == 0) - { - data->Release (); - env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); - return PortableServer::ServantLocator::_nil (); - } - return PortableServer::ServantLocator::_narrow (objref, env); -} - CORBA::Boolean PortableServer::ServantLocator::_is_a (const CORBA::Char *value, CORBA::Environment &_tao_environment) { if ( @@ -1352,21 +1269,6 @@ PortableServer::POA_ptr PortableServer::POA::_narrow ( ); } -PortableServer::POA_ptr PortableServer::POA::_bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env) -{ - IIOP_Object *data = new IIOP_Object (host, port, key); - if (!data) return PortableServer::POA::_nil (); - // create the CORBA level proxy - CORBA::Object_ptr objref = new CORBA_Object (data); - if (objref == 0) - { - data->Release (); - env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); - return PortableServer::POA::_nil (); - } - return PortableServer::POA::_narrow (objref, env); -} - // default constructor PortableServer::POA::AdapterAlreadyExists::AdapterAlreadyExists (void) : CORBA_SystemException (PortableServer::POA::_tc_AdapterAlreadyExists, 0xffff0000L, CORBA::COMPLETED_NO) @@ -2397,21 +2299,6 @@ PortableServer::Current_ptr PortableServer::Current::_narrow ( ); } -PortableServer::Current_ptr PortableServer::Current::_bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env) -{ - IIOP_Object *data = new IIOP_Object (host, port, key); - if (!data) return PortableServer::Current::_nil (); - // create the CORBA level proxy - CORBA::Object_ptr objref = new CORBA_Object (data); - if (objref == 0) - { - data->Release (); - env.exception (new CORBA::DATA_CONVERSION (CORBA::COMPLETED_NO)); - return PortableServer::Current::_nil (); - } - return PortableServer::Current::_narrow (objref, env); -} - // default constructor PortableServer::Current::NoContext::NoContext (void) : CORBA_SystemException (PortableServer::Current::_tc_NoContext, 0xffff0000L, CORBA::COMPLETED_NO) diff --git a/TAO/tao/POAC.h b/TAO/tao/POAC.h index 735a03bca3b..861696a42e7 100644 --- a/TAO/tao/POAC.h +++ b/TAO/tao/POAC.h @@ -116,7 +116,7 @@ public: #if !defined (_PORTABLESERVER__TAO_SEQ_OCTET___VAR_CH_) #define _PORTABLESERVER__TAO_SEQ_OCTET___VAR_CH_ -// ************************************************************* + // ************************************************************* // class PortableServer::_tao_seq_Octet_var // ************************************************************* @@ -203,7 +203,7 @@ public: ForwardRequest (const ForwardRequest &); // copy ctor ~ForwardRequest (void); // dtor ForwardRequest( - const CORBA::Object_ptr _tao_forward_reference); + const CORBA::Object_ptr _tao_forward_reference); ForwardRequest &operator= (const ForwardRequest &); static ForwardRequest *_narrow (CORBA::Exception *); @@ -211,10 +211,10 @@ public: // the alloc method. This is TAO extension static CORBA::Exception *_alloc (void); }; // exception PortableServer::ForwardRequest - friend void operator<<= (CORBA::Any &, const ForwardRequest &); // copying version + friend void operator<<= (CORBA::Any &, const ForwardRequest &); // copying version friend void operator<<= (CORBA::Any &, ForwardRequest*); // noncopying version friend CORBA::Boolean operator>>= (const CORBA::Any &, ForwardRequest *&); -static CORBA::TypeCode_ptr _tc_ForwardRequest; + static CORBA::TypeCode_ptr _tc_ForwardRequest; #endif /* end #if !defined */ @@ -231,7 +231,7 @@ static CORBA::TypeCode_ptr _tc_ForwardRequest; #if !defined (_PORTABLESERVER_THREADPOLICY___PTR_CH_) #define _PORTABLESERVER_THREADPOLICY___PTR_CH_ -class ThreadPolicy; + class ThreadPolicy; typedef ThreadPolicy *ThreadPolicy_ptr; #endif // end #if !defined @@ -303,16 +303,15 @@ class ThreadPolicy; static ThreadPolicy_ptr _duplicate (ThreadPolicy_ptr obj); static ThreadPolicy_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); static ThreadPolicy_ptr _nil (void); - static ThreadPolicy_ptr _bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env); virtual ThreadPolicyValue value (CORBA::Environment &env); virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); protected: ThreadPolicy ( - STUB_Object *objref = 0, - TAO_ServantBase *servant = 0, - CORBA::Boolean collocated = CORBA::B_FALSE - ); + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); public: virtual ~ThreadPolicy (void); private: @@ -337,7 +336,7 @@ class ThreadPolicy; #if !defined (_PORTABLESERVER_LIFESPANPOLICY___PTR_CH_) #define _PORTABLESERVER_LIFESPANPOLICY___PTR_CH_ -class LifespanPolicy; + class LifespanPolicy; typedef LifespanPolicy *LifespanPolicy_ptr; #endif // end #if !defined @@ -409,16 +408,15 @@ class LifespanPolicy; static LifespanPolicy_ptr _duplicate (LifespanPolicy_ptr obj); static LifespanPolicy_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); static LifespanPolicy_ptr _nil (void); - static LifespanPolicy_ptr _bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env); virtual LifespanPolicyValue value (CORBA::Environment &env); virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); protected: LifespanPolicy ( - STUB_Object *objref = 0, - TAO_ServantBase *servant = 0, - CORBA::Boolean collocated = CORBA::B_FALSE - ); + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); public: virtual ~LifespanPolicy (void); private: @@ -443,7 +441,7 @@ class LifespanPolicy; #if !defined (_PORTABLESERVER_IDUNIQUENESSPOLICY___PTR_CH_) #define _PORTABLESERVER_IDUNIQUENESSPOLICY___PTR_CH_ -class IdUniquenessPolicy; + class IdUniquenessPolicy; typedef IdUniquenessPolicy *IdUniquenessPolicy_ptr; #endif // end #if !defined @@ -515,16 +513,15 @@ class IdUniquenessPolicy; static IdUniquenessPolicy_ptr _duplicate (IdUniquenessPolicy_ptr obj); static IdUniquenessPolicy_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); static IdUniquenessPolicy_ptr _nil (void); - static IdUniquenessPolicy_ptr _bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env); virtual IdUniquenessPolicyValue value (CORBA::Environment &env); virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); protected: IdUniquenessPolicy ( - STUB_Object *objref = 0, - TAO_ServantBase *servant = 0, - CORBA::Boolean collocated = CORBA::B_FALSE - ); + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); public: virtual ~IdUniquenessPolicy (void); private: @@ -549,7 +546,7 @@ class IdUniquenessPolicy; #if !defined (_PORTABLESERVER_IDASSIGNMENTPOLICY___PTR_CH_) #define _PORTABLESERVER_IDASSIGNMENTPOLICY___PTR_CH_ -class IdAssignmentPolicy; + class IdAssignmentPolicy; typedef IdAssignmentPolicy *IdAssignmentPolicy_ptr; #endif // end #if !defined @@ -621,16 +618,15 @@ class IdAssignmentPolicy; static IdAssignmentPolicy_ptr _duplicate (IdAssignmentPolicy_ptr obj); static IdAssignmentPolicy_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); static IdAssignmentPolicy_ptr _nil (void); - static IdAssignmentPolicy_ptr _bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env); virtual IdAssignmentPolicyValue value (CORBA::Environment &env); virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); protected: IdAssignmentPolicy ( - STUB_Object *objref = 0, - TAO_ServantBase *servant = 0, - CORBA::Boolean collocated = CORBA::B_FALSE - ); + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); public: virtual ~IdAssignmentPolicy (void); private: @@ -655,7 +651,7 @@ class IdAssignmentPolicy; #if !defined (_PORTABLESERVER_IMPLICITACTIVATIONPOLICY___PTR_CH_) #define _PORTABLESERVER_IMPLICITACTIVATIONPOLICY___PTR_CH_ -class ImplicitActivationPolicy; + class ImplicitActivationPolicy; typedef ImplicitActivationPolicy *ImplicitActivationPolicy_ptr; #endif // end #if !defined @@ -727,16 +723,15 @@ class ImplicitActivationPolicy; static ImplicitActivationPolicy_ptr _duplicate (ImplicitActivationPolicy_ptr obj); static ImplicitActivationPolicy_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); static ImplicitActivationPolicy_ptr _nil (void); - static ImplicitActivationPolicy_ptr _bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env); virtual ImplicitActivationPolicyValue value (CORBA::Environment &env); virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); protected: ImplicitActivationPolicy ( - STUB_Object *objref = 0, - TAO_ServantBase *servant = 0, - CORBA::Boolean collocated = CORBA::B_FALSE - ); + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); public: virtual ~ImplicitActivationPolicy (void); private: @@ -761,7 +756,7 @@ class ImplicitActivationPolicy; #if !defined (_PORTABLESERVER_SERVANTRETENTIONPOLICY___PTR_CH_) #define _PORTABLESERVER_SERVANTRETENTIONPOLICY___PTR_CH_ -class ServantRetentionPolicy; + class ServantRetentionPolicy; typedef ServantRetentionPolicy *ServantRetentionPolicy_ptr; #endif // end #if !defined @@ -833,16 +828,15 @@ class ServantRetentionPolicy; static ServantRetentionPolicy_ptr _duplicate (ServantRetentionPolicy_ptr obj); static ServantRetentionPolicy_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); static ServantRetentionPolicy_ptr _nil (void); - static ServantRetentionPolicy_ptr _bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env); virtual ServantRetentionPolicyValue value (CORBA::Environment &env); virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); protected: ServantRetentionPolicy ( - STUB_Object *objref = 0, - TAO_ServantBase *servant = 0, - CORBA::Boolean collocated = CORBA::B_FALSE - ); + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); public: virtual ~ServantRetentionPolicy (void); private: @@ -868,7 +862,7 @@ class ServantRetentionPolicy; #if !defined (_PORTABLESERVER_REQUESTPROCESSINGPOLICY___PTR_CH_) #define _PORTABLESERVER_REQUESTPROCESSINGPOLICY___PTR_CH_ -class RequestProcessingPolicy; + class RequestProcessingPolicy; typedef RequestProcessingPolicy *RequestProcessingPolicy_ptr; #endif // end #if !defined @@ -940,16 +934,15 @@ class RequestProcessingPolicy; static RequestProcessingPolicy_ptr _duplicate (RequestProcessingPolicy_ptr obj); static RequestProcessingPolicy_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); static RequestProcessingPolicy_ptr _nil (void); - static RequestProcessingPolicy_ptr _bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env); virtual RequestProcessingPolicyValue value (CORBA::Environment &env); virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); protected: RequestProcessingPolicy ( - STUB_Object *objref = 0, - TAO_ServantBase *servant = 0, - CORBA::Boolean collocated = CORBA::B_FALSE - ); + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); public: virtual ~RequestProcessingPolicy (void); private: @@ -962,11 +955,123 @@ class RequestProcessingPolicy; static CORBA::TypeCode_ptr _tc_RequestProcessingPolicy; + // ************************************************** + // + // TAO spcific POA locking policy (non-standard) + // + // ************************************************** + + enum TAO_POA_LockingPolicyValue + { + USE_DEFAULT_LOCK, + USE_NULL_LOCK, + USE_THREAD_LOCK + }; + typedef TAO_POA_LockingPolicyValue &TAO_POA_LockingPolicyValue_out; + static CORBA::TypeCode_ptr _tc_TAO_POA_LockingPolicyValue; + + +#if !defined (_PORTABLESERVER_TAO_POA_LOCKINGPOLICY___PTR_CH_) +#define _PORTABLESERVER_TAO_POA_LOCKINGPOLICY___PTR_CH_ + + class TAO_POA_LockingPolicy; + typedef TAO_POA_LockingPolicy *TAO_POA_LockingPolicy_ptr; + +#endif // end #if !defined + + +#if !defined (_PORTABLESERVER_TAO_POA_LOCKINGPOLICY___VAR_CH_) +#define _PORTABLESERVER_TAO_POA_LOCKINGPOLICY___VAR_CH_ + + class TAO_Export TAO_POA_LockingPolicy_var + { + public: + TAO_POA_LockingPolicy_var (void); // default constructor + TAO_POA_LockingPolicy_var (TAO_POA_LockingPolicy_ptr); + TAO_POA_LockingPolicy_var (const TAO_POA_LockingPolicy_var &); // copy constructor + ~TAO_POA_LockingPolicy_var (void); // destructor + + TAO_POA_LockingPolicy_var &operator= (TAO_POA_LockingPolicy_ptr); + TAO_POA_LockingPolicy_var &operator= (const TAO_POA_LockingPolicy_var &); + TAO_POA_LockingPolicy_ptr operator-> (void) const; + + operator const TAO_POA_LockingPolicy_ptr &() const; + operator TAO_POA_LockingPolicy_ptr &(); + // in, inout, out, _retn + TAO_POA_LockingPolicy_ptr in (void) const; + TAO_POA_LockingPolicy_ptr &inout (void); + TAO_POA_LockingPolicy_ptr &out (void); + TAO_POA_LockingPolicy_ptr _retn (void); + TAO_POA_LockingPolicy_ptr ptr (void) const; + + private: + TAO_POA_LockingPolicy_ptr ptr_; + }; + + +#endif // end #if !defined + + +#if !defined (_PORTABLESERVER_TAO_POA_LOCKINGPOLICY___OUT_CH_) +#define _PORTABLESERVER_TAO_POA_LOCKINGPOLICY___OUT_CH_ + + class TAO_Export TAO_POA_LockingPolicy_out + { + public: + TAO_POA_LockingPolicy_out (TAO_POA_LockingPolicy_ptr &); + TAO_POA_LockingPolicy_out (TAO_POA_LockingPolicy_var &); + TAO_POA_LockingPolicy_out (TAO_POA_LockingPolicy_out &); + TAO_POA_LockingPolicy_out &operator= (TAO_POA_LockingPolicy_out &); + TAO_POA_LockingPolicy_out &operator= (const TAO_POA_LockingPolicy_var &); + TAO_POA_LockingPolicy_out &operator= (TAO_POA_LockingPolicy_ptr); + operator TAO_POA_LockingPolicy_ptr &(); + TAO_POA_LockingPolicy_ptr &ptr (void); + TAO_POA_LockingPolicy_ptr operator-> (void); + + private: + TAO_POA_LockingPolicy_ptr &ptr_; + }; + + +#endif // end #if !defined + + +#if !defined (_PORTABLESERVER_TAO_POA_LOCKINGPOLICY_CH_) +#define _PORTABLESERVER_TAO_POA_LOCKINGPOLICY_CH_ + + class TAO_Export TAO_POA_LockingPolicy: public virtual CORBA::Policy + { + public: + // the static operations + static TAO_POA_LockingPolicy_ptr _duplicate (TAO_POA_LockingPolicy_ptr obj); + static TAO_POA_LockingPolicy_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); + static TAO_POA_LockingPolicy_ptr _nil (void); + + virtual TAO_POA_LockingPolicyValue value (CORBA::Environment &env); + virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); + protected: + TAO_POA_LockingPolicy ( + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); + public: + virtual ~TAO_POA_LockingPolicy (void); + private: + TAO_POA_LockingPolicy (const TAO_POA_LockingPolicy&); + void operator= (const TAO_POA_LockingPolicy&); + }; + + +#endif // end #if !defined + + static CORBA::TypeCode_ptr _tc_TAO_POA_LockingPolicy; + #if !defined (_PORTABLESERVER_POAMANAGER___PTR_CH_) #define _PORTABLESERVER_POAMANAGER___PTR_CH_ -class POAManager; + class POAManager; typedef POAManager *POAManager_ptr; #endif // end #if !defined @@ -1038,7 +1143,6 @@ class POAManager; static POAManager_ptr _duplicate (POAManager_ptr obj); static POAManager_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); static POAManager_ptr _nil (void); - static POAManager_ptr _bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env); #if !defined (_PORTABLESERVER_POAMANAGER_ADAPTERINACTIVE___PTR_CH_) @@ -1059,15 +1163,15 @@ class POAManager; AdapterInactive (void); // default ctor AdapterInactive (const AdapterInactive &); // copy ctor ~AdapterInactive (void); // dtor - AdapterInactive &operator= (const AdapterInactive &); + AdapterInactive &operator= (const AdapterInactive &); static AdapterInactive *_narrow (CORBA::Exception *); // the alloc method. This is TAO extension static CORBA::Exception *_alloc (void); }; // exception PortableServer::POAManager::AdapterInactive - friend void operator<<= (CORBA::Any &, const AdapterInactive &); // copying version + friend void operator<<= (CORBA::Any &, const AdapterInactive &); // copying version friend void operator<<= (CORBA::Any &, AdapterInactive*); // noncopying version friend CORBA::Boolean operator>>= (const CORBA::Any &, AdapterInactive *&); -static CORBA::TypeCode_ptr _tc_AdapterInactive; + static CORBA::TypeCode_ptr _tc_AdapterInactive; #endif // end #if !defined @@ -1079,10 +1183,10 @@ static CORBA::TypeCode_ptr _tc_AdapterInactive; virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); protected: POAManager ( - STUB_Object *objref = 0, - TAO_ServantBase *servant = 0, - CORBA::Boolean collocated = CORBA::B_FALSE - ); + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); public: virtual ~POAManager (void); private: @@ -1099,7 +1203,7 @@ static CORBA::TypeCode_ptr _tc_AdapterInactive; #if !defined (_PORTABLESERVER_ADAPTERACTIVATOR___PTR_CH_) #define _PORTABLESERVER_ADAPTERACTIVATOR___PTR_CH_ -class AdapterActivator; + class AdapterActivator; typedef AdapterActivator *AdapterActivator_ptr; #endif // end #if !defined @@ -1171,16 +1275,15 @@ class AdapterActivator; static AdapterActivator_ptr _duplicate (AdapterActivator_ptr obj); static AdapterActivator_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); static AdapterActivator_ptr _nil (void); - static AdapterActivator_ptr _bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env); virtual CORBA::Boolean unknown_adapter (POA_ptr parent, const char *name, CORBA::Environment &env) = 0; virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); protected: AdapterActivator ( - STUB_Object *objref = 0, - TAO_ServantBase *servant = 0, - CORBA::Boolean collocated = CORBA::B_FALSE - ); + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); public: virtual ~AdapterActivator (void); private: @@ -1197,7 +1300,7 @@ class AdapterActivator; #if !defined (_PORTABLESERVER_SERVANTMANAGER___PTR_CH_) #define _PORTABLESERVER_SERVANTMANAGER___PTR_CH_ -class ServantManager; + class ServantManager; typedef ServantManager *ServantManager_ptr; #endif // end #if !defined @@ -1269,15 +1372,14 @@ class ServantManager; static ServantManager_ptr _duplicate (ServantManager_ptr obj); static ServantManager_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); static ServantManager_ptr _nil (void); - static ServantManager_ptr _bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env); virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); protected: ServantManager ( - STUB_Object *objref = 0, - TAO_ServantBase *servant = 0, - CORBA::Boolean collocated = CORBA::B_FALSE - ); + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); public: virtual ~ServantManager (void); private: @@ -1294,7 +1396,7 @@ class ServantManager; #if !defined (_PORTABLESERVER_SERVANTACTIVATOR___PTR_CH_) #define _PORTABLESERVER_SERVANTACTIVATOR___PTR_CH_ -class ServantActivator; + class ServantActivator; typedef ServantActivator *ServantActivator_ptr; #endif // end #if !defined @@ -1366,17 +1468,16 @@ class ServantActivator; static ServantActivator_ptr _duplicate (ServantActivator_ptr obj); static ServantActivator_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); static ServantActivator_ptr _nil (void); - static ServantActivator_ptr _bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env); virtual Servant incarnate (const ObjectId &oid, POA_ptr adapter, CORBA::Environment &env) = 0; virtual void etherealize (const ObjectId &oid, POA_ptr adapter, Servant serv, CORBA::Boolean cleanup_in_progress, CORBA::Boolean remaining_activations, CORBA::Environment &env) = 0; virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); protected: ServantActivator ( - STUB_Object *objref = 0, - TAO_ServantBase *servant = 0, - CORBA::Boolean collocated = CORBA::B_FALSE - ); + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); public: virtual ~ServantActivator (void); private: @@ -1393,7 +1494,7 @@ class ServantActivator; #if !defined (_PORTABLESERVER_SERVANTLOCATOR___PTR_CH_) #define _PORTABLESERVER_SERVANTLOCATOR___PTR_CH_ -class ServantLocator; + class ServantLocator; typedef ServantLocator *ServantLocator_ptr; #endif // end #if !defined @@ -1468,17 +1569,16 @@ class ServantLocator; static ServantLocator_ptr _duplicate (ServantLocator_ptr obj); static ServantLocator_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); static ServantLocator_ptr _nil (void); - static ServantLocator_ptr _bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env); virtual Servant preinvoke (const ObjectId &oid, POA_ptr adapter, const char *operation, Cookie & the_cookie, CORBA::Environment &env) = 0; virtual void postinvoke (const ObjectId &oid, POA_ptr adapter, const char *operation, Cookie the_cookie, Servant the_servant, CORBA::Environment &env) = 0; virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); protected: ServantLocator ( - STUB_Object *objref = 0, - TAO_ServantBase *servant = 0, - CORBA::Boolean collocated = CORBA::B_FALSE - ); + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); public: virtual ~ServantLocator (void); private: @@ -1495,7 +1595,7 @@ class ServantLocator; #if !defined (_PORTABLESERVER_POA___PTR_CH_) #define _PORTABLESERVER_POA___PTR_CH_ -class POA; + class POA; typedef POA *POA_ptr; #endif // end #if !defined @@ -1567,7 +1667,6 @@ class POA; static POA_ptr _duplicate (POA_ptr obj); static POA_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); static POA_ptr _nil (void); - static POA_ptr _bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env); #if !defined (_PORTABLESERVER_POA_ADAPTERALREADYEXISTS___PTR_CH_) @@ -1588,15 +1687,15 @@ class POA; AdapterAlreadyExists (void); // default ctor AdapterAlreadyExists (const AdapterAlreadyExists &); // copy ctor ~AdapterAlreadyExists (void); // dtor - AdapterAlreadyExists &operator= (const AdapterAlreadyExists &); + AdapterAlreadyExists &operator= (const AdapterAlreadyExists &); static AdapterAlreadyExists *_narrow (CORBA::Exception *); // the alloc method. This is TAO extension static CORBA::Exception *_alloc (void); }; // exception PortableServer::POA::AdapterAlreadyExists - friend void operator<<= (CORBA::Any &, const AdapterAlreadyExists &); // copying version + friend void operator<<= (CORBA::Any &, const AdapterAlreadyExists &); // copying version friend void operator<<= (CORBA::Any &, AdapterAlreadyExists*); // noncopying version friend CORBA::Boolean operator>>= (const CORBA::Any &, AdapterAlreadyExists *&); -static CORBA::TypeCode_ptr _tc_AdapterAlreadyExists; + static CORBA::TypeCode_ptr _tc_AdapterAlreadyExists; #endif // end #if !defined @@ -1620,15 +1719,15 @@ static CORBA::TypeCode_ptr _tc_AdapterAlreadyExists; AdapterInactive (void); // default ctor AdapterInactive (const AdapterInactive &); // copy ctor ~AdapterInactive (void); // dtor - AdapterInactive &operator= (const AdapterInactive &); + AdapterInactive &operator= (const AdapterInactive &); static AdapterInactive *_narrow (CORBA::Exception *); // the alloc method. This is TAO extension static CORBA::Exception *_alloc (void); }; // exception PortableServer::POA::AdapterInactive - friend void operator<<= (CORBA::Any &, const AdapterInactive &); // copying version + friend void operator<<= (CORBA::Any &, const AdapterInactive &); // copying version friend void operator<<= (CORBA::Any &, AdapterInactive*); // noncopying version friend CORBA::Boolean operator>>= (const CORBA::Any &, AdapterInactive *&); -static CORBA::TypeCode_ptr _tc_AdapterInactive; + static CORBA::TypeCode_ptr _tc_AdapterInactive; #endif // end #if !defined @@ -1652,15 +1751,15 @@ static CORBA::TypeCode_ptr _tc_AdapterInactive; AdapterNonExistent (void); // default ctor AdapterNonExistent (const AdapterNonExistent &); // copy ctor ~AdapterNonExistent (void); // dtor - AdapterNonExistent &operator= (const AdapterNonExistent &); + AdapterNonExistent &operator= (const AdapterNonExistent &); static AdapterNonExistent *_narrow (CORBA::Exception *); // the alloc method. This is TAO extension static CORBA::Exception *_alloc (void); }; // exception PortableServer::POA::AdapterNonExistent - friend void operator<<= (CORBA::Any &, const AdapterNonExistent &); // copying version + friend void operator<<= (CORBA::Any &, const AdapterNonExistent &); // copying version friend void operator<<= (CORBA::Any &, AdapterNonExistent*); // noncopying version friend CORBA::Boolean operator>>= (const CORBA::Any &, AdapterNonExistent *&); -static CORBA::TypeCode_ptr _tc_AdapterNonExistent; + static CORBA::TypeCode_ptr _tc_AdapterNonExistent; #endif // end #if !defined @@ -1685,7 +1784,7 @@ static CORBA::TypeCode_ptr _tc_AdapterNonExistent; InvalidPolicy (const InvalidPolicy &); // copy ctor ~InvalidPolicy (void); // dtor InvalidPolicy( - CORBA::UShort _tao_index); + CORBA::UShort _tao_index); InvalidPolicy &operator= (const InvalidPolicy &); static InvalidPolicy *_narrow (CORBA::Exception *); @@ -1693,10 +1792,10 @@ static CORBA::TypeCode_ptr _tc_AdapterNonExistent; // the alloc method. This is TAO extension static CORBA::Exception *_alloc (void); }; // exception PortableServer::POA::InvalidPolicy - friend void operator<<= (CORBA::Any &, const InvalidPolicy &); // copying version + friend void operator<<= (CORBA::Any &, const InvalidPolicy &); // copying version friend void operator<<= (CORBA::Any &, InvalidPolicy*); // noncopying version friend CORBA::Boolean operator>>= (const CORBA::Any &, InvalidPolicy *&); -static CORBA::TypeCode_ptr _tc_InvalidPolicy; + static CORBA::TypeCode_ptr _tc_InvalidPolicy; #endif // end #if !defined @@ -1720,15 +1819,15 @@ static CORBA::TypeCode_ptr _tc_InvalidPolicy; NoServant (void); // default ctor NoServant (const NoServant &); // copy ctor ~NoServant (void); // dtor - NoServant &operator= (const NoServant &); + NoServant &operator= (const NoServant &); static NoServant *_narrow (CORBA::Exception *); // the alloc method. This is TAO extension static CORBA::Exception *_alloc (void); }; // exception PortableServer::POA::NoServant - friend void operator<<= (CORBA::Any &, const NoServant &); // copying version + friend void operator<<= (CORBA::Any &, const NoServant &); // copying version friend void operator<<= (CORBA::Any &, NoServant*); // noncopying version friend CORBA::Boolean operator>>= (const CORBA::Any &, NoServant *&); -static CORBA::TypeCode_ptr _tc_NoServant; + static CORBA::TypeCode_ptr _tc_NoServant; #endif // end #if !defined @@ -1752,15 +1851,15 @@ static CORBA::TypeCode_ptr _tc_NoServant; ObjectAlreadyActive (void); // default ctor ObjectAlreadyActive (const ObjectAlreadyActive &); // copy ctor ~ObjectAlreadyActive (void); // dtor - ObjectAlreadyActive &operator= (const ObjectAlreadyActive &); + ObjectAlreadyActive &operator= (const ObjectAlreadyActive &); static ObjectAlreadyActive *_narrow (CORBA::Exception *); // the alloc method. This is TAO extension static CORBA::Exception *_alloc (void); }; // exception PortableServer::POA::ObjectAlreadyActive - friend void operator<<= (CORBA::Any &, const ObjectAlreadyActive &); // copying version + friend void operator<<= (CORBA::Any &, const ObjectAlreadyActive &); // copying version friend void operator<<= (CORBA::Any &, ObjectAlreadyActive*); // noncopying version friend CORBA::Boolean operator>>= (const CORBA::Any &, ObjectAlreadyActive *&); -static CORBA::TypeCode_ptr _tc_ObjectAlreadyActive; + static CORBA::TypeCode_ptr _tc_ObjectAlreadyActive; #endif // end #if !defined @@ -1784,15 +1883,15 @@ static CORBA::TypeCode_ptr _tc_ObjectAlreadyActive; ObjectNotActive (void); // default ctor ObjectNotActive (const ObjectNotActive &); // copy ctor ~ObjectNotActive (void); // dtor - ObjectNotActive &operator= (const ObjectNotActive &); + ObjectNotActive &operator= (const ObjectNotActive &); static ObjectNotActive *_narrow (CORBA::Exception *); // the alloc method. This is TAO extension static CORBA::Exception *_alloc (void); }; // exception PortableServer::POA::ObjectNotActive - friend void operator<<= (CORBA::Any &, const ObjectNotActive &); // copying version + friend void operator<<= (CORBA::Any &, const ObjectNotActive &); // copying version friend void operator<<= (CORBA::Any &, ObjectNotActive*); // noncopying version friend CORBA::Boolean operator>>= (const CORBA::Any &, ObjectNotActive *&); -static CORBA::TypeCode_ptr _tc_ObjectNotActive; + static CORBA::TypeCode_ptr _tc_ObjectNotActive; #endif // end #if !defined @@ -1816,15 +1915,15 @@ static CORBA::TypeCode_ptr _tc_ObjectNotActive; ServantAlreadyActive (void); // default ctor ServantAlreadyActive (const ServantAlreadyActive &); // copy ctor ~ServantAlreadyActive (void); // dtor - ServantAlreadyActive &operator= (const ServantAlreadyActive &); + ServantAlreadyActive &operator= (const ServantAlreadyActive &); static ServantAlreadyActive *_narrow (CORBA::Exception *); // the alloc method. This is TAO extension static CORBA::Exception *_alloc (void); }; // exception PortableServer::POA::ServantAlreadyActive - friend void operator<<= (CORBA::Any &, const ServantAlreadyActive &); // copying version + friend void operator<<= (CORBA::Any &, const ServantAlreadyActive &); // copying version friend void operator<<= (CORBA::Any &, ServantAlreadyActive*); // noncopying version friend CORBA::Boolean operator>>= (const CORBA::Any &, ServantAlreadyActive *&); -static CORBA::TypeCode_ptr _tc_ServantAlreadyActive; + static CORBA::TypeCode_ptr _tc_ServantAlreadyActive; #endif // end #if !defined @@ -1848,15 +1947,15 @@ static CORBA::TypeCode_ptr _tc_ServantAlreadyActive; ServantNotActive (void); // default ctor ServantNotActive (const ServantNotActive &); // copy ctor ~ServantNotActive (void); // dtor - ServantNotActive &operator= (const ServantNotActive &); + ServantNotActive &operator= (const ServantNotActive &); static ServantNotActive *_narrow (CORBA::Exception *); // the alloc method. This is TAO extension static CORBA::Exception *_alloc (void); }; // exception PortableServer::POA::ServantNotActive - friend void operator<<= (CORBA::Any &, const ServantNotActive &); // copying version + friend void operator<<= (CORBA::Any &, const ServantNotActive &); // copying version friend void operator<<= (CORBA::Any &, ServantNotActive*); // noncopying version friend CORBA::Boolean operator>>= (const CORBA::Any &, ServantNotActive *&); -static CORBA::TypeCode_ptr _tc_ServantNotActive; + static CORBA::TypeCode_ptr _tc_ServantNotActive; #endif // end #if !defined @@ -1880,15 +1979,15 @@ static CORBA::TypeCode_ptr _tc_ServantNotActive; WrongAdapter (void); // default ctor WrongAdapter (const WrongAdapter &); // copy ctor ~WrongAdapter (void); // dtor - WrongAdapter &operator= (const WrongAdapter &); + WrongAdapter &operator= (const WrongAdapter &); static WrongAdapter *_narrow (CORBA::Exception *); // the alloc method. This is TAO extension static CORBA::Exception *_alloc (void); }; // exception PortableServer::POA::WrongAdapter - friend void operator<<= (CORBA::Any &, const WrongAdapter &); // copying version + friend void operator<<= (CORBA::Any &, const WrongAdapter &); // copying version friend void operator<<= (CORBA::Any &, WrongAdapter*); // noncopying version friend CORBA::Boolean operator>>= (const CORBA::Any &, WrongAdapter *&); -static CORBA::TypeCode_ptr _tc_WrongAdapter; + static CORBA::TypeCode_ptr _tc_WrongAdapter; #endif // end #if !defined @@ -1912,15 +2011,15 @@ static CORBA::TypeCode_ptr _tc_WrongAdapter; WrongPolicy (void); // default ctor WrongPolicy (const WrongPolicy &); // copy ctor ~WrongPolicy (void); // dtor - WrongPolicy &operator= (const WrongPolicy &); + WrongPolicy &operator= (const WrongPolicy &); static WrongPolicy *_narrow (CORBA::Exception *); // the alloc method. This is TAO extension static CORBA::Exception *_alloc (void); }; // exception PortableServer::POA::WrongPolicy - friend void operator<<= (CORBA::Any &, const WrongPolicy &); // copying version + friend void operator<<= (CORBA::Any &, const WrongPolicy &); // copying version friend void operator<<= (CORBA::Any &, WrongPolicy*); // noncopying version friend CORBA::Boolean operator>>= (const CORBA::Any &, WrongPolicy *&); -static CORBA::TypeCode_ptr _tc_WrongPolicy; + static CORBA::TypeCode_ptr _tc_WrongPolicy; #endif // end #if !defined @@ -1935,6 +2034,15 @@ static CORBA::TypeCode_ptr _tc_WrongPolicy; virtual ImplicitActivationPolicy_ptr create_implicit_activation_policy (ImplicitActivationPolicyValue value, CORBA::Environment &env) = 0; virtual ServantRetentionPolicy_ptr create_servant_retention_policy (ServantRetentionPolicyValue value, CORBA::Environment &env) = 0; virtual RequestProcessingPolicy_ptr create_request_processing_policy (RequestProcessingPolicyValue value, CORBA::Environment &env) = 0; + + // ************************************************** + // + // TAO spcific POA locking policy (non-standard) + // + // ************************************************** + + virtual TAO_POA_LockingPolicy_ptr create_TAO_POA_locking_policy (TAO_POA_LockingPolicyValue value, CORBA::Environment &env) = 0; + virtual char * the_name (CORBA::Environment &env) = 0; virtual POA_ptr the_parent (CORBA::Environment &env) = 0; virtual POAManager_ptr the_POAManager (CORBA::Environment &env) = 0; @@ -1958,10 +2066,10 @@ static CORBA::TypeCode_ptr _tc_WrongPolicy; virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); protected: POA ( - STUB_Object *objref = 0, - TAO_ServantBase *servant = 0, - CORBA::Boolean collocated = CORBA::B_FALSE - ); + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); public: virtual ~POA (void); private: @@ -1978,7 +2086,7 @@ static CORBA::TypeCode_ptr _tc_WrongPolicy; #if !defined (_PORTABLESERVER_CURRENT___PTR_CH_) #define _PORTABLESERVER_CURRENT___PTR_CH_ -class Current; + class Current; typedef Current *Current_ptr; #endif // end #if !defined @@ -2050,7 +2158,6 @@ class Current; static Current_ptr _duplicate (Current_ptr obj); static Current_ptr _narrow (CORBA::Object_ptr obj, CORBA::Environment &env); static Current_ptr _nil (void); - static Current_ptr _bind (const char *host, CORBA::UShort port, const char *key, CORBA::Environment &env); #if !defined (_PORTABLESERVER_CURRENT_NOCONTEXT___PTR_CH_) @@ -2071,15 +2178,15 @@ class Current; NoContext (void); // default ctor NoContext (const NoContext &); // copy ctor ~NoContext (void); // dtor - NoContext &operator= (const NoContext &); + NoContext &operator= (const NoContext &); static NoContext *_narrow (CORBA::Exception *); // the alloc method. This is TAO extension static CORBA::Exception *_alloc (void); }; // exception PortableServer::Current::NoContext - friend void operator<<= (CORBA::Any &, const NoContext &); // copying version + friend void operator<<= (CORBA::Any &, const NoContext &); // copying version friend void operator<<= (CORBA::Any &, NoContext*); // noncopying version friend CORBA::Boolean operator>>= (const CORBA::Any &, NoContext *&); -static CORBA::TypeCode_ptr _tc_NoContext; + static CORBA::TypeCode_ptr _tc_NoContext; #endif // end #if !defined @@ -2089,10 +2196,10 @@ static CORBA::TypeCode_ptr _tc_NoContext; virtual CORBA::Boolean _is_a (const CORBA::Char *type_id, CORBA::Environment &env); protected: Current ( - STUB_Object *objref = 0, - TAO_ServantBase *servant = 0, - CORBA::Boolean collocated = CORBA::B_FALSE - ); + STUB_Object *objref = 0, + TAO_ServantBase *servant = 0, + CORBA::Boolean collocated = CORBA::B_FALSE + ); public: virtual ~Current (void); private: diff --git a/TAO/tao/POAC.i b/TAO/tao/POAC.i index 46487e15e45..ee2c7f2a583 100644 --- a/TAO/tao/POAC.i +++ b/TAO/tao/POAC.i @@ -23,12 +23,12 @@ PortableServer::POA::_nil (void) ACE_INLINE PortableServer::POA_var::POA_var (void) // default constructor - : ptr_ (PortableServer::POA::_nil ()) + : ptr_ (PortableServer::POA::_nil ()) {} ACE_INLINE PortableServer::POA_var::POA_var (PortableServer::POA_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::POA_ptr @@ -39,7 +39,7 @@ PortableServer::POA_var::ptr (void) const ACE_INLINE PortableServer::POA_var::POA_var (const PortableServer::POA_var &p) // copy constructor - : ptr_ (PortableServer::POA::_duplicate (p.ptr ())) + : ptr_ (PortableServer::POA::_duplicate (p.ptr ())) {} ACE_INLINE @@ -60,10 +60,10 @@ ACE_INLINE PortableServer::POA_var & PortableServer::POA_var::operator= (const PortableServer::POA_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::POA::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::POA::_duplicate (p.ptr ()); + } return *this; } @@ -127,14 +127,14 @@ PortableServer::POA_var::_retn (void) ACE_INLINE PortableServer::POA_out::POA_out (PortableServer::POA_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::POA::_nil (); } ACE_INLINE PortableServer::POA_out::POA_out (PortableServer::POA_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::POA::_nil (); @@ -142,7 +142,7 @@ PortableServer::POA_out::POA_out (PortableServer::POA_var &p) // constructor fro ACE_INLINE PortableServer::POA_out::POA_out (PortableServer::POA_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::POA_out & @@ -197,21 +197,21 @@ PortableServer::POA_out::operator-> (void) ACE_INLINE PortableServer::_tao_seq_Octet_var::_tao_seq_Octet_var (void) // default constructor - : ptr_ (0) + : ptr_ (0) {} ACE_INLINE PortableServer::_tao_seq_Octet_var::_tao_seq_Octet_var (PortableServer::_tao_seq_Octet *p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::_tao_seq_Octet_var::_tao_seq_Octet_var (const PortableServer::_tao_seq_Octet_var &p) // copy constructor { if (p.ptr_) - this->ptr_ = new PortableServer::_tao_seq_Octet(*p.ptr_); + this->ptr_ = new PortableServer::_tao_seq_Octet(*p.ptr_); else - this->ptr_ = 0; + this->ptr_ = 0; } ACE_INLINE @@ -232,10 +232,10 @@ ACE_INLINE PortableServer::_tao_seq_Octet_var & PortableServer::_tao_seq_Octet_var::operator= (const PortableServer::_tao_seq_Octet_var &p) // deep copy { if (this != &p) - { - delete this->ptr_; - this->ptr_ = new PortableServer::_tao_seq_Octet (*p.ptr_); - } + { + delete this->ptr_; + this->ptr_ = new PortableServer::_tao_seq_Octet (*p.ptr_); + } return *this; } @@ -323,14 +323,14 @@ PortableServer::_tao_seq_Octet_var::ptr (void) const ACE_INLINE PortableServer::_tao_seq_Octet_out::_tao_seq_Octet_out (PortableServer::_tao_seq_Octet *&p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = 0; } ACE_INLINE PortableServer::_tao_seq_Octet_out::_tao_seq_Octet_out (PortableServer::_tao_seq_Octet_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { delete this->ptr_; this->ptr_ = 0; @@ -338,7 +338,7 @@ PortableServer::_tao_seq_Octet_out::_tao_seq_Octet_out (PortableServer::_tao_seq ACE_INLINE PortableServer::_tao_seq_Octet_out::_tao_seq_Octet_out (PortableServer::_tao_seq_Octet_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::_tao_seq_Octet_out & @@ -384,11 +384,11 @@ PortableServer::_tao_seq_Octet_out::operator[] (CORBA::ULong index) ACE_INLINE PortableServer::ThreadPolicy::ThreadPolicy( - STUB_Object *objref, - TAO_ServantBase *servant, - CORBA::Boolean collocated - ) - : ACE_CORBA_1 (Object) (objref, servant, collocated) + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) {} ACE_INLINE @@ -411,12 +411,12 @@ PortableServer::ThreadPolicy::_nil (void) ACE_INLINE PortableServer::ThreadPolicy_var::ThreadPolicy_var (void) // default constructor - : ptr_ (PortableServer::ThreadPolicy::_nil ()) + : ptr_ (PortableServer::ThreadPolicy::_nil ()) {} ACE_INLINE PortableServer::ThreadPolicy_var::ThreadPolicy_var (PortableServer::ThreadPolicy_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::ThreadPolicy_ptr @@ -427,7 +427,7 @@ PortableServer::ThreadPolicy_var::ptr (void) const ACE_INLINE PortableServer::ThreadPolicy_var::ThreadPolicy_var (const PortableServer::ThreadPolicy_var &p) // copy constructor - : ptr_ (PortableServer::ThreadPolicy::_duplicate (p.ptr ())) + : ptr_ (PortableServer::ThreadPolicy::_duplicate (p.ptr ())) {} ACE_INLINE @@ -448,10 +448,10 @@ ACE_INLINE PortableServer::ThreadPolicy_var & PortableServer::ThreadPolicy_var::operator= (const PortableServer::ThreadPolicy_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::ThreadPolicy::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::ThreadPolicy::_duplicate (p.ptr ()); + } return *this; } @@ -515,14 +515,14 @@ PortableServer::ThreadPolicy_var::_retn (void) ACE_INLINE PortableServer::ThreadPolicy_out::ThreadPolicy_out (PortableServer::ThreadPolicy_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::ThreadPolicy::_nil (); } ACE_INLINE PortableServer::ThreadPolicy_out::ThreadPolicy_out (PortableServer::ThreadPolicy_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::ThreadPolicy::_nil (); @@ -530,7 +530,7 @@ PortableServer::ThreadPolicy_out::ThreadPolicy_out (PortableServer::ThreadPolicy ACE_INLINE PortableServer::ThreadPolicy_out::ThreadPolicy_out (PortableServer::ThreadPolicy_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::ThreadPolicy_out & @@ -577,11 +577,11 @@ PortableServer::ThreadPolicy_out::operator-> (void) ACE_INLINE PortableServer::LifespanPolicy::LifespanPolicy( - STUB_Object *objref, - TAO_ServantBase *servant, - CORBA::Boolean collocated - ) - : ACE_CORBA_1 (Object) (objref, servant, collocated) + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) {} ACE_INLINE @@ -604,12 +604,12 @@ PortableServer::LifespanPolicy::_nil (void) ACE_INLINE PortableServer::LifespanPolicy_var::LifespanPolicy_var (void) // default constructor - : ptr_ (PortableServer::LifespanPolicy::_nil ()) + : ptr_ (PortableServer::LifespanPolicy::_nil ()) {} ACE_INLINE PortableServer::LifespanPolicy_var::LifespanPolicy_var (PortableServer::LifespanPolicy_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::LifespanPolicy_ptr @@ -620,7 +620,7 @@ PortableServer::LifespanPolicy_var::ptr (void) const ACE_INLINE PortableServer::LifespanPolicy_var::LifespanPolicy_var (const PortableServer::LifespanPolicy_var &p) // copy constructor - : ptr_ (PortableServer::LifespanPolicy::_duplicate (p.ptr ())) + : ptr_ (PortableServer::LifespanPolicy::_duplicate (p.ptr ())) {} ACE_INLINE @@ -641,10 +641,10 @@ ACE_INLINE PortableServer::LifespanPolicy_var & PortableServer::LifespanPolicy_var::operator= (const PortableServer::LifespanPolicy_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::LifespanPolicy::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::LifespanPolicy::_duplicate (p.ptr ()); + } return *this; } @@ -708,14 +708,14 @@ PortableServer::LifespanPolicy_var::_retn (void) ACE_INLINE PortableServer::LifespanPolicy_out::LifespanPolicy_out (PortableServer::LifespanPolicy_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::LifespanPolicy::_nil (); } ACE_INLINE PortableServer::LifespanPolicy_out::LifespanPolicy_out (PortableServer::LifespanPolicy_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::LifespanPolicy::_nil (); @@ -723,7 +723,7 @@ PortableServer::LifespanPolicy_out::LifespanPolicy_out (PortableServer::Lifespan ACE_INLINE PortableServer::LifespanPolicy_out::LifespanPolicy_out (PortableServer::LifespanPolicy_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::LifespanPolicy_out & @@ -770,11 +770,11 @@ PortableServer::LifespanPolicy_out::operator-> (void) ACE_INLINE PortableServer::IdUniquenessPolicy::IdUniquenessPolicy( - STUB_Object *objref, - TAO_ServantBase *servant, - CORBA::Boolean collocated - ) - : ACE_CORBA_1 (Object) (objref, servant, collocated) + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) {} ACE_INLINE @@ -797,12 +797,12 @@ PortableServer::IdUniquenessPolicy::_nil (void) ACE_INLINE PortableServer::IdUniquenessPolicy_var::IdUniquenessPolicy_var (void) // default constructor - : ptr_ (PortableServer::IdUniquenessPolicy::_nil ()) + : ptr_ (PortableServer::IdUniquenessPolicy::_nil ()) {} ACE_INLINE PortableServer::IdUniquenessPolicy_var::IdUniquenessPolicy_var (PortableServer::IdUniquenessPolicy_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::IdUniquenessPolicy_ptr @@ -813,7 +813,7 @@ PortableServer::IdUniquenessPolicy_var::ptr (void) const ACE_INLINE PortableServer::IdUniquenessPolicy_var::IdUniquenessPolicy_var (const PortableServer::IdUniquenessPolicy_var &p) // copy constructor - : ptr_ (PortableServer::IdUniquenessPolicy::_duplicate (p.ptr ())) + : ptr_ (PortableServer::IdUniquenessPolicy::_duplicate (p.ptr ())) {} ACE_INLINE @@ -834,10 +834,10 @@ ACE_INLINE PortableServer::IdUniquenessPolicy_var & PortableServer::IdUniquenessPolicy_var::operator= (const PortableServer::IdUniquenessPolicy_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::IdUniquenessPolicy::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::IdUniquenessPolicy::_duplicate (p.ptr ()); + } return *this; } @@ -901,14 +901,14 @@ PortableServer::IdUniquenessPolicy_var::_retn (void) ACE_INLINE PortableServer::IdUniquenessPolicy_out::IdUniquenessPolicy_out (PortableServer::IdUniquenessPolicy_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::IdUniquenessPolicy::_nil (); } ACE_INLINE PortableServer::IdUniquenessPolicy_out::IdUniquenessPolicy_out (PortableServer::IdUniquenessPolicy_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::IdUniquenessPolicy::_nil (); @@ -916,7 +916,7 @@ PortableServer::IdUniquenessPolicy_out::IdUniquenessPolicy_out (PortableServer:: ACE_INLINE PortableServer::IdUniquenessPolicy_out::IdUniquenessPolicy_out (PortableServer::IdUniquenessPolicy_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::IdUniquenessPolicy_out & @@ -963,11 +963,11 @@ PortableServer::IdUniquenessPolicy_out::operator-> (void) ACE_INLINE PortableServer::IdAssignmentPolicy::IdAssignmentPolicy( - STUB_Object *objref, - TAO_ServantBase *servant, - CORBA::Boolean collocated - ) - : ACE_CORBA_1 (Object) (objref, servant, collocated) + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) {} ACE_INLINE @@ -990,12 +990,12 @@ PortableServer::IdAssignmentPolicy::_nil (void) ACE_INLINE PortableServer::IdAssignmentPolicy_var::IdAssignmentPolicy_var (void) // default constructor - : ptr_ (PortableServer::IdAssignmentPolicy::_nil ()) + : ptr_ (PortableServer::IdAssignmentPolicy::_nil ()) {} ACE_INLINE PortableServer::IdAssignmentPolicy_var::IdAssignmentPolicy_var (PortableServer::IdAssignmentPolicy_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::IdAssignmentPolicy_ptr @@ -1006,7 +1006,7 @@ PortableServer::IdAssignmentPolicy_var::ptr (void) const ACE_INLINE PortableServer::IdAssignmentPolicy_var::IdAssignmentPolicy_var (const PortableServer::IdAssignmentPolicy_var &p) // copy constructor - : ptr_ (PortableServer::IdAssignmentPolicy::_duplicate (p.ptr ())) + : ptr_ (PortableServer::IdAssignmentPolicy::_duplicate (p.ptr ())) {} ACE_INLINE @@ -1027,10 +1027,10 @@ ACE_INLINE PortableServer::IdAssignmentPolicy_var & PortableServer::IdAssignmentPolicy_var::operator= (const PortableServer::IdAssignmentPolicy_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::IdAssignmentPolicy::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::IdAssignmentPolicy::_duplicate (p.ptr ()); + } return *this; } @@ -1094,14 +1094,14 @@ PortableServer::IdAssignmentPolicy_var::_retn (void) ACE_INLINE PortableServer::IdAssignmentPolicy_out::IdAssignmentPolicy_out (PortableServer::IdAssignmentPolicy_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::IdAssignmentPolicy::_nil (); } ACE_INLINE PortableServer::IdAssignmentPolicy_out::IdAssignmentPolicy_out (PortableServer::IdAssignmentPolicy_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::IdAssignmentPolicy::_nil (); @@ -1109,7 +1109,7 @@ PortableServer::IdAssignmentPolicy_out::IdAssignmentPolicy_out (PortableServer:: ACE_INLINE PortableServer::IdAssignmentPolicy_out::IdAssignmentPolicy_out (PortableServer::IdAssignmentPolicy_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::IdAssignmentPolicy_out & @@ -1156,11 +1156,11 @@ PortableServer::IdAssignmentPolicy_out::operator-> (void) ACE_INLINE PortableServer::ImplicitActivationPolicy::ImplicitActivationPolicy( - STUB_Object *objref, - TAO_ServantBase *servant, - CORBA::Boolean collocated - ) - : ACE_CORBA_1 (Object) (objref, servant, collocated) + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) {} ACE_INLINE @@ -1183,12 +1183,12 @@ PortableServer::ImplicitActivationPolicy::_nil (void) ACE_INLINE PortableServer::ImplicitActivationPolicy_var::ImplicitActivationPolicy_var (void) // default constructor - : ptr_ (PortableServer::ImplicitActivationPolicy::_nil ()) + : ptr_ (PortableServer::ImplicitActivationPolicy::_nil ()) {} ACE_INLINE PortableServer::ImplicitActivationPolicy_var::ImplicitActivationPolicy_var (PortableServer::ImplicitActivationPolicy_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::ImplicitActivationPolicy_ptr @@ -1199,7 +1199,7 @@ PortableServer::ImplicitActivationPolicy_var::ptr (void) const ACE_INLINE PortableServer::ImplicitActivationPolicy_var::ImplicitActivationPolicy_var (const PortableServer::ImplicitActivationPolicy_var &p) // copy constructor - : ptr_ (PortableServer::ImplicitActivationPolicy::_duplicate (p.ptr ())) + : ptr_ (PortableServer::ImplicitActivationPolicy::_duplicate (p.ptr ())) {} ACE_INLINE @@ -1220,10 +1220,10 @@ ACE_INLINE PortableServer::ImplicitActivationPolicy_var & PortableServer::ImplicitActivationPolicy_var::operator= (const PortableServer::ImplicitActivationPolicy_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::ImplicitActivationPolicy::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::ImplicitActivationPolicy::_duplicate (p.ptr ()); + } return *this; } @@ -1287,14 +1287,14 @@ PortableServer::ImplicitActivationPolicy_var::_retn (void) ACE_INLINE PortableServer::ImplicitActivationPolicy_out::ImplicitActivationPolicy_out (PortableServer::ImplicitActivationPolicy_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::ImplicitActivationPolicy::_nil (); } ACE_INLINE PortableServer::ImplicitActivationPolicy_out::ImplicitActivationPolicy_out (PortableServer::ImplicitActivationPolicy_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::ImplicitActivationPolicy::_nil (); @@ -1302,7 +1302,7 @@ PortableServer::ImplicitActivationPolicy_out::ImplicitActivationPolicy_out (Port ACE_INLINE PortableServer::ImplicitActivationPolicy_out::ImplicitActivationPolicy_out (PortableServer::ImplicitActivationPolicy_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::ImplicitActivationPolicy_out & @@ -1349,11 +1349,11 @@ PortableServer::ImplicitActivationPolicy_out::operator-> (void) ACE_INLINE PortableServer::ServantRetentionPolicy::ServantRetentionPolicy( - STUB_Object *objref, - TAO_ServantBase *servant, - CORBA::Boolean collocated - ) - : ACE_CORBA_1 (Object) (objref, servant, collocated) + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) {} ACE_INLINE @@ -1376,12 +1376,12 @@ PortableServer::ServantRetentionPolicy::_nil (void) ACE_INLINE PortableServer::ServantRetentionPolicy_var::ServantRetentionPolicy_var (void) // default constructor - : ptr_ (PortableServer::ServantRetentionPolicy::_nil ()) + : ptr_ (PortableServer::ServantRetentionPolicy::_nil ()) {} ACE_INLINE PortableServer::ServantRetentionPolicy_var::ServantRetentionPolicy_var (PortableServer::ServantRetentionPolicy_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::ServantRetentionPolicy_ptr @@ -1392,7 +1392,7 @@ PortableServer::ServantRetentionPolicy_var::ptr (void) const ACE_INLINE PortableServer::ServantRetentionPolicy_var::ServantRetentionPolicy_var (const PortableServer::ServantRetentionPolicy_var &p) // copy constructor - : ptr_ (PortableServer::ServantRetentionPolicy::_duplicate (p.ptr ())) + : ptr_ (PortableServer::ServantRetentionPolicy::_duplicate (p.ptr ())) {} ACE_INLINE @@ -1413,10 +1413,10 @@ ACE_INLINE PortableServer::ServantRetentionPolicy_var & PortableServer::ServantRetentionPolicy_var::operator= (const PortableServer::ServantRetentionPolicy_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::ServantRetentionPolicy::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::ServantRetentionPolicy::_duplicate (p.ptr ()); + } return *this; } @@ -1480,14 +1480,14 @@ PortableServer::ServantRetentionPolicy_var::_retn (void) ACE_INLINE PortableServer::ServantRetentionPolicy_out::ServantRetentionPolicy_out (PortableServer::ServantRetentionPolicy_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::ServantRetentionPolicy::_nil (); } ACE_INLINE PortableServer::ServantRetentionPolicy_out::ServantRetentionPolicy_out (PortableServer::ServantRetentionPolicy_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::ServantRetentionPolicy::_nil (); @@ -1495,7 +1495,7 @@ PortableServer::ServantRetentionPolicy_out::ServantRetentionPolicy_out (Portable ACE_INLINE PortableServer::ServantRetentionPolicy_out::ServantRetentionPolicy_out (PortableServer::ServantRetentionPolicy_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::ServantRetentionPolicy_out & @@ -1542,11 +1542,11 @@ PortableServer::ServantRetentionPolicy_out::operator-> (void) ACE_INLINE PortableServer::RequestProcessingPolicy::RequestProcessingPolicy( - STUB_Object *objref, - TAO_ServantBase *servant, - CORBA::Boolean collocated - ) - : ACE_CORBA_1 (Object) (objref, servant, collocated) + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) {} ACE_INLINE @@ -1569,12 +1569,12 @@ PortableServer::RequestProcessingPolicy::_nil (void) ACE_INLINE PortableServer::RequestProcessingPolicy_var::RequestProcessingPolicy_var (void) // default constructor - : ptr_ (PortableServer::RequestProcessingPolicy::_nil ()) + : ptr_ (PortableServer::RequestProcessingPolicy::_nil ()) {} ACE_INLINE PortableServer::RequestProcessingPolicy_var::RequestProcessingPolicy_var (PortableServer::RequestProcessingPolicy_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::RequestProcessingPolicy_ptr @@ -1585,7 +1585,7 @@ PortableServer::RequestProcessingPolicy_var::ptr (void) const ACE_INLINE PortableServer::RequestProcessingPolicy_var::RequestProcessingPolicy_var (const PortableServer::RequestProcessingPolicy_var &p) // copy constructor - : ptr_ (PortableServer::RequestProcessingPolicy::_duplicate (p.ptr ())) + : ptr_ (PortableServer::RequestProcessingPolicy::_duplicate (p.ptr ())) {} ACE_INLINE @@ -1606,10 +1606,10 @@ ACE_INLINE PortableServer::RequestProcessingPolicy_var & PortableServer::RequestProcessingPolicy_var::operator= (const PortableServer::RequestProcessingPolicy_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::RequestProcessingPolicy::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::RequestProcessingPolicy::_duplicate (p.ptr ()); + } return *this; } @@ -1673,14 +1673,14 @@ PortableServer::RequestProcessingPolicy_var::_retn (void) ACE_INLINE PortableServer::RequestProcessingPolicy_out::RequestProcessingPolicy_out (PortableServer::RequestProcessingPolicy_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::RequestProcessingPolicy::_nil (); } ACE_INLINE PortableServer::RequestProcessingPolicy_out::RequestProcessingPolicy_out (PortableServer::RequestProcessingPolicy_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::RequestProcessingPolicy::_nil (); @@ -1688,7 +1688,7 @@ PortableServer::RequestProcessingPolicy_out::RequestProcessingPolicy_out (Portab ACE_INLINE PortableServer::RequestProcessingPolicy_out::RequestProcessingPolicy_out (PortableServer::RequestProcessingPolicy_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::RequestProcessingPolicy_out & @@ -1733,13 +1733,212 @@ PortableServer::RequestProcessingPolicy_out::operator-> (void) #endif // end #if !defined +// ************************************************** +// +// TAO spcific POA locking policy (non-standard) +// +// ************************************************** + +ACE_INLINE +PortableServer::TAO_POA_LockingPolicy::TAO_POA_LockingPolicy( + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) +{} + +ACE_INLINE +PortableServer::TAO_POA_LockingPolicy::~TAO_POA_LockingPolicy (void) // destructor +{} + +ACE_INLINE PortableServer::TAO_POA_LockingPolicy_ptr +PortableServer::TAO_POA_LockingPolicy::_nil (void) +{ + return (PortableServer::TAO_POA_LockingPolicy_ptr)0; +} + + +#if !defined (_PORTABLESERVER_TAO_POA_LockingPOLICY___VAR_CI_) +#define _PORTABLESERVER_TAO_POA_LockingPOLICY___VAR_CI_ + +// ************************************************************* +// Inline operations for class PortableServer::TAO_POA_LockingPolicy_var +// ************************************************************* + +ACE_INLINE +PortableServer::TAO_POA_LockingPolicy_var::TAO_POA_LockingPolicy_var (void) // default constructor + : ptr_ (PortableServer::TAO_POA_LockingPolicy::_nil ()) +{} + +ACE_INLINE +PortableServer::TAO_POA_LockingPolicy_var::TAO_POA_LockingPolicy_var (PortableServer::TAO_POA_LockingPolicy_ptr p) + : ptr_ (p) +{} + +ACE_INLINE PortableServer::TAO_POA_LockingPolicy_ptr +PortableServer::TAO_POA_LockingPolicy_var::ptr (void) const +{ + return this->ptr_; +} + +ACE_INLINE +PortableServer::TAO_POA_LockingPolicy_var::TAO_POA_LockingPolicy_var (const PortableServer::TAO_POA_LockingPolicy_var &p) // copy constructor + : ptr_ (PortableServer::TAO_POA_LockingPolicy::_duplicate (p.ptr ())) +{} + +ACE_INLINE +PortableServer::TAO_POA_LockingPolicy_var::~TAO_POA_LockingPolicy_var (void) // destructor +{ + CORBA::release (this->ptr_); +} + +ACE_INLINE PortableServer::TAO_POA_LockingPolicy_var & +PortableServer::TAO_POA_LockingPolicy_var::operator= (PortableServer::TAO_POA_LockingPolicy_ptr p) +{ + CORBA::release (this->ptr_); + this->ptr_ = p; + return *this; +} + +ACE_INLINE PortableServer::TAO_POA_LockingPolicy_var & +PortableServer::TAO_POA_LockingPolicy_var::operator= (const PortableServer::TAO_POA_LockingPolicy_var &p) +{ + if (this != &p) + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::TAO_POA_LockingPolicy::_duplicate (p.ptr ()); + } + return *this; +} + +ACE_INLINE +PortableServer::TAO_POA_LockingPolicy_var::operator const PortableServer::TAO_POA_LockingPolicy_ptr &() const // cast +{ + return this->ptr_; +} + +ACE_INLINE +PortableServer::TAO_POA_LockingPolicy_var::operator PortableServer::TAO_POA_LockingPolicy_ptr &() // cast +{ + return this->ptr_; +} + +ACE_INLINE PortableServer::TAO_POA_LockingPolicy_ptr +PortableServer::TAO_POA_LockingPolicy_var::operator-> (void) const +{ + return this->ptr_; +} + +ACE_INLINE PortableServer::TAO_POA_LockingPolicy_ptr +PortableServer::TAO_POA_LockingPolicy_var::in (void) const +{ + return this->ptr_; +} + +ACE_INLINE PortableServer::TAO_POA_LockingPolicy_ptr & +PortableServer::TAO_POA_LockingPolicy_var::inout (void) +{ + return this->ptr_; +} + +ACE_INLINE PortableServer::TAO_POA_LockingPolicy_ptr & +PortableServer::TAO_POA_LockingPolicy_var::out (void) +{ + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::TAO_POA_LockingPolicy::_nil (); + return this->ptr_; +} + +ACE_INLINE PortableServer::TAO_POA_LockingPolicy_ptr +PortableServer::TAO_POA_LockingPolicy_var::_retn (void) +{ + // yield ownership of managed obj reference + PortableServer::TAO_POA_LockingPolicy_ptr val = this->ptr_; + this->ptr_ = PortableServer::TAO_POA_LockingPolicy::_nil (); + return val; +} + + +#endif // end #if !defined + + +#if !defined (_PORTABLESERVER_TAO_POA_LockingPOLICY___OUT_CI_) +#define _PORTABLESERVER_TAO_POA_LockingPOLICY___OUT_CI_ + +// ************************************************************* +// Inline operations for class PortableServer::TAO_POA_LockingPolicy_out +// ************************************************************* + +ACE_INLINE +PortableServer::TAO_POA_LockingPolicy_out::TAO_POA_LockingPolicy_out (PortableServer::TAO_POA_LockingPolicy_ptr &p) + : ptr_ (p) +{ + this->ptr_ = PortableServer::TAO_POA_LockingPolicy::_nil (); +} + +ACE_INLINE +PortableServer::TAO_POA_LockingPolicy_out::TAO_POA_LockingPolicy_out (PortableServer::TAO_POA_LockingPolicy_var &p) // constructor from _var + : ptr_ (p.out ()) +{ + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::TAO_POA_LockingPolicy::_nil (); +} + +ACE_INLINE +PortableServer::TAO_POA_LockingPolicy_out::TAO_POA_LockingPolicy_out (PortableServer::TAO_POA_LockingPolicy_out &p) // copy constructor + : ptr_ (p.ptr_) +{} + +ACE_INLINE PortableServer::TAO_POA_LockingPolicy_out & +PortableServer::TAO_POA_LockingPolicy_out::operator= (PortableServer::TAO_POA_LockingPolicy_out &p) +{ + this->ptr_ = p.ptr_; + return *this; +} + +ACE_INLINE PortableServer::TAO_POA_LockingPolicy_out & +PortableServer::TAO_POA_LockingPolicy_out::operator= (const PortableServer::TAO_POA_LockingPolicy_var &p) +{ + this->ptr_ = PortableServer::TAO_POA_LockingPolicy::_duplicate (p.ptr ()); + return *this; +} + +ACE_INLINE PortableServer::TAO_POA_LockingPolicy_out & +PortableServer::TAO_POA_LockingPolicy_out::operator= (PortableServer::TAO_POA_LockingPolicy_ptr p) +{ + this->ptr_ = p; + return *this; +} + +ACE_INLINE +PortableServer::TAO_POA_LockingPolicy_out::operator PortableServer::TAO_POA_LockingPolicy_ptr &() // cast +{ + return this->ptr_; +} + +ACE_INLINE PortableServer::TAO_POA_LockingPolicy_ptr & +PortableServer::TAO_POA_LockingPolicy_out::ptr (void) // ptr +{ + return this->ptr_; +} + +ACE_INLINE PortableServer::TAO_POA_LockingPolicy_ptr +PortableServer::TAO_POA_LockingPolicy_out::operator-> (void) +{ + return this->ptr_; +} + + +#endif // end #if !defined + ACE_INLINE PortableServer::POAManager::POAManager( - STUB_Object *objref, - TAO_ServantBase *servant, - CORBA::Boolean collocated - ) - : ACE_CORBA_1 (Object) (objref, servant, collocated) + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) {} ACE_INLINE @@ -1762,12 +1961,12 @@ PortableServer::POAManager::_nil (void) ACE_INLINE PortableServer::POAManager_var::POAManager_var (void) // default constructor - : ptr_ (PortableServer::POAManager::_nil ()) + : ptr_ (PortableServer::POAManager::_nil ()) {} ACE_INLINE PortableServer::POAManager_var::POAManager_var (PortableServer::POAManager_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::POAManager_ptr @@ -1778,7 +1977,7 @@ PortableServer::POAManager_var::ptr (void) const ACE_INLINE PortableServer::POAManager_var::POAManager_var (const PortableServer::POAManager_var &p) // copy constructor - : ptr_ (PortableServer::POAManager::_duplicate (p.ptr ())) + : ptr_ (PortableServer::POAManager::_duplicate (p.ptr ())) {} ACE_INLINE @@ -1799,10 +1998,10 @@ ACE_INLINE PortableServer::POAManager_var & PortableServer::POAManager_var::operator= (const PortableServer::POAManager_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::POAManager::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::POAManager::_duplicate (p.ptr ()); + } return *this; } @@ -1866,14 +2065,14 @@ PortableServer::POAManager_var::_retn (void) ACE_INLINE PortableServer::POAManager_out::POAManager_out (PortableServer::POAManager_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::POAManager::_nil (); } ACE_INLINE PortableServer::POAManager_out::POAManager_out (PortableServer::POAManager_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::POAManager::_nil (); @@ -1881,7 +2080,7 @@ PortableServer::POAManager_out::POAManager_out (PortableServer::POAManager_var & ACE_INLINE PortableServer::POAManager_out::POAManager_out (PortableServer::POAManager_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::POAManager_out & @@ -1928,11 +2127,11 @@ PortableServer::POAManager_out::operator-> (void) ACE_INLINE PortableServer::AdapterActivator::AdapterActivator( - STUB_Object *objref, - TAO_ServantBase *servant, - CORBA::Boolean collocated - ) - : ACE_CORBA_1 (Object) (objref, servant, collocated) + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) {} ACE_INLINE @@ -1955,12 +2154,12 @@ PortableServer::AdapterActivator::_nil (void) ACE_INLINE PortableServer::AdapterActivator_var::AdapterActivator_var (void) // default constructor - : ptr_ (PortableServer::AdapterActivator::_nil ()) + : ptr_ (PortableServer::AdapterActivator::_nil ()) {} ACE_INLINE PortableServer::AdapterActivator_var::AdapterActivator_var (PortableServer::AdapterActivator_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::AdapterActivator_ptr @@ -1971,7 +2170,7 @@ PortableServer::AdapterActivator_var::ptr (void) const ACE_INLINE PortableServer::AdapterActivator_var::AdapterActivator_var (const PortableServer::AdapterActivator_var &p) // copy constructor - : ptr_ (PortableServer::AdapterActivator::_duplicate (p.ptr ())) + : ptr_ (PortableServer::AdapterActivator::_duplicate (p.ptr ())) {} ACE_INLINE @@ -1992,10 +2191,10 @@ ACE_INLINE PortableServer::AdapterActivator_var & PortableServer::AdapterActivator_var::operator= (const PortableServer::AdapterActivator_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::AdapterActivator::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::AdapterActivator::_duplicate (p.ptr ()); + } return *this; } @@ -2059,14 +2258,14 @@ PortableServer::AdapterActivator_var::_retn (void) ACE_INLINE PortableServer::AdapterActivator_out::AdapterActivator_out (PortableServer::AdapterActivator_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::AdapterActivator::_nil (); } ACE_INLINE PortableServer::AdapterActivator_out::AdapterActivator_out (PortableServer::AdapterActivator_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::AdapterActivator::_nil (); @@ -2074,7 +2273,7 @@ PortableServer::AdapterActivator_out::AdapterActivator_out (PortableServer::Adap ACE_INLINE PortableServer::AdapterActivator_out::AdapterActivator_out (PortableServer::AdapterActivator_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::AdapterActivator_out & @@ -2121,11 +2320,11 @@ PortableServer::AdapterActivator_out::operator-> (void) ACE_INLINE PortableServer::ServantManager::ServantManager( - STUB_Object *objref, - TAO_ServantBase *servant, - CORBA::Boolean collocated - ) - : ACE_CORBA_1 (Object) (objref, servant, collocated) + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) {} ACE_INLINE @@ -2148,12 +2347,12 @@ PortableServer::ServantManager::_nil (void) ACE_INLINE PortableServer::ServantManager_var::ServantManager_var (void) // default constructor - : ptr_ (PortableServer::ServantManager::_nil ()) + : ptr_ (PortableServer::ServantManager::_nil ()) {} ACE_INLINE PortableServer::ServantManager_var::ServantManager_var (PortableServer::ServantManager_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::ServantManager_ptr @@ -2164,7 +2363,7 @@ PortableServer::ServantManager_var::ptr (void) const ACE_INLINE PortableServer::ServantManager_var::ServantManager_var (const PortableServer::ServantManager_var &p) // copy constructor - : ptr_ (PortableServer::ServantManager::_duplicate (p.ptr ())) + : ptr_ (PortableServer::ServantManager::_duplicate (p.ptr ())) {} ACE_INLINE @@ -2185,10 +2384,10 @@ ACE_INLINE PortableServer::ServantManager_var & PortableServer::ServantManager_var::operator= (const PortableServer::ServantManager_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::ServantManager::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::ServantManager::_duplicate (p.ptr ()); + } return *this; } @@ -2252,14 +2451,14 @@ PortableServer::ServantManager_var::_retn (void) ACE_INLINE PortableServer::ServantManager_out::ServantManager_out (PortableServer::ServantManager_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::ServantManager::_nil (); } ACE_INLINE PortableServer::ServantManager_out::ServantManager_out (PortableServer::ServantManager_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::ServantManager::_nil (); @@ -2267,7 +2466,7 @@ PortableServer::ServantManager_out::ServantManager_out (PortableServer::ServantM ACE_INLINE PortableServer::ServantManager_out::ServantManager_out (PortableServer::ServantManager_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::ServantManager_out & @@ -2314,11 +2513,11 @@ PortableServer::ServantManager_out::operator-> (void) ACE_INLINE PortableServer::ServantActivator::ServantActivator( - STUB_Object *objref, - TAO_ServantBase *servant, - CORBA::Boolean collocated - ) - : ACE_CORBA_1 (Object) (objref, servant, collocated) + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) {} ACE_INLINE @@ -2341,12 +2540,12 @@ PortableServer::ServantActivator::_nil (void) ACE_INLINE PortableServer::ServantActivator_var::ServantActivator_var (void) // default constructor - : ptr_ (PortableServer::ServantActivator::_nil ()) + : ptr_ (PortableServer::ServantActivator::_nil ()) {} ACE_INLINE PortableServer::ServantActivator_var::ServantActivator_var (PortableServer::ServantActivator_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::ServantActivator_ptr @@ -2357,7 +2556,7 @@ PortableServer::ServantActivator_var::ptr (void) const ACE_INLINE PortableServer::ServantActivator_var::ServantActivator_var (const PortableServer::ServantActivator_var &p) // copy constructor - : ptr_ (PortableServer::ServantActivator::_duplicate (p.ptr ())) + : ptr_ (PortableServer::ServantActivator::_duplicate (p.ptr ())) {} ACE_INLINE @@ -2378,10 +2577,10 @@ ACE_INLINE PortableServer::ServantActivator_var & PortableServer::ServantActivator_var::operator= (const PortableServer::ServantActivator_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::ServantActivator::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::ServantActivator::_duplicate (p.ptr ()); + } return *this; } @@ -2445,14 +2644,14 @@ PortableServer::ServantActivator_var::_retn (void) ACE_INLINE PortableServer::ServantActivator_out::ServantActivator_out (PortableServer::ServantActivator_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::ServantActivator::_nil (); } ACE_INLINE PortableServer::ServantActivator_out::ServantActivator_out (PortableServer::ServantActivator_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::ServantActivator::_nil (); @@ -2460,7 +2659,7 @@ PortableServer::ServantActivator_out::ServantActivator_out (PortableServer::Serv ACE_INLINE PortableServer::ServantActivator_out::ServantActivator_out (PortableServer::ServantActivator_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::ServantActivator_out & @@ -2507,11 +2706,11 @@ PortableServer::ServantActivator_out::operator-> (void) ACE_INLINE PortableServer::ServantLocator::ServantLocator( - STUB_Object *objref, - TAO_ServantBase *servant, - CORBA::Boolean collocated - ) - : ACE_CORBA_1 (Object) (objref, servant, collocated) + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) {} ACE_INLINE @@ -2534,12 +2733,12 @@ PortableServer::ServantLocator::_nil (void) ACE_INLINE PortableServer::ServantLocator_var::ServantLocator_var (void) // default constructor - : ptr_ (PortableServer::ServantLocator::_nil ()) + : ptr_ (PortableServer::ServantLocator::_nil ()) {} ACE_INLINE PortableServer::ServantLocator_var::ServantLocator_var (PortableServer::ServantLocator_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::ServantLocator_ptr @@ -2550,7 +2749,7 @@ PortableServer::ServantLocator_var::ptr (void) const ACE_INLINE PortableServer::ServantLocator_var::ServantLocator_var (const PortableServer::ServantLocator_var &p) // copy constructor - : ptr_ (PortableServer::ServantLocator::_duplicate (p.ptr ())) + : ptr_ (PortableServer::ServantLocator::_duplicate (p.ptr ())) {} ACE_INLINE @@ -2571,10 +2770,10 @@ ACE_INLINE PortableServer::ServantLocator_var & PortableServer::ServantLocator_var::operator= (const PortableServer::ServantLocator_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::ServantLocator::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::ServantLocator::_duplicate (p.ptr ()); + } return *this; } @@ -2638,14 +2837,14 @@ PortableServer::ServantLocator_var::_retn (void) ACE_INLINE PortableServer::ServantLocator_out::ServantLocator_out (PortableServer::ServantLocator_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::ServantLocator::_nil (); } ACE_INLINE PortableServer::ServantLocator_out::ServantLocator_out (PortableServer::ServantLocator_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::ServantLocator::_nil (); @@ -2653,7 +2852,7 @@ PortableServer::ServantLocator_out::ServantLocator_out (PortableServer::ServantL ACE_INLINE PortableServer::ServantLocator_out::ServantLocator_out (PortableServer::ServantLocator_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::ServantLocator_out & @@ -2700,11 +2899,11 @@ PortableServer::ServantLocator_out::operator-> (void) ACE_INLINE PortableServer::POA::POA( - STUB_Object *objref, - TAO_ServantBase *servant, - CORBA::Boolean collocated - ) - : ACE_CORBA_1 (Object) (objref, servant, collocated) + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) {} ACE_INLINE @@ -2721,12 +2920,12 @@ PortableServer::POA::~POA (void) // destructor ACE_INLINE PortableServer::POA_var::POA_var (void) // default constructor - : ptr_ (PortableServer::POA::_nil ()) + : ptr_ (PortableServer::POA::_nil ()) {} ACE_INLINE PortableServer::POA_var::POA_var (PortableServer::POA_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::POA_ptr @@ -2737,7 +2936,7 @@ PortableServer::POA_var::ptr (void) const ACE_INLINE PortableServer::POA_var::POA_var (const PortableServer::POA_var &p) // copy constructor - : ptr_ (PortableServer::POA::_duplicate (p.ptr ())) + : ptr_ (PortableServer::POA::_duplicate (p.ptr ())) {} ACE_INLINE @@ -2758,10 +2957,10 @@ ACE_INLINE PortableServer::POA_var & PortableServer::POA_var::operator= (const PortableServer::POA_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::POA::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::POA::_duplicate (p.ptr ()); + } return *this; } @@ -2825,14 +3024,14 @@ PortableServer::POA_var::_retn (void) ACE_INLINE PortableServer::POA_out::POA_out (PortableServer::POA_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::POA::_nil (); } ACE_INLINE PortableServer::POA_out::POA_out (PortableServer::POA_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::POA::_nil (); @@ -2840,7 +3039,7 @@ PortableServer::POA_out::POA_out (PortableServer::POA_var &p) // constructor fro ACE_INLINE PortableServer::POA_out::POA_out (PortableServer::POA_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::POA_out & @@ -2887,11 +3086,11 @@ PortableServer::POA_out::operator-> (void) ACE_INLINE PortableServer::Current::Current( - STUB_Object *objref, - TAO_ServantBase *servant, - CORBA::Boolean collocated - ) - : ACE_CORBA_1 (Object) (objref, servant, collocated) + STUB_Object *objref, + TAO_ServantBase *servant, + CORBA::Boolean collocated + ) + : ACE_CORBA_1 (Object) (objref, servant, collocated) {} ACE_INLINE @@ -2914,12 +3113,12 @@ PortableServer::Current::_nil (void) ACE_INLINE PortableServer::Current_var::Current_var (void) // default constructor - : ptr_ (PortableServer::Current::_nil ()) + : ptr_ (PortableServer::Current::_nil ()) {} ACE_INLINE PortableServer::Current_var::Current_var (PortableServer::Current_ptr p) - : ptr_ (p) + : ptr_ (p) {} ACE_INLINE PortableServer::Current_ptr @@ -2930,7 +3129,7 @@ PortableServer::Current_var::ptr (void) const ACE_INLINE PortableServer::Current_var::Current_var (const PortableServer::Current_var &p) // copy constructor - : ptr_ (PortableServer::Current::_duplicate (p.ptr ())) + : ptr_ (PortableServer::Current::_duplicate (p.ptr ())) {} ACE_INLINE @@ -2951,10 +3150,10 @@ ACE_INLINE PortableServer::Current_var & PortableServer::Current_var::operator= (const PortableServer::Current_var &p) { if (this != &p) - { - CORBA::release (this->ptr_); - this->ptr_ = PortableServer::Current::_duplicate (p.ptr ()); - } + { + CORBA::release (this->ptr_); + this->ptr_ = PortableServer::Current::_duplicate (p.ptr ()); + } return *this; } @@ -3018,14 +3217,14 @@ PortableServer::Current_var::_retn (void) ACE_INLINE PortableServer::Current_out::Current_out (PortableServer::Current_ptr &p) - : ptr_ (p) + : ptr_ (p) { this->ptr_ = PortableServer::Current::_nil (); } ACE_INLINE PortableServer::Current_out::Current_out (PortableServer::Current_var &p) // constructor from _var - : ptr_ (p.out ()) + : ptr_ (p.out ()) { CORBA::release (this->ptr_); this->ptr_ = PortableServer::Current::_nil (); @@ -3033,7 +3232,7 @@ PortableServer::Current_out::Current_out (PortableServer::Current_var &p) // con ACE_INLINE PortableServer::Current_out::Current_out (PortableServer::Current_out &p) // copy constructor - : ptr_ (p.ptr_) + : ptr_ (p.ptr_) {} ACE_INLINE PortableServer::Current_out & diff --git a/TAO/tao/POAS.cpp b/TAO/tao/POAS.cpp index cb1f05b066c..45a18f28e6c 100644 --- a/TAO/tao/POAS.cpp +++ b/TAO/tao/POAS.cpp @@ -33,11 +33,11 @@ POA_PortableServer::ThreadPolicy::ThreadPolicy (void) } void POA_PortableServer::ThreadPolicy::_get_value_skel ( - CORBA::ServerRequest &_tao_server_request, - void *_tao_object_reference, - void * /* context */, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void *_tao_object_reference, + void * /* context */, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel _get_PortableServer_ThreadPolicy_value_paramdata [] = @@ -51,28 +51,28 @@ void POA_PortableServer::ThreadPolicy::_get_value_skel ( POA_PortableServer::ThreadPolicy *_tao_impl = (POA_PortableServer::ThreadPolicy *)_tao_object_reference; PortableServer::ThreadPolicyValue _tao_retval; _tao_server_request.demarshal ( - _tao_orb_environment, - &_get_PortableServer_ThreadPolicy_value_calldata, - &_tao_retval - ); + _tao_orb_environment, + &_get_PortableServer_ThreadPolicy_value_calldata, + &_tao_retval + ); if (_tao_orb_environment.exception ()) return; _tao_retval = _tao_impl->value ( - _tao_skel_environment - ); + _tao_skel_environment + ); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &_get_PortableServer_ThreadPolicy_value_calldata, - &_tao_retval - ); + _tao_orb_environment, + _tao_skel_environment, + &_get_PortableServer_ThreadPolicy_value_calldata, + &_tao_retval + ); } void POA_PortableServer::ThreadPolicy::_is_a_skel ( - CORBA::ServerRequest &_tao_server_request, - void * _tao_object_reference, - void * /*context*/, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_ThreadPolicy_is_a_paramdata [] = @@ -86,40 +86,40 @@ void POA_PortableServer::ThreadPolicy::_is_a_skel ( CORBA::Boolean _tao_retval; char *_tao_value = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_ThreadPolicy_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + &PortableServer_ThreadPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); if (_tao_orb_environment.exception () != 0) return; _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_ThreadPolicy_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_ThreadPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); CORBA::string_free (_tao_value); } CORBA::Boolean POA_PortableServer::ThreadPolicy::_is_a ( - const char* value, - CORBA::Environment &_tao_orb_environment - ) + const char* value, + CORBA::Environment &_tao_orb_environment + ) { if ( - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ThreadPolicy:1.0")) || - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || - (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) - return CORBA::B_TRUE; - else - return CORBA::B_FALSE; + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ThreadPolicy:1.0")) || + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; } void* POA_PortableServer::ThreadPolicy::_downcast ( - const char* logical_type_id - ) + const char* logical_type_id + ) { if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/ThreadPolicy:1.0") == 0) return ACE_static_cast (POA_PortableServer::ThreadPolicy_ptr, this); @@ -136,12 +136,12 @@ void POA_PortableServer::ThreadPolicy::_dispatch (CORBA::ServerRequest &req, voi const char *opname = req.operation (); // retrieve operation name // find the skeleton corresponding to this opname if (this->_find (opname, skel) == -1) - { - env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); - ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); - } -else - skel (req, this, context, env); + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); } const char* POA_PortableServer::ThreadPolicy::_interface_repository_id (void) const @@ -150,9 +150,9 @@ const char* POA_PortableServer::ThreadPolicy::_interface_repository_id (void) co } POA_PortableServer::_tao_collocated_ThreadPolicy::_tao_collocated_ThreadPolicy ( - POA_PortableServer::ThreadPolicy_ptr servant, - STUB_Object *stub - ) + POA_PortableServer::ThreadPolicy_ptr servant, + STUB_Object *stub + ) : ACE_NESTED_CLASS (PortableServer, ThreadPolicy) (stub, servant, CORBA::B_TRUE), ACE_NESTED_CLASS (POA_CORBA, _tao_collocated_Policy) (servant, stub), CORBA_Object (stub, servant, CORBA::B_TRUE), @@ -166,46 +166,46 @@ POA_PortableServer::ThreadPolicy_ptr POA_PortableServer::_tao_collocated_ThreadP } CORBA::Boolean POA_PortableServer::_tao_collocated_ThreadPolicy::_is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_orb_environment - ) + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->_is_a ( - logical_type_id, - _tao_orb_environment - ); + logical_type_id, + _tao_orb_environment + ); } CORBA::Policy_ptr POA_PortableServer::_tao_collocated_ThreadPolicy::copy ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->copy ( - _tao_orb_environment - ); + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_ThreadPolicy::destroy ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { this->servant_->destroy ( - _tao_orb_environment - ); + _tao_orb_environment + ); } CORBA::PolicyType POA_PortableServer::_tao_collocated_ThreadPolicy::policy_type ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->policy_type (_tao_orb_environment); } PortableServer::ThreadPolicyValue POA_PortableServer::_tao_collocated_ThreadPolicy::value ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->value(_tao_orb_environment); } @@ -239,11 +239,11 @@ POA_PortableServer::LifespanPolicy::LifespanPolicy (void) } void POA_PortableServer::LifespanPolicy::_get_value_skel ( - CORBA::ServerRequest &_tao_server_request, - void *_tao_object_reference, - void * /* context */, - CORBA::Environment &_tao_orb_environment -) + CORBA::ServerRequest &_tao_server_request, + void *_tao_object_reference, + void * /* context */, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel _get_PortableServer_LifespanPolicy_value_paramdata [] = @@ -257,28 +257,28 @@ void POA_PortableServer::LifespanPolicy::_get_value_skel ( POA_PortableServer::LifespanPolicy *_tao_impl = (POA_PortableServer::LifespanPolicy *)_tao_object_reference; PortableServer::LifespanPolicyValue _tao_retval; _tao_server_request.demarshal ( - _tao_orb_environment, - &_get_PortableServer_LifespanPolicy_value_calldata, - &_tao_retval - ); + _tao_orb_environment, + &_get_PortableServer_LifespanPolicy_value_calldata, + &_tao_retval + ); if (_tao_orb_environment.exception ()) return; _tao_retval = _tao_impl->value ( - _tao_skel_environment - ); + _tao_skel_environment + ); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &_get_PortableServer_LifespanPolicy_value_calldata, - &_tao_retval - ); + _tao_orb_environment, + _tao_skel_environment, + &_get_PortableServer_LifespanPolicy_value_calldata, + &_tao_retval + ); } void POA_PortableServer::LifespanPolicy::_is_a_skel ( - CORBA::ServerRequest &_tao_server_request, - void * _tao_object_reference, - void * /*context*/, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_LifespanPolicy_is_a_paramdata [] = @@ -292,40 +292,40 @@ void POA_PortableServer::LifespanPolicy::_is_a_skel ( CORBA::Boolean _tao_retval; char *_tao_value = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_LifespanPolicy_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + &PortableServer_LifespanPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); if (_tao_orb_environment.exception () != 0) return; _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_LifespanPolicy_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_LifespanPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); CORBA::string_free (_tao_value); } CORBA::Boolean POA_PortableServer::LifespanPolicy::_is_a ( - const char* value, - CORBA::Environment &_tao_orb_environment - ) + const char* value, + CORBA::Environment &_tao_orb_environment + ) { if ( - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/LifespanPolicy:1.0")) || - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || - (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) - return CORBA::B_TRUE; - else - return CORBA::B_FALSE; + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/LifespanPolicy:1.0")) || + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; } void* POA_PortableServer::LifespanPolicy::_downcast ( - const char* logical_type_id - ) + const char* logical_type_id + ) { if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/LifespanPolicy:1.0") == 0) return ACE_static_cast (POA_PortableServer::LifespanPolicy_ptr, this); @@ -342,12 +342,12 @@ void POA_PortableServer::LifespanPolicy::_dispatch (CORBA::ServerRequest &req, v const char *opname = req.operation (); // retrieve operation name // find the skeleton corresponding to this opname if (this->_find (opname, skel) == -1) - { - env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); - ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); - } -else - skel (req, this, context, env); + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); } const char* POA_PortableServer::LifespanPolicy::_interface_repository_id (void) const @@ -356,9 +356,9 @@ const char* POA_PortableServer::LifespanPolicy::_interface_repository_id (void) } POA_PortableServer::_tao_collocated_LifespanPolicy::_tao_collocated_LifespanPolicy ( - POA_PortableServer::LifespanPolicy_ptr servant, - STUB_Object *stub - ) + POA_PortableServer::LifespanPolicy_ptr servant, + STUB_Object *stub + ) : ACE_NESTED_CLASS (PortableServer, LifespanPolicy) (stub, servant, CORBA::B_TRUE), ACE_NESTED_CLASS (POA_CORBA, _tao_collocated_Policy) (servant, stub), CORBA_Object (stub, servant, CORBA::B_TRUE), @@ -372,45 +372,45 @@ POA_PortableServer::LifespanPolicy_ptr POA_PortableServer::_tao_collocated_Lifes } CORBA::Boolean POA_PortableServer::_tao_collocated_LifespanPolicy::_is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_orb_environment - ) + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->_is_a ( - logical_type_id, - _tao_orb_environment - ); + logical_type_id, + _tao_orb_environment + ); } CORBA::Policy_ptr POA_PortableServer::_tao_collocated_LifespanPolicy::copy ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->copy ( - _tao_orb_environment - ); + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_LifespanPolicy::destroy ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { this->servant_->destroy ( - _tao_orb_environment - ); + _tao_orb_environment + ); } CORBA::PolicyType POA_PortableServer::_tao_collocated_LifespanPolicy::policy_type ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->policy_type (_tao_orb_environment); } PortableServer::LifespanPolicyValue POA_PortableServer::_tao_collocated_LifespanPolicy::value ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->value(_tao_orb_environment); } @@ -444,11 +444,11 @@ POA_PortableServer::IdUniquenessPolicy::IdUniquenessPolicy (void) } void POA_PortableServer::IdUniquenessPolicy::_get_value_skel ( - CORBA::ServerRequest &_tao_server_request, - void *_tao_object_reference, - void * /* context */, - CORBA::Environment &_tao_orb_environment -) + CORBA::ServerRequest &_tao_server_request, + void *_tao_object_reference, + void * /* context */, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel _get_PortableServer_IdUniquenessPolicy_value_paramdata [] = @@ -462,28 +462,28 @@ void POA_PortableServer::IdUniquenessPolicy::_get_value_skel ( POA_PortableServer::IdUniquenessPolicy *_tao_impl = (POA_PortableServer::IdUniquenessPolicy *)_tao_object_reference; PortableServer::IdUniquenessPolicyValue _tao_retval; _tao_server_request.demarshal ( - _tao_orb_environment, - &_get_PortableServer_IdUniquenessPolicy_value_calldata, - &_tao_retval - ); + _tao_orb_environment, + &_get_PortableServer_IdUniquenessPolicy_value_calldata, + &_tao_retval + ); if (_tao_orb_environment.exception ()) return; _tao_retval = _tao_impl->value ( - _tao_skel_environment - ); + _tao_skel_environment + ); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &_get_PortableServer_IdUniquenessPolicy_value_calldata, - &_tao_retval - ); + _tao_orb_environment, + _tao_skel_environment, + &_get_PortableServer_IdUniquenessPolicy_value_calldata, + &_tao_retval + ); } void POA_PortableServer::IdUniquenessPolicy::_is_a_skel ( - CORBA::ServerRequest &_tao_server_request, - void * _tao_object_reference, - void * /*context*/, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_IdUniquenessPolicy_is_a_paramdata [] = @@ -497,40 +497,40 @@ void POA_PortableServer::IdUniquenessPolicy::_is_a_skel ( CORBA::Boolean _tao_retval; char *_tao_value = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_IdUniquenessPolicy_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + &PortableServer_IdUniquenessPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); if (_tao_orb_environment.exception () != 0) return; _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_IdUniquenessPolicy_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_IdUniquenessPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); CORBA::string_free (_tao_value); } CORBA::Boolean POA_PortableServer::IdUniquenessPolicy::_is_a ( - const char* value, - CORBA::Environment &_tao_orb_environment - ) + const char* value, + CORBA::Environment &_tao_orb_environment + ) { if ( - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/IdUniquenessPolicy:1.0")) || - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || - (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) - return CORBA::B_TRUE; - else - return CORBA::B_FALSE; + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/IdUniquenessPolicy:1.0")) || + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; } void* POA_PortableServer::IdUniquenessPolicy::_downcast ( - const char* logical_type_id - ) + const char* logical_type_id + ) { if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/IdUniquenessPolicy:1.0") == 0) return ACE_static_cast (POA_PortableServer::IdUniquenessPolicy_ptr, this); @@ -547,12 +547,12 @@ void POA_PortableServer::IdUniquenessPolicy::_dispatch (CORBA::ServerRequest &re const char *opname = req.operation (); // retrieve operation name // find the skeleton corresponding to this opname if (this->_find (opname, skel) == -1) - { - env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); - ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); - } -else - skel (req, this, context, env); + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); } const char* POA_PortableServer::IdUniquenessPolicy::_interface_repository_id (void) const @@ -561,9 +561,9 @@ const char* POA_PortableServer::IdUniquenessPolicy::_interface_repository_id (vo } POA_PortableServer::_tao_collocated_IdUniquenessPolicy::_tao_collocated_IdUniquenessPolicy ( - POA_PortableServer::IdUniquenessPolicy_ptr servant, - STUB_Object *stub - ) + POA_PortableServer::IdUniquenessPolicy_ptr servant, + STUB_Object *stub + ) : ACE_NESTED_CLASS (PortableServer, IdUniquenessPolicy) (stub, servant, CORBA::B_TRUE), ACE_NESTED_CLASS (POA_CORBA, _tao_collocated_Policy) (servant, stub), CORBA_Object (stub, servant, CORBA::B_TRUE), @@ -577,45 +577,45 @@ POA_PortableServer::IdUniquenessPolicy_ptr POA_PortableServer::_tao_collocated_I } CORBA::Boolean POA_PortableServer::_tao_collocated_IdUniquenessPolicy::_is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_orb_environment - ) + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->_is_a ( - logical_type_id, - _tao_orb_environment - ); + logical_type_id, + _tao_orb_environment + ); } CORBA::Policy_ptr POA_PortableServer::_tao_collocated_IdUniquenessPolicy::copy ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->copy ( - _tao_orb_environment - ); + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_IdUniquenessPolicy::destroy ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { this->servant_->destroy ( - _tao_orb_environment - ); + _tao_orb_environment + ); } CORBA::PolicyType POA_PortableServer::_tao_collocated_IdUniquenessPolicy::policy_type ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->policy_type (_tao_orb_environment); } PortableServer::IdUniquenessPolicyValue POA_PortableServer::_tao_collocated_IdUniquenessPolicy::value ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->value(_tao_orb_environment); } @@ -649,11 +649,11 @@ POA_PortableServer::IdAssignmentPolicy::IdAssignmentPolicy (void) } void POA_PortableServer::IdAssignmentPolicy::_get_value_skel ( - CORBA::ServerRequest &_tao_server_request, - void *_tao_object_reference, - void * /* context */, - CORBA::Environment &_tao_orb_environment -) + CORBA::ServerRequest &_tao_server_request, + void *_tao_object_reference, + void * /* context */, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel _get_PortableServer_IdAssignmentPolicy_value_paramdata [] = @@ -667,28 +667,28 @@ void POA_PortableServer::IdAssignmentPolicy::_get_value_skel ( POA_PortableServer::IdAssignmentPolicy *_tao_impl = (POA_PortableServer::IdAssignmentPolicy *)_tao_object_reference; PortableServer::IdAssignmentPolicyValue _tao_retval; _tao_server_request.demarshal ( - _tao_orb_environment, - &_get_PortableServer_IdAssignmentPolicy_value_calldata, - &_tao_retval - ); + _tao_orb_environment, + &_get_PortableServer_IdAssignmentPolicy_value_calldata, + &_tao_retval + ); if (_tao_orb_environment.exception ()) return; _tao_retval = _tao_impl->value ( - _tao_skel_environment - ); + _tao_skel_environment + ); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &_get_PortableServer_IdAssignmentPolicy_value_calldata, - &_tao_retval - ); + _tao_orb_environment, + _tao_skel_environment, + &_get_PortableServer_IdAssignmentPolicy_value_calldata, + &_tao_retval + ); } void POA_PortableServer::IdAssignmentPolicy::_is_a_skel ( - CORBA::ServerRequest &_tao_server_request, - void * _tao_object_reference, - void * /*context*/, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_IdAssignmentPolicy_is_a_paramdata [] = @@ -702,40 +702,40 @@ void POA_PortableServer::IdAssignmentPolicy::_is_a_skel ( CORBA::Boolean _tao_retval; char *_tao_value = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_IdAssignmentPolicy_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + &PortableServer_IdAssignmentPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); if (_tao_orb_environment.exception () != 0) return; _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_IdAssignmentPolicy_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_IdAssignmentPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); CORBA::string_free (_tao_value); } CORBA::Boolean POA_PortableServer::IdAssignmentPolicy::_is_a ( - const char* value, - CORBA::Environment &_tao_orb_environment - ) + const char* value, + CORBA::Environment &_tao_orb_environment + ) { if ( - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/IdAssignmentPolicy:1.0")) || - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || - (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) - return CORBA::B_TRUE; - else - return CORBA::B_FALSE; + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/IdAssignmentPolicy:1.0")) || + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; } void* POA_PortableServer::IdAssignmentPolicy::_downcast ( - const char* logical_type_id - ) + const char* logical_type_id + ) { if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/IdAssignmentPolicy:1.0") == 0) return ACE_static_cast (POA_PortableServer::IdAssignmentPolicy_ptr, this); @@ -752,12 +752,12 @@ void POA_PortableServer::IdAssignmentPolicy::_dispatch (CORBA::ServerRequest &re const char *opname = req.operation (); // retrieve operation name // find the skeleton corresponding to this opname if (this->_find (opname, skel) == -1) - { - env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); - ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); - } -else - skel (req, this, context, env); + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); } const char* POA_PortableServer::IdAssignmentPolicy::_interface_repository_id (void) const @@ -766,9 +766,9 @@ const char* POA_PortableServer::IdAssignmentPolicy::_interface_repository_id (vo } POA_PortableServer::_tao_collocated_IdAssignmentPolicy::_tao_collocated_IdAssignmentPolicy ( - POA_PortableServer::IdAssignmentPolicy_ptr servant, - STUB_Object *stub - ) + POA_PortableServer::IdAssignmentPolicy_ptr servant, + STUB_Object *stub + ) : ACE_NESTED_CLASS (PortableServer, IdAssignmentPolicy) (stub, servant, CORBA::B_TRUE), ACE_NESTED_CLASS (POA_CORBA, _tao_collocated_Policy) (servant, stub), CORBA_Object (stub, servant, CORBA::B_TRUE), @@ -782,45 +782,45 @@ POA_PortableServer::IdAssignmentPolicy_ptr POA_PortableServer::_tao_collocated_I } CORBA::Boolean POA_PortableServer::_tao_collocated_IdAssignmentPolicy::_is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_orb_environment - ) + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->_is_a ( - logical_type_id, - _tao_orb_environment - ); + logical_type_id, + _tao_orb_environment + ); } CORBA::Policy_ptr POA_PortableServer::_tao_collocated_IdAssignmentPolicy::copy ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->copy ( - _tao_orb_environment - ); + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_IdAssignmentPolicy::destroy ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { this->servant_->destroy ( - _tao_orb_environment - ); + _tao_orb_environment + ); } CORBA::PolicyType POA_PortableServer::_tao_collocated_IdAssignmentPolicy::policy_type ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->policy_type (_tao_orb_environment); } PortableServer::IdAssignmentPolicyValue POA_PortableServer::_tao_collocated_IdAssignmentPolicy::value ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->value(_tao_orb_environment); } @@ -854,11 +854,11 @@ POA_PortableServer::ImplicitActivationPolicy::ImplicitActivationPolicy (void) } void POA_PortableServer::ImplicitActivationPolicy::_get_value_skel ( - CORBA::ServerRequest &_tao_server_request, - void *_tao_object_reference, - void * /* context */, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void *_tao_object_reference, + void * /* context */, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel _get_PortableServer_ImplicitActivationPolicy_value_paramdata [] = @@ -872,28 +872,28 @@ void POA_PortableServer::ImplicitActivationPolicy::_get_value_skel ( POA_PortableServer::ImplicitActivationPolicy *_tao_impl = (POA_PortableServer::ImplicitActivationPolicy *)_tao_object_reference; PortableServer::ImplicitActivationPolicyValue _tao_retval; _tao_server_request.demarshal ( - _tao_orb_environment, - &_get_PortableServer_ImplicitActivationPolicy_value_calldata, - &_tao_retval - ); + _tao_orb_environment, + &_get_PortableServer_ImplicitActivationPolicy_value_calldata, + &_tao_retval + ); if (_tao_orb_environment.exception ()) return; _tao_retval = _tao_impl->value ( - _tao_skel_environment - ); + _tao_skel_environment + ); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &_get_PortableServer_ImplicitActivationPolicy_value_calldata, - &_tao_retval - ); + _tao_orb_environment, + _tao_skel_environment, + &_get_PortableServer_ImplicitActivationPolicy_value_calldata, + &_tao_retval + ); } void POA_PortableServer::ImplicitActivationPolicy::_is_a_skel ( - CORBA::ServerRequest &_tao_server_request, - void * _tao_object_reference, - void * /*context*/, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_ImplicitActivationPolicy_is_a_paramdata [] = @@ -907,40 +907,40 @@ void POA_PortableServer::ImplicitActivationPolicy::_is_a_skel ( CORBA::Boolean _tao_retval; char *_tao_value = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_ImplicitActivationPolicy_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + &PortableServer_ImplicitActivationPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); if (_tao_orb_environment.exception () != 0) return; _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_ImplicitActivationPolicy_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_ImplicitActivationPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); CORBA::string_free (_tao_value); } CORBA::Boolean POA_PortableServer::ImplicitActivationPolicy::_is_a ( - const char* value, - CORBA::Environment &_tao_orb_environment - ) + const char* value, + CORBA::Environment &_tao_orb_environment + ) { if ( - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ImplicitActivationPolicy:1.0")) || - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || - (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) - return CORBA::B_TRUE; - else - return CORBA::B_FALSE; + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ImplicitActivationPolicy:1.0")) || + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; } void* POA_PortableServer::ImplicitActivationPolicy::_downcast ( - const char* logical_type_id - ) + const char* logical_type_id + ) { if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/ImplicitActivationPolicy:1.0") == 0) return ACE_static_cast (POA_PortableServer::ImplicitActivationPolicy_ptr, this); @@ -957,12 +957,12 @@ void POA_PortableServer::ImplicitActivationPolicy::_dispatch (CORBA::ServerReque const char *opname = req.operation (); // retrieve operation name // find the skeleton corresponding to this opname if (this->_find (opname, skel) == -1) - { - env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); - ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); - } -else - skel (req, this, context, env); + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); } const char* POA_PortableServer::ImplicitActivationPolicy::_interface_repository_id (void) const @@ -971,9 +971,9 @@ const char* POA_PortableServer::ImplicitActivationPolicy::_interface_repository_ } POA_PortableServer::_tao_collocated_ImplicitActivationPolicy::_tao_collocated_ImplicitActivationPolicy ( - POA_PortableServer::ImplicitActivationPolicy_ptr servant, - STUB_Object *stub - ) + POA_PortableServer::ImplicitActivationPolicy_ptr servant, + STUB_Object *stub + ) : ACE_NESTED_CLASS (PortableServer, ImplicitActivationPolicy) (stub, servant, CORBA::B_TRUE), ACE_NESTED_CLASS (POA_CORBA, _tao_collocated_Policy) (servant, stub), CORBA_Object (stub, servant, CORBA::B_TRUE), @@ -987,45 +987,45 @@ POA_PortableServer::ImplicitActivationPolicy_ptr POA_PortableServer::_tao_colloc } CORBA::Boolean POA_PortableServer::_tao_collocated_ImplicitActivationPolicy::_is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_orb_environment - ) + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->_is_a ( - logical_type_id, - _tao_orb_environment - ); + logical_type_id, + _tao_orb_environment + ); } CORBA::Policy_ptr POA_PortableServer::_tao_collocated_ImplicitActivationPolicy::copy ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->copy ( - _tao_orb_environment - ); + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_ImplicitActivationPolicy::destroy ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { this->servant_->destroy ( - _tao_orb_environment - ); + _tao_orb_environment + ); } CORBA::PolicyType POA_PortableServer::_tao_collocated_ImplicitActivationPolicy::policy_type ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->policy_type (_tao_orb_environment); } PortableServer::ImplicitActivationPolicyValue POA_PortableServer::_tao_collocated_ImplicitActivationPolicy::value ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->value(_tao_orb_environment); } @@ -1059,11 +1059,11 @@ POA_PortableServer::ServantRetentionPolicy::ServantRetentionPolicy (void) } void POA_PortableServer::ServantRetentionPolicy::_get_value_skel ( - CORBA::ServerRequest &_tao_server_request, - void *_tao_object_reference, - void * /* context */, - CORBA::Environment &_tao_orb_environment -) + CORBA::ServerRequest &_tao_server_request, + void *_tao_object_reference, + void * /* context */, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel _get_PortableServer_ServantRetentionPolicy_value_paramdata [] = @@ -1077,28 +1077,28 @@ void POA_PortableServer::ServantRetentionPolicy::_get_value_skel ( POA_PortableServer::ServantRetentionPolicy *_tao_impl = (POA_PortableServer::ServantRetentionPolicy *)_tao_object_reference; PortableServer::ServantRetentionPolicyValue _tao_retval; _tao_server_request.demarshal ( - _tao_orb_environment, - &_get_PortableServer_ServantRetentionPolicy_value_calldata, - &_tao_retval - ); + _tao_orb_environment, + &_get_PortableServer_ServantRetentionPolicy_value_calldata, + &_tao_retval + ); if (_tao_orb_environment.exception ()) return; _tao_retval = _tao_impl->value ( - _tao_skel_environment - ); + _tao_skel_environment + ); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &_get_PortableServer_ServantRetentionPolicy_value_calldata, - &_tao_retval - ); + _tao_orb_environment, + _tao_skel_environment, + &_get_PortableServer_ServantRetentionPolicy_value_calldata, + &_tao_retval + ); } void POA_PortableServer::ServantRetentionPolicy::_is_a_skel ( - CORBA::ServerRequest &_tao_server_request, - void * _tao_object_reference, - void * /*context*/, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_ServantRetentionPolicy_is_a_paramdata [] = @@ -1112,40 +1112,40 @@ void POA_PortableServer::ServantRetentionPolicy::_is_a_skel ( CORBA::Boolean _tao_retval; char *_tao_value = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_ServantRetentionPolicy_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + &PortableServer_ServantRetentionPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); if (_tao_orb_environment.exception () != 0) return; _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_ServantRetentionPolicy_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_ServantRetentionPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); CORBA::string_free (_tao_value); } CORBA::Boolean POA_PortableServer::ServantRetentionPolicy::_is_a ( - const char* value, - CORBA::Environment &_tao_orb_environment - ) + const char* value, + CORBA::Environment &_tao_orb_environment + ) { if ( - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ServantRetentionPolicy:1.0")) || - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || - (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) - return CORBA::B_TRUE; - else - return CORBA::B_FALSE; + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ServantRetentionPolicy:1.0")) || + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; } void* POA_PortableServer::ServantRetentionPolicy::_downcast ( - const char* logical_type_id - ) + const char* logical_type_id + ) { if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/ServantRetentionPolicy:1.0") == 0) return ACE_static_cast (POA_PortableServer::ServantRetentionPolicy_ptr, this); @@ -1162,12 +1162,12 @@ void POA_PortableServer::ServantRetentionPolicy::_dispatch (CORBA::ServerRequest const char *opname = req.operation (); // retrieve operation name // find the skeleton corresponding to this opname if (this->_find (opname, skel) == -1) - { - env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); - ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); - } -else - skel (req, this, context, env); + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); } const char* POA_PortableServer::ServantRetentionPolicy::_interface_repository_id (void) const @@ -1176,9 +1176,9 @@ const char* POA_PortableServer::ServantRetentionPolicy::_interface_repository_id } POA_PortableServer::_tao_collocated_ServantRetentionPolicy::_tao_collocated_ServantRetentionPolicy ( - POA_PortableServer::ServantRetentionPolicy_ptr servant, - STUB_Object *stub - ) + POA_PortableServer::ServantRetentionPolicy_ptr servant, + STUB_Object *stub + ) : ACE_NESTED_CLASS (PortableServer, ServantRetentionPolicy) (stub, servant, CORBA::B_TRUE), ACE_NESTED_CLASS (POA_CORBA, _tao_collocated_Policy) (servant, stub), CORBA_Object (stub, servant, CORBA::B_TRUE), @@ -1192,45 +1192,45 @@ POA_PortableServer::ServantRetentionPolicy_ptr POA_PortableServer::_tao_collocat } CORBA::Boolean POA_PortableServer::_tao_collocated_ServantRetentionPolicy::_is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_orb_environment - ) + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->_is_a ( - logical_type_id, - _tao_orb_environment - ); + logical_type_id, + _tao_orb_environment + ); } CORBA::Policy_ptr POA_PortableServer::_tao_collocated_ServantRetentionPolicy::copy ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->copy ( - _tao_orb_environment - ); + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_ServantRetentionPolicy::destroy ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { this->servant_->destroy ( - _tao_orb_environment - ); + _tao_orb_environment + ); } CORBA::PolicyType POA_PortableServer::_tao_collocated_ServantRetentionPolicy::policy_type ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->policy_type (_tao_orb_environment); } PortableServer::ServantRetentionPolicyValue POA_PortableServer::_tao_collocated_ServantRetentionPolicy::value ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->value(_tao_orb_environment); } @@ -1264,11 +1264,11 @@ POA_PortableServer::RequestProcessingPolicy::RequestProcessingPolicy (void) } void POA_PortableServer::RequestProcessingPolicy::_get_value_skel ( - CORBA::ServerRequest &_tao_server_request, - void *_tao_object_reference, - void * /* context */, - CORBA::Environment &_tao_orb_environment -) + CORBA::ServerRequest &_tao_server_request, + void *_tao_object_reference, + void * /* context */, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel _get_PortableServer_RequestProcessingPolicy_value_paramdata [] = @@ -1282,28 +1282,28 @@ void POA_PortableServer::RequestProcessingPolicy::_get_value_skel ( POA_PortableServer::RequestProcessingPolicy *_tao_impl = (POA_PortableServer::RequestProcessingPolicy *)_tao_object_reference; PortableServer::RequestProcessingPolicyValue _tao_retval; _tao_server_request.demarshal ( - _tao_orb_environment, - &_get_PortableServer_RequestProcessingPolicy_value_calldata, - &_tao_retval - ); + _tao_orb_environment, + &_get_PortableServer_RequestProcessingPolicy_value_calldata, + &_tao_retval + ); if (_tao_orb_environment.exception ()) return; _tao_retval = _tao_impl->value ( - _tao_skel_environment - ); + _tao_skel_environment + ); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &_get_PortableServer_RequestProcessingPolicy_value_calldata, - &_tao_retval - ); + _tao_orb_environment, + _tao_skel_environment, + &_get_PortableServer_RequestProcessingPolicy_value_calldata, + &_tao_retval + ); } void POA_PortableServer::RequestProcessingPolicy::_is_a_skel ( - CORBA::ServerRequest &_tao_server_request, - void * _tao_object_reference, - void * /*context*/, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_RequestProcessingPolicy_is_a_paramdata [] = @@ -1317,40 +1317,40 @@ void POA_PortableServer::RequestProcessingPolicy::_is_a_skel ( CORBA::Boolean _tao_retval; char *_tao_value = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_RequestProcessingPolicy_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + &PortableServer_RequestProcessingPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); if (_tao_orb_environment.exception () != 0) return; _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_RequestProcessingPolicy_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_RequestProcessingPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); CORBA::string_free (_tao_value); } CORBA::Boolean POA_PortableServer::RequestProcessingPolicy::_is_a ( - const char* value, - CORBA::Environment &_tao_orb_environment - ) + const char* value, + CORBA::Environment &_tao_orb_environment + ) { if ( - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/RequestProcessingPolicy:1.0")) || - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || - (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) - return CORBA::B_TRUE; - else - return CORBA::B_FALSE; + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/RequestProcessingPolicy:1.0")) || + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; } void* POA_PortableServer::RequestProcessingPolicy::_downcast ( - const char* logical_type_id - ) + const char* logical_type_id + ) { if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/RequestProcessingPolicy:1.0") == 0) return ACE_static_cast (POA_PortableServer::RequestProcessingPolicy_ptr, this); @@ -1367,12 +1367,12 @@ void POA_PortableServer::RequestProcessingPolicy::_dispatch (CORBA::ServerReques const char *opname = req.operation (); // retrieve operation name // find the skeleton corresponding to this opname if (this->_find (opname, skel) == -1) - { - env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); - ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); - } -else - skel (req, this, context, env); + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); } const char* POA_PortableServer::RequestProcessingPolicy::_interface_repository_id (void) const @@ -1381,9 +1381,9 @@ const char* POA_PortableServer::RequestProcessingPolicy::_interface_repository_i } POA_PortableServer::_tao_collocated_RequestProcessingPolicy::_tao_collocated_RequestProcessingPolicy ( - POA_PortableServer::RequestProcessingPolicy_ptr servant, - STUB_Object *stub - ) + POA_PortableServer::RequestProcessingPolicy_ptr servant, + STUB_Object *stub + ) : ACE_NESTED_CLASS (PortableServer, RequestProcessingPolicy) (stub, servant, CORBA::B_TRUE), ACE_NESTED_CLASS (POA_CORBA, _tao_collocated_Policy) (servant, stub), CORBA_Object (stub, servant, CORBA::B_TRUE), @@ -1397,45 +1397,45 @@ POA_PortableServer::RequestProcessingPolicy_ptr POA_PortableServer::_tao_colloca } CORBA::Boolean POA_PortableServer::_tao_collocated_RequestProcessingPolicy::_is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_orb_environment - ) + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->_is_a ( - logical_type_id, - _tao_orb_environment - ); + logical_type_id, + _tao_orb_environment + ); } CORBA::Policy_ptr POA_PortableServer::_tao_collocated_RequestProcessingPolicy::copy ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->copy ( - _tao_orb_environment - ); + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_RequestProcessingPolicy::destroy ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { this->servant_->destroy ( - _tao_orb_environment - ); + _tao_orb_environment + ); } CORBA::PolicyType POA_PortableServer::_tao_collocated_RequestProcessingPolicy::policy_type ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->policy_type (_tao_orb_environment); } PortableServer::RequestProcessingPolicyValue POA_PortableServer::_tao_collocated_RequestProcessingPolicy::value ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->value(_tao_orb_environment); } @@ -1449,6 +1449,217 @@ POA_PortableServer::RequestProcessingPolicy::_this (CORBA_Environment &_env) return new POA_PortableServer::_tao_collocated_RequestProcessingPolicy (this, stub); } +// ************************************************** +// +// TAO spcific POA locking policy (non-standard) +// +// ************************************************** + +static const TAO_operation_db_entry PortableServer_TAO_POA_LockingPolicy_operations [] = { + {"_get_value", &POA_PortableServer::TAO_POA_LockingPolicy::_get_value_skel}, + {"copy", &POA_PortableServer::TAO_POA_LockingPolicy::copy_skel}, + {"destroy", &POA_PortableServer::TAO_POA_LockingPolicy::destroy_skel}, + {"_get_policy_type", &POA_PortableServer::TAO_POA_LockingPolicy::_get_policy_type_skel}, + {"_is_a", &POA_PortableServer::TAO_POA_LockingPolicy::_is_a_skel} +}; + +static const CORBA::Long _tao_PortableServer_TAO_POA_LockingPolicy_optable_size = sizeof (ACE_Hash_Map_Entry<const char *, TAO_Skeleton>) * (15); +static char _tao_PortableServer_TAO_POA_LockingPolicy_optable_pool [_tao_PortableServer_TAO_POA_LockingPolicy_optable_size]; +static ACE_Static_Allocator_Base _tao_PortableServer_TAO_POA_LockingPolicy_allocator (_tao_PortableServer_TAO_POA_LockingPolicy_optable_pool, _tao_PortableServer_TAO_POA_LockingPolicy_optable_size); +static TAO_Dynamic_Hash_OpTable tao_PortableServer_TAO_POA_LockingPolicy_optable (PortableServer_TAO_POA_LockingPolicy_operations, 5, 10, &_tao_PortableServer_TAO_POA_LockingPolicy_allocator); + +// skeleton constructor +POA_PortableServer::TAO_POA_LockingPolicy::TAO_POA_LockingPolicy (void) +{ + this->optable_ = &tao_PortableServer_TAO_POA_LockingPolicy_optable; +} + +void POA_PortableServer::TAO_POA_LockingPolicy::_get_value_skel ( + CORBA::ServerRequest &_tao_server_request, + void *_tao_object_reference, + void * /* context */, + CORBA::Environment &_tao_orb_environment + ) +{ + CORBA::Environment _tao_skel_environment; + static const TAO_Param_Data_Skel _get_PortableServer_TAO_POA_LockingPolicy_value_paramdata [] = + { + {PortableServer::_tc_TAO_POA_LockingPolicyValue, 0, 0} + }; // PortableServer_TAO_POA_LockingPolicy_value_paramdata + + static const TAO_Call_Data_Skel _get_PortableServer_TAO_POA_LockingPolicy_value_calldata = + {"_get_value", 1, 1, _get_PortableServer_TAO_POA_LockingPolicy_value_paramdata}; + + POA_PortableServer::TAO_POA_LockingPolicy *_tao_impl = (POA_PortableServer::TAO_POA_LockingPolicy *)_tao_object_reference; + PortableServer::TAO_POA_LockingPolicyValue _tao_retval; + _tao_server_request.demarshal ( + _tao_orb_environment, + &_get_PortableServer_TAO_POA_LockingPolicy_value_calldata, + &_tao_retval + ); + if (_tao_orb_environment.exception ()) return; + _tao_retval = _tao_impl->value ( + _tao_skel_environment + ); + _tao_server_request.marshal ( + _tao_orb_environment, + _tao_skel_environment, + &_get_PortableServer_TAO_POA_LockingPolicy_value_calldata, + &_tao_retval + ); +} + +void POA_PortableServer::TAO_POA_LockingPolicy::_is_a_skel ( + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) +{ + CORBA::Environment _tao_skel_environment; + static const TAO_Param_Data_Skel PortableServer_TAO_POA_LockingPolicy_is_a_paramdata [] = + { + {CORBA::_tc_boolean, 0, 0}, + {CORBA::_tc_string, CORBA::ARG_IN, 0} + }; + static const TAO_Call_Data_Skel PortableServer_TAO_POA_LockingPolicy_is_a_calldata = + {"_is_a", 1, 2, PortableServer_TAO_POA_LockingPolicy_is_a_paramdata}; + POA_PortableServer::TAO_POA_LockingPolicy_ptr _tao_impl = (POA_PortableServer::TAO_POA_LockingPolicy_ptr) _tao_object_reference; + CORBA::Boolean _tao_retval; + char *_tao_value = 0; + _tao_server_request.demarshal ( + _tao_orb_environment, + &PortableServer_TAO_POA_LockingPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); + if (_tao_orb_environment.exception () != 0) return; + _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); + _tao_server_request.marshal ( + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_TAO_POA_LockingPolicy_is_a_calldata, + &_tao_retval, + &_tao_value + ); + CORBA::string_free (_tao_value); +} + +CORBA::Boolean POA_PortableServer::TAO_POA_LockingPolicy::_is_a ( + const char* value, + CORBA::Environment &_tao_orb_environment + ) +{ + if ( + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/TAO_POA_LockingPolicy:1.0")) || + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Policy:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; +} + +void* POA_PortableServer::TAO_POA_LockingPolicy::_downcast ( + const char* logical_type_id + ) +{ + if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/TAO_POA_LockingPolicy:1.0") == 0) + return ACE_static_cast (POA_PortableServer::TAO_POA_LockingPolicy_ptr, this); + if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/Policy:1.0") == 0) + return ACE_static_cast (POA_CORBA::Policy_ptr, this); + if (ACE_OS::strcmp (logical_type_id, "IDL:omg.org/CORBA/Object:1.0") == 0) + return ACE_static_cast(PortableServer::Servant, this); + return 0; +} + +void POA_PortableServer::TAO_POA_LockingPolicy::_dispatch (CORBA::ServerRequest &req, void *context, CORBA::Environment &env) +{ + TAO_Skeleton skel; // pointer to skeleton for operation + const char *opname = req.operation (); // retrieve operation name + // find the skeleton corresponding to this opname + if (this->_find (opname, skel) == -1) + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); +} + +const char* POA_PortableServer::TAO_POA_LockingPolicy::_interface_repository_id (void) const +{ + return "IDL:PortableServer/TAO_POA_LockingPolicy:1.0"; +} + +POA_PortableServer::_tao_collocated_TAO_POA_LockingPolicy::_tao_collocated_TAO_POA_LockingPolicy ( + POA_PortableServer::TAO_POA_LockingPolicy_ptr servant, + STUB_Object *stub + ) + : ACE_NESTED_CLASS (PortableServer, TAO_POA_LockingPolicy) (stub, servant, CORBA::B_TRUE), + ACE_NESTED_CLASS (POA_CORBA, _tao_collocated_Policy) (servant, stub), + CORBA_Object (stub, servant, CORBA::B_TRUE), + servant_ (servant) +{ +} + +POA_PortableServer::TAO_POA_LockingPolicy_ptr POA_PortableServer::_tao_collocated_TAO_POA_LockingPolicy::_get_servant (void) const +{ + return this->servant_; +} + +CORBA::Boolean POA_PortableServer::_tao_collocated_TAO_POA_LockingPolicy::_is_a ( + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) +{ + return this->servant_->_is_a ( + logical_type_id, + _tao_orb_environment + ); +} + +CORBA::Policy_ptr POA_PortableServer::_tao_collocated_TAO_POA_LockingPolicy::copy ( + CORBA::Environment &_tao_orb_environment + ) +{ + return this->servant_->copy ( + _tao_orb_environment + ); +} + +void POA_PortableServer::_tao_collocated_TAO_POA_LockingPolicy::destroy ( + CORBA::Environment &_tao_orb_environment + ) +{ + this->servant_->destroy ( + _tao_orb_environment + ); +} + +CORBA::PolicyType POA_PortableServer::_tao_collocated_TAO_POA_LockingPolicy::policy_type ( + CORBA::Environment &_tao_orb_environment + ) +{ + return this->servant_->policy_type (_tao_orb_environment); +} + +PortableServer::TAO_POA_LockingPolicyValue +POA_PortableServer::_tao_collocated_TAO_POA_LockingPolicy::value ( + CORBA::Environment &_tao_orb_environment + ) +{ + return this->servant_->value(_tao_orb_environment); +} + +PortableServer::TAO_POA_LockingPolicy* +POA_PortableServer::TAO_POA_LockingPolicy::_this (CORBA_Environment &_env) +{ + STUB_Object *stub = this->_create_stub (_env); + if (_env.exception () != 0) + return 0; + return new POA_PortableServer::_tao_collocated_TAO_POA_LockingPolicy (this, stub); +} + static const TAO_operation_db_entry PortableServer_POAManager_operations [] = { {"_is_a", &POA_PortableServer::POAManager::_is_a_skel} }; @@ -1465,11 +1676,11 @@ POA_PortableServer::POAManager::POAManager (void) } void POA_PortableServer::POAManager::_is_a_skel ( - CORBA::ServerRequest &_tao_server_request, - void * _tao_object_reference, - void * /*context*/, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_POAManager_is_a_paramdata [] = @@ -1483,39 +1694,39 @@ void POA_PortableServer::POAManager::_is_a_skel ( CORBA::Boolean _tao_retval; char *_tao_value = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_POAManager_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + &PortableServer_POAManager_is_a_calldata, + &_tao_retval, + &_tao_value + ); if (_tao_orb_environment.exception () != 0) return; _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_POAManager_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_POAManager_is_a_calldata, + &_tao_retval, + &_tao_value + ); CORBA::string_free (_tao_value); } CORBA::Boolean POA_PortableServer::POAManager::_is_a ( - const char* value, - CORBA::Environment &_tao_orb_environment - ) + const char* value, + CORBA::Environment &_tao_orb_environment + ) { if ( - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/POAManager:1.0")) || - (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) - return CORBA::B_TRUE; - else - return CORBA::B_FALSE; + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/POAManager:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; } void* POA_PortableServer::POAManager::_downcast ( - const char* logical_type_id - ) + const char* logical_type_id + ) { if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/POAManager:1.0") == 0) return ACE_static_cast (POA_PortableServer::POAManager_ptr, this); @@ -1530,12 +1741,12 @@ void POA_PortableServer::POAManager::_dispatch (CORBA::ServerRequest &req, void const char *opname = req.operation (); // retrieve operation name // find the skeleton corresponding to this opname if (this->_find (opname, skel) == -1) - { - env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); - ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); - } -else - skel (req, this, context, env); + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); } const char* POA_PortableServer::POAManager::_interface_repository_id (void) const @@ -1544,9 +1755,9 @@ const char* POA_PortableServer::POAManager::_interface_repository_id (void) cons } POA_PortableServer::_tao_collocated_POAManager::_tao_collocated_POAManager ( - POA_PortableServer::POAManager_ptr servant, - STUB_Object *stub - ) + POA_PortableServer::POAManager_ptr servant, + STUB_Object *stub + ) : ACE_NESTED_CLASS (PortableServer, POAManager) (stub, servant, CORBA::B_TRUE), CORBA_Object (stub, servant, CORBA::B_TRUE), servant_ (servant) @@ -1559,58 +1770,58 @@ POA_PortableServer::POAManager_ptr POA_PortableServer::_tao_collocated_POAManage } CORBA::Boolean POA_PortableServer::_tao_collocated_POAManager::_is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_orb_environment - ) + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->_is_a ( - logical_type_id, - _tao_orb_environment - ); + logical_type_id, + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_POAManager::activate ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { this->servant_->activate ( - _tao_orb_environment - ); + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_POAManager::hold_requests ( - CORBA::Boolean wait_for_completion, - CORBA::Environment &_tao_orb_environment - ) + CORBA::Boolean wait_for_completion, + CORBA::Environment &_tao_orb_environment + ) { this->servant_->hold_requests ( - wait_for_completion, - _tao_orb_environment - ); + wait_for_completion, + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_POAManager::discard_requests ( - CORBA::Boolean wait_for_completion, - CORBA::Environment &_tao_orb_environment - ) + CORBA::Boolean wait_for_completion, + CORBA::Environment &_tao_orb_environment + ) { this->servant_->discard_requests ( - wait_for_completion, - _tao_orb_environment - ); + wait_for_completion, + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_POAManager::deactivate ( - CORBA::Boolean etherealize_objects, - CORBA::Boolean wait_for_completion, - CORBA::Environment &_tao_orb_environment - ) + CORBA::Boolean etherealize_objects, + CORBA::Boolean wait_for_completion, + CORBA::Environment &_tao_orb_environment + ) { this->servant_->deactivate ( - etherealize_objects, - wait_for_completion, - _tao_orb_environment - ); + etherealize_objects, + wait_for_completion, + _tao_orb_environment + ); } @@ -1639,11 +1850,11 @@ POA_PortableServer::AdapterActivator::AdapterActivator (void) } void POA_PortableServer::AdapterActivator::_is_a_skel ( - CORBA::ServerRequest &_tao_server_request, - void * _tao_object_reference, - void * /*context*/, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_AdapterActivator_is_a_paramdata [] = @@ -1657,39 +1868,39 @@ void POA_PortableServer::AdapterActivator::_is_a_skel ( CORBA::Boolean _tao_retval; char *_tao_value = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_AdapterActivator_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + &PortableServer_AdapterActivator_is_a_calldata, + &_tao_retval, + &_tao_value + ); if (_tao_orb_environment.exception () != 0) return; _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_AdapterActivator_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_AdapterActivator_is_a_calldata, + &_tao_retval, + &_tao_value + ); CORBA::string_free (_tao_value); } CORBA::Boolean POA_PortableServer::AdapterActivator::_is_a ( - const char* value, - CORBA::Environment &_tao_orb_environment - ) + const char* value, + CORBA::Environment &_tao_orb_environment + ) { if ( - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/AdapterActivator:1.0")) || - (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) - return CORBA::B_TRUE; - else - return CORBA::B_FALSE; + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/AdapterActivator:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; } void* POA_PortableServer::AdapterActivator::_downcast ( - const char* logical_type_id - ) + const char* logical_type_id + ) { if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/AdapterActivator:1.0") == 0) return ACE_static_cast (POA_PortableServer::AdapterActivator_ptr, this); @@ -1704,12 +1915,12 @@ void POA_PortableServer::AdapterActivator::_dispatch (CORBA::ServerRequest &req, const char *opname = req.operation (); // retrieve operation name // find the skeleton corresponding to this opname if (this->_find (opname, skel) == -1) - { - env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); - ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); - } -else - skel (req, this, context, env); + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); } const char* POA_PortableServer::AdapterActivator::_interface_repository_id (void) const @@ -1718,9 +1929,9 @@ const char* POA_PortableServer::AdapterActivator::_interface_repository_id (void } POA_PortableServer::_tao_collocated_AdapterActivator::_tao_collocated_AdapterActivator ( - POA_PortableServer::AdapterActivator_ptr servant, - STUB_Object *stub - ) + POA_PortableServer::AdapterActivator_ptr servant, + STUB_Object *stub + ) : ACE_NESTED_CLASS (PortableServer, AdapterActivator) (stub, servant, CORBA::B_TRUE), CORBA_Object (stub, servant, CORBA::B_TRUE), servant_ (servant) @@ -1733,27 +1944,27 @@ POA_PortableServer::AdapterActivator_ptr POA_PortableServer::_tao_collocated_Ada } CORBA::Boolean POA_PortableServer::_tao_collocated_AdapterActivator::_is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_orb_environment - ) + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->_is_a ( - logical_type_id, - _tao_orb_environment - ); + logical_type_id, + _tao_orb_environment + ); } CORBA::Boolean POA_PortableServer::_tao_collocated_AdapterActivator::unknown_adapter ( - PortableServer::POA_ptr parent, - const char* name, - CORBA::Environment &_tao_orb_environment - ) + PortableServer::POA_ptr parent, + const char* name, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->unknown_adapter ( - parent, - name, - _tao_orb_environment - ); + parent, + name, + _tao_orb_environment + ); } @@ -1782,11 +1993,11 @@ POA_PortableServer::ServantManager::ServantManager (void) } void POA_PortableServer::ServantManager::_is_a_skel ( - CORBA::ServerRequest &_tao_server_request, - void * _tao_object_reference, - void * /*context*/, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_ServantManager_is_a_paramdata [] = @@ -1800,39 +2011,39 @@ void POA_PortableServer::ServantManager::_is_a_skel ( CORBA::Boolean _tao_retval; char *_tao_value = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_ServantManager_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + &PortableServer_ServantManager_is_a_calldata, + &_tao_retval, + &_tao_value + ); if (_tao_orb_environment.exception () != 0) return; _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_ServantManager_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_ServantManager_is_a_calldata, + &_tao_retval, + &_tao_value + ); CORBA::string_free (_tao_value); } CORBA::Boolean POA_PortableServer::ServantManager::_is_a ( - const char* value, - CORBA::Environment &_tao_orb_environment - ) + const char* value, + CORBA::Environment &_tao_orb_environment + ) { if ( - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ServantManager:1.0")) || - (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) - return CORBA::B_TRUE; - else - return CORBA::B_FALSE; + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ServantManager:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; } void* POA_PortableServer::ServantManager::_downcast ( - const char* logical_type_id - ) + const char* logical_type_id + ) { if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/ServantManager:1.0") == 0) return ACE_static_cast (POA_PortableServer::ServantManager_ptr, this); @@ -1847,12 +2058,12 @@ void POA_PortableServer::ServantManager::_dispatch (CORBA::ServerRequest &req, v const char *opname = req.operation (); // retrieve operation name // find the skeleton corresponding to this opname if (this->_find (opname, skel) == -1) - { - env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); - ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); - } -else - skel (req, this, context, env); + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); } const char* POA_PortableServer::ServantManager::_interface_repository_id (void) const @@ -1861,9 +2072,9 @@ const char* POA_PortableServer::ServantManager::_interface_repository_id (void) } POA_PortableServer::_tao_collocated_ServantManager::_tao_collocated_ServantManager ( - POA_PortableServer::ServantManager_ptr servant, - STUB_Object *stub - ) + POA_PortableServer::ServantManager_ptr servant, + STUB_Object *stub + ) : ACE_NESTED_CLASS (PortableServer, ServantManager) (stub, servant, CORBA::B_TRUE), CORBA_Object (stub, servant, CORBA::B_TRUE), servant_ (servant) @@ -1876,14 +2087,14 @@ POA_PortableServer::ServantManager_ptr POA_PortableServer::_tao_collocated_Serva } CORBA::Boolean POA_PortableServer::_tao_collocated_ServantManager::_is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_orb_environment - ) + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->_is_a ( - logical_type_id, - _tao_orb_environment - ); + logical_type_id, + _tao_orb_environment + ); } @@ -1912,11 +2123,11 @@ POA_PortableServer::ServantActivator::ServantActivator (void) } void POA_PortableServer::ServantActivator::_is_a_skel ( - CORBA::ServerRequest &_tao_server_request, - void * _tao_object_reference, - void * /*context*/, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_ServantActivator_is_a_paramdata [] = @@ -1930,40 +2141,40 @@ void POA_PortableServer::ServantActivator::_is_a_skel ( CORBA::Boolean _tao_retval; char *_tao_value = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_ServantActivator_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + &PortableServer_ServantActivator_is_a_calldata, + &_tao_retval, + &_tao_value + ); if (_tao_orb_environment.exception () != 0) return; _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_ServantActivator_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_ServantActivator_is_a_calldata, + &_tao_retval, + &_tao_value + ); CORBA::string_free (_tao_value); } CORBA::Boolean POA_PortableServer::ServantActivator::_is_a ( - const char* value, - CORBA::Environment &_tao_orb_environment - ) + const char* value, + CORBA::Environment &_tao_orb_environment + ) { if ( - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ServantActivator:1.0")) || - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ServantManager:1.0")) || - (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) - return CORBA::B_TRUE; - else - return CORBA::B_FALSE; + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ServantActivator:1.0")) || + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ServantManager:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; } void* POA_PortableServer::ServantActivator::_downcast ( - const char* logical_type_id - ) + const char* logical_type_id + ) { if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/ServantActivator:1.0") == 0) return ACE_static_cast (POA_PortableServer::ServantActivator_ptr, this); @@ -1980,12 +2191,12 @@ void POA_PortableServer::ServantActivator::_dispatch (CORBA::ServerRequest &req, const char *opname = req.operation (); // retrieve operation name // find the skeleton corresponding to this opname if (this->_find (opname, skel) == -1) - { - env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); - ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); - } -else - skel (req, this, context, env); + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); } const char* POA_PortableServer::ServantActivator::_interface_repository_id (void) const @@ -1994,9 +2205,9 @@ const char* POA_PortableServer::ServantActivator::_interface_repository_id (void } POA_PortableServer::_tao_collocated_ServantActivator::_tao_collocated_ServantActivator ( - POA_PortableServer::ServantActivator_ptr servant, - STUB_Object *stub - ) + POA_PortableServer::ServantActivator_ptr servant, + STUB_Object *stub + ) : ACE_NESTED_CLASS (PortableServer, ServantActivator) (stub, servant, CORBA::B_TRUE), ACE_NESTED_CLASS (POA_PortableServer, _tao_collocated_ServantManager) (servant, stub), CORBA_Object (stub, servant, CORBA::B_TRUE), @@ -2010,46 +2221,46 @@ POA_PortableServer::ServantActivator_ptr POA_PortableServer::_tao_collocated_Ser } CORBA::Boolean POA_PortableServer::_tao_collocated_ServantActivator::_is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_orb_environment - ) + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->_is_a ( - logical_type_id, - _tao_orb_environment - ); + logical_type_id, + _tao_orb_environment + ); } PortableServer::Servant POA_PortableServer::_tao_collocated_ServantActivator::incarnate ( - const PortableServer::ObjectId & oid, - PortableServer::POA_ptr adapter, - CORBA::Environment &_tao_orb_environment - ) + const PortableServer::ObjectId & oid, + PortableServer::POA_ptr adapter, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->incarnate ( - oid, - adapter, - _tao_orb_environment - ); + oid, + adapter, + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_ServantActivator::etherealize ( - const PortableServer::ObjectId & oid, - PortableServer::POA_ptr adapter, - PortableServer::Servant serv, - CORBA::Boolean cleanup_in_progress, - CORBA::Boolean remaining_activations, - CORBA::Environment &_tao_orb_environment - ) + const PortableServer::ObjectId & oid, + PortableServer::POA_ptr adapter, + PortableServer::Servant serv, + CORBA::Boolean cleanup_in_progress, + CORBA::Boolean remaining_activations, + CORBA::Environment &_tao_orb_environment + ) { this->servant_->etherealize ( - oid, - adapter, - serv, - cleanup_in_progress, - remaining_activations, - _tao_orb_environment - ); + oid, + adapter, + serv, + cleanup_in_progress, + remaining_activations, + _tao_orb_environment + ); } @@ -2078,11 +2289,11 @@ POA_PortableServer::ServantLocator::ServantLocator (void) } void POA_PortableServer::ServantLocator::_is_a_skel ( - CORBA::ServerRequest &_tao_server_request, - void * _tao_object_reference, - void * /*context*/, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_ServantLocator_is_a_paramdata [] = @@ -2096,40 +2307,40 @@ void POA_PortableServer::ServantLocator::_is_a_skel ( CORBA::Boolean _tao_retval; char *_tao_value = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_ServantLocator_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + &PortableServer_ServantLocator_is_a_calldata, + &_tao_retval, + &_tao_value + ); if (_tao_orb_environment.exception () != 0) return; _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_ServantLocator_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_ServantLocator_is_a_calldata, + &_tao_retval, + &_tao_value + ); CORBA::string_free (_tao_value); } CORBA::Boolean POA_PortableServer::ServantLocator::_is_a ( - const char* value, - CORBA::Environment &_tao_orb_environment - ) + const char* value, + CORBA::Environment &_tao_orb_environment + ) { if ( - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ServantLocator:1.0")) || - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ServantManager:1.0")) || - (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) - return CORBA::B_TRUE; - else - return CORBA::B_FALSE; + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ServantLocator:1.0")) || + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/ServantManager:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; } void* POA_PortableServer::ServantLocator::_downcast ( - const char* logical_type_id - ) + const char* logical_type_id + ) { if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/ServantLocator:1.0") == 0) return ACE_static_cast (POA_PortableServer::ServantLocator_ptr, this); @@ -2146,12 +2357,12 @@ void POA_PortableServer::ServantLocator::_dispatch (CORBA::ServerRequest &req, v const char *opname = req.operation (); // retrieve operation name // find the skeleton corresponding to this opname if (this->_find (opname, skel) == -1) - { - env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); - ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); - } -else - skel (req, this, context, env); + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); } const char* POA_PortableServer::ServantLocator::_interface_repository_id (void) const @@ -2160,9 +2371,9 @@ const char* POA_PortableServer::ServantLocator::_interface_repository_id (void) } POA_PortableServer::_tao_collocated_ServantLocator::_tao_collocated_ServantLocator ( - POA_PortableServer::ServantLocator_ptr servant, - STUB_Object *stub - ) + POA_PortableServer::ServantLocator_ptr servant, + STUB_Object *stub + ) : ACE_NESTED_CLASS (PortableServer, ServantLocator) (stub, servant, CORBA::B_TRUE), ACE_NESTED_CLASS (POA_PortableServer, _tao_collocated_ServantManager) (servant, stub), CORBA_Object (stub, servant, CORBA::B_TRUE), @@ -2176,50 +2387,50 @@ POA_PortableServer::ServantLocator_ptr POA_PortableServer::_tao_collocated_Serva } CORBA::Boolean POA_PortableServer::_tao_collocated_ServantLocator::_is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_orb_environment - ) + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->_is_a ( - logical_type_id, - _tao_orb_environment - ); + logical_type_id, + _tao_orb_environment + ); } PortableServer::Servant POA_PortableServer::_tao_collocated_ServantLocator::preinvoke ( - const PortableServer::ObjectId & oid, - PortableServer::POA_ptr adapter, - const char * operation, - PortableServer::ServantLocator::Cookie & the_cookie, - CORBA::Environment &_tao_orb_environment - ) + const PortableServer::ObjectId & oid, + PortableServer::POA_ptr adapter, + const char * operation, + PortableServer::ServantLocator::Cookie & the_cookie, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->preinvoke ( - oid, - adapter, - operation, - the_cookie, - _tao_orb_environment - ); + oid, + adapter, + operation, + the_cookie, + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_ServantLocator::postinvoke ( - const PortableServer::ObjectId & oid, - PortableServer::POA_ptr adapter, - const char * operation, - PortableServer::ServantLocator::Cookie the_cookie, - PortableServer::Servant the_servant, - CORBA::Environment &_tao_orb_environment - ) + const PortableServer::ObjectId & oid, + PortableServer::POA_ptr adapter, + const char * operation, + PortableServer::ServantLocator::Cookie the_cookie, + PortableServer::Servant the_servant, + CORBA::Environment &_tao_orb_environment + ) { this->servant_->postinvoke ( - oid, - adapter, - operation, - the_cookie, - the_servant, - _tao_orb_environment - ); + oid, + adapter, + operation, + the_cookie, + the_servant, + _tao_orb_environment + ); } @@ -2248,11 +2459,11 @@ POA_PortableServer::POA::POA (void) } void POA_PortableServer::POA::_is_a_skel ( - CORBA::ServerRequest &_tao_server_request, - void * _tao_object_reference, - void * /*context*/, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_POA_is_a_paramdata [] = @@ -2266,39 +2477,39 @@ void POA_PortableServer::POA::_is_a_skel ( CORBA::Boolean _tao_retval; char *_tao_value = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_POA_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + &PortableServer_POA_is_a_calldata, + &_tao_retval, + &_tao_value + ); if (_tao_orb_environment.exception () != 0) return; _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_POA_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_POA_is_a_calldata, + &_tao_retval, + &_tao_value + ); CORBA::string_free (_tao_value); } CORBA::Boolean POA_PortableServer::POA::_is_a ( - const char* value, - CORBA::Environment &_tao_orb_environment - ) + const char* value, + CORBA::Environment &_tao_orb_environment + ) { if ( - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/POA:1.0")) || - (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) - return CORBA::B_TRUE; - else - return CORBA::B_FALSE; + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/POA:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; } void* POA_PortableServer::POA::_downcast ( - const char* logical_type_id - ) + const char* logical_type_id + ) { if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/POA:1.0") == 0) return ACE_static_cast (POA_PortableServer::POA_ptr, this); @@ -2313,12 +2524,12 @@ void POA_PortableServer::POA::_dispatch (CORBA::ServerRequest &req, void *contex const char *opname = req.operation (); // retrieve operation name // find the skeleton corresponding to this opname if (this->_find (opname, skel) == -1) - { - env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); - ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); - } -else - skel (req, this, context, env); + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); } const char* POA_PortableServer::POA::_interface_repository_id (void) const @@ -2327,9 +2538,9 @@ const char* POA_PortableServer::POA::_interface_repository_id (void) const } POA_PortableServer::_tao_collocated_POA::_tao_collocated_POA ( - POA_PortableServer::POA_ptr servant, - STUB_Object *stub - ) + POA_PortableServer::POA_ptr servant, + STUB_Object *stub + ) : ACE_NESTED_CLASS (PortableServer, POA) (stub, servant, CORBA::B_TRUE), CORBA_Object (stub, servant, CORBA::B_TRUE), servant_ (servant) @@ -2342,337 +2553,354 @@ POA_PortableServer::POA_ptr POA_PortableServer::_tao_collocated_POA::_get_servan } CORBA::Boolean POA_PortableServer::_tao_collocated_POA::_is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_orb_environment - ) + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->_is_a ( - logical_type_id, - _tao_orb_environment - ); + logical_type_id, + _tao_orb_environment + ); } PortableServer::POA_ptr POA_PortableServer::_tao_collocated_POA::create_POA ( - const char* adapter_name, - PortableServer::POAManager_ptr a_POAManager, - const CORBA::PolicyList & policies, - CORBA::Environment &_tao_orb_environment - ) + const char* adapter_name, + PortableServer::POAManager_ptr a_POAManager, + const CORBA::PolicyList & policies, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->create_POA ( - adapter_name, - a_POAManager, - policies, - _tao_orb_environment - ); + adapter_name, + a_POAManager, + policies, + _tao_orb_environment + ); } PortableServer::POA_ptr POA_PortableServer::_tao_collocated_POA::find_POA ( - const char* adapter_name, - CORBA::Boolean activate_it, - CORBA::Environment &_tao_orb_environment - ) + const char* adapter_name, + CORBA::Boolean activate_it, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->find_POA ( - adapter_name, - activate_it, - _tao_orb_environment - ); + adapter_name, + activate_it, + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_POA::destroy ( - CORBA::Boolean etherealize_objects, - CORBA::Boolean wait_for_completion, - CORBA::Environment &_tao_orb_environment - ) + CORBA::Boolean etherealize_objects, + CORBA::Boolean wait_for_completion, + CORBA::Environment &_tao_orb_environment + ) { this->servant_->destroy ( - etherealize_objects, - wait_for_completion, - _tao_orb_environment - ); + etherealize_objects, + wait_for_completion, + _tao_orb_environment + ); } PortableServer::ThreadPolicy_ptr POA_PortableServer::_tao_collocated_POA::create_thread_policy ( - PortableServer::ThreadPolicyValue value, - CORBA::Environment &_tao_orb_environment - ) + PortableServer::ThreadPolicyValue value, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->create_thread_policy ( - value, - _tao_orb_environment - ); + value, + _tao_orb_environment + ); } PortableServer::LifespanPolicy_ptr POA_PortableServer::_tao_collocated_POA::create_lifespan_policy ( - PortableServer::LifespanPolicyValue value, - CORBA::Environment &_tao_orb_environment - ) + PortableServer::LifespanPolicyValue value, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->create_lifespan_policy ( - value, - _tao_orb_environment - ); + value, + _tao_orb_environment + ); } PortableServer::IdUniquenessPolicy_ptr POA_PortableServer::_tao_collocated_POA::create_id_uniqueness_policy ( - PortableServer::IdUniquenessPolicyValue value, - CORBA::Environment &_tao_orb_environment - ) + PortableServer::IdUniquenessPolicyValue value, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->create_id_uniqueness_policy ( - value, - _tao_orb_environment - ); + value, + _tao_orb_environment + ); } PortableServer::IdAssignmentPolicy_ptr POA_PortableServer::_tao_collocated_POA::create_id_assignment_policy ( - PortableServer::IdAssignmentPolicyValue value, - CORBA::Environment &_tao_orb_environment - ) + PortableServer::IdAssignmentPolicyValue value, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->create_id_assignment_policy ( - value, - _tao_orb_environment - ); + value, + _tao_orb_environment + ); } PortableServer::ImplicitActivationPolicy_ptr POA_PortableServer::_tao_collocated_POA::create_implicit_activation_policy ( - PortableServer::ImplicitActivationPolicyValue value, - CORBA::Environment &_tao_orb_environment - ) + PortableServer::ImplicitActivationPolicyValue value, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->create_implicit_activation_policy ( - value, - _tao_orb_environment - ); + value, + _tao_orb_environment + ); } PortableServer::ServantRetentionPolicy_ptr POA_PortableServer::_tao_collocated_POA::create_servant_retention_policy ( - PortableServer::ServantRetentionPolicyValue value, - CORBA::Environment &_tao_orb_environment - ) + PortableServer::ServantRetentionPolicyValue value, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->create_servant_retention_policy ( - value, - _tao_orb_environment - ); + value, + _tao_orb_environment + ); } PortableServer::RequestProcessingPolicy_ptr POA_PortableServer::_tao_collocated_POA::create_request_processing_policy ( - PortableServer::RequestProcessingPolicyValue value, - CORBA::Environment &_tao_orb_environment - ) + PortableServer::RequestProcessingPolicyValue value, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->create_request_processing_policy ( - value, - _tao_orb_environment - ); + value, + _tao_orb_environment + ); +} + +// ************************************************** +// +// TAO spcific POA locking policy (non-standard) +// +// ************************************************** + +PortableServer::TAO_POA_LockingPolicy_ptr POA_PortableServer::_tao_collocated_POA::create_TAO_POA_locking_policy ( + PortableServer::TAO_POA_LockingPolicyValue value, + CORBA::Environment &_tao_orb_environment + ) +{ + return this->servant_->create_TAO_POA_locking_policy ( + value, + _tao_orb_environment + ); } char* POA_PortableServer::_tao_collocated_POA::the_name ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->the_name(_tao_orb_environment); } PortableServer::POA_ptr POA_PortableServer::_tao_collocated_POA::the_parent ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->the_parent(_tao_orb_environment); } PortableServer::POAManager_ptr POA_PortableServer::_tao_collocated_POA::the_POAManager ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->the_POAManager(_tao_orb_environment); } PortableServer::AdapterActivator_ptr POA_PortableServer::_tao_collocated_POA::the_activator ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->the_activator(_tao_orb_environment); } void POA_PortableServer::_tao_collocated_POA::the_activator ( - PortableServer::AdapterActivator_ptr _tao_value, - CORBA::Environment &_tao_orb_environment - ) + PortableServer::AdapterActivator_ptr _tao_value, + CORBA::Environment &_tao_orb_environment + ) { this->servant_->the_activator ( - _tao_value, - _tao_orb_environment - ); + _tao_value, + _tao_orb_environment + ); } PortableServer::ServantManager_ptr POA_PortableServer::_tao_collocated_POA::get_servant_manager ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->get_servant_manager ( - _tao_orb_environment - ); + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_POA::set_servant_manager ( - PortableServer::ServantManager_ptr imgr, - CORBA::Environment &_tao_orb_environment - ) + PortableServer::ServantManager_ptr imgr, + CORBA::Environment &_tao_orb_environment + ) { this->servant_->set_servant_manager ( - imgr, - _tao_orb_environment - ); + imgr, + _tao_orb_environment + ); } PortableServer::Servant POA_PortableServer::_tao_collocated_POA::get_servant ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->get_servant ( - _tao_orb_environment - ); + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_POA::set_servant ( - PortableServer::Servant p_servant, - CORBA::Environment &_tao_orb_environment - ) + PortableServer::Servant p_servant, + CORBA::Environment &_tao_orb_environment + ) { this->servant_->set_servant ( - p_servant, - _tao_orb_environment - ); + p_servant, + _tao_orb_environment + ); } PortableServer::ObjectId * POA_PortableServer::_tao_collocated_POA::activate_object ( - PortableServer::Servant p_servant, - CORBA::Environment &_tao_orb_environment - ) + PortableServer::Servant p_servant, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->activate_object ( - p_servant, - _tao_orb_environment - ); + p_servant, + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_POA::activate_object_with_id ( - const PortableServer::ObjectId & id, - PortableServer::Servant p_servant, - CORBA::Environment &_tao_orb_environment - ) + const PortableServer::ObjectId & id, + PortableServer::Servant p_servant, + CORBA::Environment &_tao_orb_environment + ) { this->servant_->activate_object_with_id ( - id, - p_servant, - _tao_orb_environment - ); + id, + p_servant, + _tao_orb_environment + ); } void POA_PortableServer::_tao_collocated_POA::deactivate_object ( - const PortableServer::ObjectId & oid, - CORBA::Environment &_tao_orb_environment - ) + const PortableServer::ObjectId & oid, + CORBA::Environment &_tao_orb_environment + ) { this->servant_->deactivate_object ( - oid, - _tao_orb_environment - ); + oid, + _tao_orb_environment + ); } CORBA::Object_ptr POA_PortableServer::_tao_collocated_POA::create_reference ( - const char *intf, - CORBA::Environment &_tao_orb_environment - ) + const char *intf, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->create_reference ( - intf, - _tao_orb_environment - ); + intf, + _tao_orb_environment + ); } CORBA::Object_ptr POA_PortableServer::_tao_collocated_POA::create_reference_with_id ( - const PortableServer::ObjectId & oid, - const char *intf, - CORBA::Environment &_tao_orb_environment - ) + const PortableServer::ObjectId & oid, + const char *intf, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->create_reference_with_id ( - oid, - intf, - _tao_orb_environment - ); + oid, + intf, + _tao_orb_environment + ); } PortableServer::ObjectId * POA_PortableServer::_tao_collocated_POA::servant_to_id ( - PortableServer::Servant p_servant, - CORBA::Environment &_tao_orb_environment - ) + PortableServer::Servant p_servant, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->servant_to_id ( - p_servant, - _tao_orb_environment - ); + p_servant, + _tao_orb_environment + ); } CORBA::Object_ptr POA_PortableServer::_tao_collocated_POA::servant_to_reference ( - PortableServer::Servant p_servant, - CORBA::Environment &_tao_orb_environment - ) + PortableServer::Servant p_servant, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->servant_to_reference ( - p_servant, - _tao_orb_environment - ); + p_servant, + _tao_orb_environment + ); } PortableServer::Servant POA_PortableServer::_tao_collocated_POA::reference_to_servant ( - CORBA::Object_ptr reference, - CORBA::Environment &_tao_orb_environment - ) + CORBA::Object_ptr reference, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->reference_to_servant ( - reference, - _tao_orb_environment - ); + reference, + _tao_orb_environment + ); } PortableServer::ObjectId * POA_PortableServer::_tao_collocated_POA::reference_to_id ( - CORBA::Object_ptr reference, - CORBA::Environment &_tao_orb_environment - ) + CORBA::Object_ptr reference, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->reference_to_id ( - reference, - _tao_orb_environment - ); + reference, + _tao_orb_environment + ); } PortableServer::Servant POA_PortableServer::_tao_collocated_POA::id_to_servant ( - const PortableServer::ObjectId & oid, - CORBA::Environment &_tao_orb_environment - ) + const PortableServer::ObjectId & oid, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->id_to_servant ( - oid, - _tao_orb_environment - ); + oid, + _tao_orb_environment + ); } CORBA::Object_ptr POA_PortableServer::_tao_collocated_POA::id_to_reference ( - const PortableServer::ObjectId & oid, - CORBA::Environment &_tao_orb_environment - ) + const PortableServer::ObjectId & oid, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->id_to_reference ( - oid, - _tao_orb_environment - ); + oid, + _tao_orb_environment + ); } @@ -2703,11 +2931,11 @@ POA_PortableServer::Current::Current (void) } void POA_PortableServer::Current::get_POA_skel ( - CORBA::ServerRequest &_tao_server_request, - void *_tao_object_reference, - void * /* context */, - CORBA::Environment &_tao_orb_environment -) + CORBA::ServerRequest &_tao_server_request, + void *_tao_object_reference, + void * /* context */, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_Current_get_POA_paramdata [] = @@ -2721,28 +2949,28 @@ void POA_PortableServer::Current::get_POA_skel ( POA_PortableServer::Current *_tao_impl = (POA_PortableServer::Current *)_tao_object_reference; CORBA::Object_ptr _tao_retval = CORBA::Object::_nil (); _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_Current_get_POA_calldata, - &_tao_retval - ); + _tao_orb_environment, + &PortableServer_Current_get_POA_calldata, + &_tao_retval + ); if (_tao_orb_environment.exception ()) return; _tao_retval = _tao_impl->get_POA ( - _tao_skel_environment - ); + _tao_skel_environment + ); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_Current_get_POA_calldata, - &_tao_retval - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_Current_get_POA_calldata, + &_tao_retval + ); } void POA_PortableServer::Current::get_object_id_skel ( - CORBA::ServerRequest &_tao_server_request, - void *_tao_object_reference, - void * /* context */, - CORBA::Environment &_tao_orb_environment -) + CORBA::ServerRequest &_tao_server_request, + void *_tao_object_reference, + void * /* context */, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_Current_get_object_id_paramdata [] = @@ -2756,28 +2984,28 @@ void POA_PortableServer::Current::get_object_id_skel ( POA_PortableServer::Current *_tao_impl = (POA_PortableServer::Current *)_tao_object_reference; PortableServer::ObjectId *_tao_retval = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_Current_get_object_id_calldata, - _tao_retval - ); + _tao_orb_environment, + &PortableServer_Current_get_object_id_calldata, + _tao_retval + ); if (_tao_orb_environment.exception ()) return; _tao_retval = _tao_impl->get_object_id ( - _tao_skel_environment - ); + _tao_skel_environment + ); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_Current_get_object_id_calldata, - _tao_retval - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_Current_get_object_id_calldata, + _tao_retval + ); } void POA_PortableServer::Current::_is_a_skel ( - CORBA::ServerRequest &_tao_server_request, - void * _tao_object_reference, - void * /*context*/, - CORBA::Environment &_tao_orb_environment - ) + CORBA::ServerRequest &_tao_server_request, + void * _tao_object_reference, + void * /*context*/, + CORBA::Environment &_tao_orb_environment + ) { CORBA::Environment _tao_skel_environment; static const TAO_Param_Data_Skel PortableServer_Current_is_a_paramdata [] = @@ -2791,40 +3019,40 @@ void POA_PortableServer::Current::_is_a_skel ( CORBA::Boolean _tao_retval; char *_tao_value = 0; _tao_server_request.demarshal ( - _tao_orb_environment, - &PortableServer_Current_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + &PortableServer_Current_is_a_calldata, + &_tao_retval, + &_tao_value + ); if (_tao_orb_environment.exception () != 0) return; _tao_retval = _tao_impl->_is_a (_tao_value, _tao_skel_environment); _tao_server_request.marshal ( - _tao_orb_environment, - _tao_skel_environment, - &PortableServer_Current_is_a_calldata, - &_tao_retval, - &_tao_value - ); + _tao_orb_environment, + _tao_skel_environment, + &PortableServer_Current_is_a_calldata, + &_tao_retval, + &_tao_value + ); CORBA::string_free (_tao_value); } CORBA::Boolean POA_PortableServer::Current::_is_a ( - const char* value, - CORBA::Environment &_tao_orb_environment - ) + const char* value, + CORBA::Environment &_tao_orb_environment + ) { if ( - (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Current:1.0")) || - (!ACE_OS::strcmp ((char *)value, "IDL:CORBA/Current:1.0")) || - (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) - return CORBA::B_TRUE; - else - return CORBA::B_FALSE; + (!ACE_OS::strcmp ((char *)value, "IDL:PortableServer/Current:1.0")) || + (!ACE_OS::strcmp ((char *)value, "IDL:CORBA/Current:1.0")) || + (!ACE_OS::strcmp ((char *)value, CORBA::_tc_Object->id (_tao_orb_environment)))) + return CORBA::B_TRUE; + else + return CORBA::B_FALSE; } void* POA_PortableServer::Current::_downcast ( - const char* logical_type_id - ) + const char* logical_type_id + ) { if (ACE_OS::strcmp (logical_type_id, "IDL:PortableServer/Current:1.0") == 0) return ACE_static_cast (POA_PortableServer::Current_ptr, this); @@ -2841,12 +3069,12 @@ void POA_PortableServer::Current::_dispatch (CORBA::ServerRequest &req, void *co const char *opname = req.operation (); // retrieve operation name // find the skeleton corresponding to this opname if (this->_find (opname, skel) == -1) - { - env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); - ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); - } -else - skel (req, this, context, env); + { + env.exception (new CORBA_BAD_OPERATION (CORBA::COMPLETED_NO)); + ACE_ERROR ((LM_ERROR, "Bad operation <%s>\n", opname)); + } + else + skel (req, this, context, env); } const char* POA_PortableServer::Current::_interface_repository_id (void) const @@ -2855,9 +3083,9 @@ const char* POA_PortableServer::Current::_interface_repository_id (void) const } POA_PortableServer::_tao_collocated_Current::_tao_collocated_Current ( - POA_PortableServer::Current_ptr servant, - STUB_Object *stub - ) + POA_PortableServer::Current_ptr servant, + STUB_Object *stub + ) : ACE_NESTED_CLASS (PortableServer, Current) (stub, servant, CORBA::B_TRUE), ACE_NESTED_CLASS (POA_CORBA,_tao_collocated_Current) (servant, stub), CORBA_Object (stub, servant, CORBA::B_TRUE), @@ -2871,32 +3099,32 @@ POA_PortableServer::Current_ptr POA_PortableServer::_tao_collocated_Current::_ge } CORBA::Boolean POA_PortableServer::_tao_collocated_Current::_is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_orb_environment - ) + const char* logical_type_id, + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->_is_a ( - logical_type_id, - _tao_orb_environment - ); + logical_type_id, + _tao_orb_environment + ); } PortableServer::POA_ptr POA_PortableServer::_tao_collocated_Current::get_POA ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->get_POA ( - _tao_orb_environment - ); + _tao_orb_environment + ); } PortableServer::ObjectId * POA_PortableServer::_tao_collocated_Current::get_object_id ( - CORBA::Environment &_tao_orb_environment - ) + CORBA::Environment &_tao_orb_environment + ) { return this->servant_->get_object_id ( - _tao_orb_environment - ); + _tao_orb_environment + ); } diff --git a/TAO/tao/POAS.h b/TAO/tao/POAS.h index d9fd2ec3808..9ef6d1c3acb 100644 --- a/TAO/tao/POAS.h +++ b/TAO/tao/POAS.h @@ -31,14 +31,14 @@ public: { protected: ThreadPolicy (void); - public: + public: virtual ~ThreadPolicy (void); virtual CORBA::Boolean _is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_environment); + const char* logical_type_id, + CORBA::Environment &_tao_environment); virtual void* _downcast ( - const char* logical_type_id - ); + const char* logical_type_id + ); virtual PortableServer::ThreadPolicyValue value (CORBA::Environment &env) = 0; static void _get_value_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &env); @@ -51,11 +51,11 @@ public: virtual void _dispatch (CORBA::ServerRequest &req, void *context, CORBA::Environment &env); static void _get_policy_type_skel ( - CORBA::ServerRequest &_tao_req, - void *_tao_obj, - void *_tao_context, - CORBA::Environment &_tao_env - ); + CORBA::ServerRequest &_tao_req, + void *_tao_obj, + void *_tao_context, + CORBA::Environment &_tao_env + ); PortableServer::ThreadPolicy *_this (CORBA::Environment &_tao_environment); virtual const char* _interface_repository_id (void) const; @@ -66,30 +66,30 @@ public: #define _PORTABLESERVER_THREADPOLICY___COLLOCATED_SH_ class TAO_Export _tao_collocated_ThreadPolicy : public virtual PortableServer::ThreadPolicy, - public virtual POA_CORBA::_tao_collocated_Policy + public virtual POA_CORBA::_tao_collocated_Policy { public: _tao_collocated_ThreadPolicy ( - ThreadPolicy_ptr servant, - STUB_Object *stub - ); + ThreadPolicy_ptr servant, + STUB_Object *stub + ); ThreadPolicy_ptr _get_servant (void) const; virtual CORBA::Boolean _is_a ( - const char *logical_type_id, - CORBA::Environment &_tao_environment - ); + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); virtual PortableServer::ThreadPolicyValue value ( - CORBA::Environment &env - ); + CORBA::Environment &env + ); virtual CORBA::Policy_ptr copy ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual void destroy ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual CORBA::PolicyType policy_type ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); private: ThreadPolicy_ptr servant_; }; @@ -104,14 +104,14 @@ public: { protected: LifespanPolicy (void); - public: + public: virtual ~LifespanPolicy (void); virtual CORBA::Boolean _is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_environment); + const char* logical_type_id, + CORBA::Environment &_tao_environment); virtual void* _downcast ( - const char* logical_type_id - ); + const char* logical_type_id + ); virtual PortableServer::LifespanPolicyValue value (CORBA::Environment &env) = 0; static void _get_value_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &env); @@ -124,11 +124,11 @@ public: virtual void _dispatch (CORBA::ServerRequest &req, void *context, CORBA::Environment &env); static void _get_policy_type_skel ( - CORBA::ServerRequest &_tao_req, - void *_tao_obj, - void *_tao_context, - CORBA::Environment &_tao_env - ); + CORBA::ServerRequest &_tao_req, + void *_tao_obj, + void *_tao_context, + CORBA::Environment &_tao_env + ); PortableServer::LifespanPolicy *_this (CORBA::Environment &_tao_environment); @@ -140,30 +140,30 @@ public: #define _PORTABLESERVER_LIFESPANPOLICY___COLLOCATED_SH_ class TAO_Export _tao_collocated_LifespanPolicy : public virtual PortableServer::LifespanPolicy, - public virtual POA_CORBA::_tao_collocated_Policy + public virtual POA_CORBA::_tao_collocated_Policy { public: _tao_collocated_LifespanPolicy ( - LifespanPolicy_ptr servant, - STUB_Object *stub - ); + LifespanPolicy_ptr servant, + STUB_Object *stub + ); LifespanPolicy_ptr _get_servant (void) const; virtual CORBA::Boolean _is_a ( - const char *logical_type_id, - CORBA::Environment &_tao_environment - ); + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); virtual PortableServer::LifespanPolicyValue value ( - CORBA::Environment &env - ); + CORBA::Environment &env + ); virtual CORBA::Policy_ptr copy ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual void destroy ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual CORBA::PolicyType policy_type ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); private: LifespanPolicy_ptr servant_; @@ -179,14 +179,14 @@ public: { protected: IdUniquenessPolicy (void); - public: + public: virtual ~IdUniquenessPolicy (void); virtual CORBA::Boolean _is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_environment); + const char* logical_type_id, + CORBA::Environment &_tao_environment); virtual void* _downcast ( - const char* logical_type_id - ); + const char* logical_type_id + ); virtual PortableServer::IdUniquenessPolicyValue value (CORBA::Environment &env) = 0; static void _get_value_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &env); @@ -199,11 +199,11 @@ public: virtual void _dispatch (CORBA::ServerRequest &req, void *context, CORBA::Environment &env); static void _get_policy_type_skel ( - CORBA::ServerRequest &_tao_req, - void *_tao_obj, - void *_tao_context, - CORBA::Environment &_tao_env - ); + CORBA::ServerRequest &_tao_req, + void *_tao_obj, + void *_tao_context, + CORBA::Environment &_tao_env + ); PortableServer::IdUniquenessPolicy *_this (CORBA::Environment &_tao_environment); @@ -215,30 +215,30 @@ public: #define _PORTABLESERVER_IDUNIQUENESSPOLICY___COLLOCATED_SH_ class TAO_Export _tao_collocated_IdUniquenessPolicy : public virtual PortableServer::IdUniquenessPolicy, - public virtual POA_CORBA::_tao_collocated_Policy + public virtual POA_CORBA::_tao_collocated_Policy { public: _tao_collocated_IdUniquenessPolicy ( - IdUniquenessPolicy_ptr servant, - STUB_Object *stub - ); + IdUniquenessPolicy_ptr servant, + STUB_Object *stub + ); IdUniquenessPolicy_ptr _get_servant (void) const; virtual CORBA::Boolean _is_a ( - const char *logical_type_id, - CORBA::Environment &_tao_environment - ); + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); virtual PortableServer::IdUniquenessPolicyValue value ( - CORBA::Environment &env - ); + CORBA::Environment &env + ); virtual CORBA::Policy_ptr copy ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual void destroy ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual CORBA::PolicyType policy_type ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); private: IdUniquenessPolicy_ptr servant_; @@ -254,14 +254,14 @@ public: { protected: IdAssignmentPolicy (void); - public: + public: virtual ~IdAssignmentPolicy (void); virtual CORBA::Boolean _is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_environment); + const char* logical_type_id, + CORBA::Environment &_tao_environment); virtual void* _downcast ( - const char* logical_type_id - ); + const char* logical_type_id + ); virtual PortableServer::IdAssignmentPolicyValue value (CORBA::Environment &env) = 0; static void _get_value_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &env); @@ -274,11 +274,11 @@ public: virtual void _dispatch (CORBA::ServerRequest &req, void *context, CORBA::Environment &env); static void _get_policy_type_skel ( - CORBA::ServerRequest &_tao_req, - void *_tao_obj, - void *_tao_context, - CORBA::Environment &_tao_env - ); + CORBA::ServerRequest &_tao_req, + void *_tao_obj, + void *_tao_context, + CORBA::Environment &_tao_env + ); PortableServer::IdAssignmentPolicy *_this (CORBA::Environment &_tao_environment); @@ -290,30 +290,30 @@ public: #define _PORTABLESERVER_IDASSIGNMENTPOLICY___COLLOCATED_SH_ class TAO_Export _tao_collocated_IdAssignmentPolicy : public virtual PortableServer::IdAssignmentPolicy, - public virtual POA_CORBA::_tao_collocated_Policy + public virtual POA_CORBA::_tao_collocated_Policy { public: _tao_collocated_IdAssignmentPolicy ( - IdAssignmentPolicy_ptr servant, - STUB_Object *stub - ); + IdAssignmentPolicy_ptr servant, + STUB_Object *stub + ); IdAssignmentPolicy_ptr _get_servant (void) const; virtual CORBA::Boolean _is_a ( - const char *logical_type_id, - CORBA::Environment &_tao_environment - ); + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); virtual PortableServer::IdAssignmentPolicyValue value ( - CORBA::Environment &env - ); + CORBA::Environment &env + ); virtual CORBA::Policy_ptr copy ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual void destroy ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual CORBA::PolicyType policy_type ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); private: IdAssignmentPolicy_ptr servant_; @@ -329,14 +329,14 @@ public: { protected: ImplicitActivationPolicy (void); - public: + public: virtual ~ImplicitActivationPolicy (void); virtual CORBA::Boolean _is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_environment); + const char* logical_type_id, + CORBA::Environment &_tao_environment); virtual void* _downcast ( - const char* logical_type_id - ); + const char* logical_type_id + ); virtual PortableServer::ImplicitActivationPolicyValue value (CORBA::Environment &env) = 0; static void _get_value_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &env); @@ -349,11 +349,11 @@ public: virtual void _dispatch (CORBA::ServerRequest &req, void *context, CORBA::Environment &env); static void _get_policy_type_skel ( - CORBA::ServerRequest &_tao_req, - void *_tao_obj, - void *_tao_context, - CORBA::Environment &_tao_env - ); + CORBA::ServerRequest &_tao_req, + void *_tao_obj, + void *_tao_context, + CORBA::Environment &_tao_env + ); PortableServer::ImplicitActivationPolicy *_this (CORBA::Environment &_tao_environment); @@ -365,30 +365,30 @@ public: #define _PORTABLESERVER_IMPLICITACTIVATIONPOLICY___COLLOCATED_SH_ class TAO_Export _tao_collocated_ImplicitActivationPolicy : public virtual PortableServer::ImplicitActivationPolicy, - public virtual POA_CORBA::_tao_collocated_Policy + public virtual POA_CORBA::_tao_collocated_Policy { public: _tao_collocated_ImplicitActivationPolicy ( - ImplicitActivationPolicy_ptr servant, - STUB_Object *stub - ); + ImplicitActivationPolicy_ptr servant, + STUB_Object *stub + ); ImplicitActivationPolicy_ptr _get_servant (void) const; virtual CORBA::Boolean _is_a ( - const char *logical_type_id, - CORBA::Environment &_tao_environment - ); + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); virtual PortableServer::ImplicitActivationPolicyValue value ( - CORBA::Environment &env - ); + CORBA::Environment &env + ); virtual CORBA::Policy_ptr copy ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual void destroy ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual CORBA::PolicyType policy_type ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); private: ImplicitActivationPolicy_ptr servant_; @@ -404,14 +404,14 @@ public: { protected: ServantRetentionPolicy (void); - public: + public: virtual ~ServantRetentionPolicy (void); virtual CORBA::Boolean _is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_environment); + const char* logical_type_id, + CORBA::Environment &_tao_environment); virtual void* _downcast ( - const char* logical_type_id - ); + const char* logical_type_id + ); virtual PortableServer::ServantRetentionPolicyValue value (CORBA::Environment &env) = 0; static void _get_value_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &env); @@ -424,11 +424,11 @@ public: virtual void _dispatch (CORBA::ServerRequest &req, void *context, CORBA::Environment &env); static void _get_policy_type_skel ( - CORBA::ServerRequest &_tao_req, - void *_tao_obj, - void *_tao_context, - CORBA::Environment &_tao_env - ); + CORBA::ServerRequest &_tao_req, + void *_tao_obj, + void *_tao_context, + CORBA::Environment &_tao_env + ); PortableServer::ServantRetentionPolicy *_this (CORBA::Environment &_tao_environment); @@ -440,30 +440,30 @@ public: #define _PORTABLESERVER_SERVANTRETENTIONPOLICY___COLLOCATED_SH_ class TAO_Export _tao_collocated_ServantRetentionPolicy : public virtual PortableServer::ServantRetentionPolicy, - public virtual POA_CORBA::_tao_collocated_Policy + public virtual POA_CORBA::_tao_collocated_Policy { public: _tao_collocated_ServantRetentionPolicy ( - ServantRetentionPolicy_ptr servant, - STUB_Object *stub - ); + ServantRetentionPolicy_ptr servant, + STUB_Object *stub + ); ServantRetentionPolicy_ptr _get_servant (void) const; virtual CORBA::Boolean _is_a ( - const char *logical_type_id, - CORBA::Environment &_tao_environment - ); + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); virtual PortableServer::ServantRetentionPolicyValue value ( - CORBA::Environment &env - ); + CORBA::Environment &env + ); virtual CORBA::Policy_ptr copy ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual void destroy ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual CORBA::PolicyType policy_type ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); private: ServantRetentionPolicy_ptr servant_; @@ -479,14 +479,14 @@ public: { protected: RequestProcessingPolicy (void); - public: + public: virtual ~RequestProcessingPolicy (void); virtual CORBA::Boolean _is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_environment); + const char* logical_type_id, + CORBA::Environment &_tao_environment); virtual void* _downcast ( - const char* logical_type_id - ); + const char* logical_type_id + ); virtual PortableServer::RequestProcessingPolicyValue value (CORBA::Environment &env) = 0; static void _get_value_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &env); @@ -499,11 +499,11 @@ public: virtual void _dispatch (CORBA::ServerRequest &req, void *context, CORBA::Environment &env); static void _get_policy_type_skel ( - CORBA::ServerRequest &_tao_req, - void *_tao_obj, - void *_tao_context, - CORBA::Environment &_tao_env - ); + CORBA::ServerRequest &_tao_req, + void *_tao_obj, + void *_tao_context, + CORBA::Environment &_tao_env + ); PortableServer::RequestProcessingPolicy *_this (CORBA::Environment &_tao_environment); @@ -515,30 +515,30 @@ public: #define _PORTABLESERVER_REQUESTPROCESSINGPOLICY___COLLOCATED_SH_ class TAO_Export _tao_collocated_RequestProcessingPolicy : public virtual PortableServer::RequestProcessingPolicy, - public virtual POA_CORBA::_tao_collocated_Policy + public virtual POA_CORBA::_tao_collocated_Policy { public: _tao_collocated_RequestProcessingPolicy ( - RequestProcessingPolicy_ptr servant, - STUB_Object *stub - ); + RequestProcessingPolicy_ptr servant, + STUB_Object *stub + ); RequestProcessingPolicy_ptr _get_servant (void) const; virtual CORBA::Boolean _is_a ( - const char *logical_type_id, - CORBA::Environment &_tao_environment - ); + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); virtual PortableServer::RequestProcessingPolicyValue value ( - CORBA::Environment &env - ); + CORBA::Environment &env + ); virtual CORBA::Policy_ptr copy ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual void destroy ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual CORBA::PolicyType policy_type ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); private: RequestProcessingPolicy_ptr servant_; @@ -548,20 +548,101 @@ public: #endif // end #if !defined + // ************************************************** + // + // TAO spcific POA locking policy (non-standard) + // + // ************************************************** + + class TAO_POA_LockingPolicy; + typedef TAO_POA_LockingPolicy *TAO_POA_LockingPolicy_ptr; + class TAO_Export TAO_POA_LockingPolicy : public virtual POA_CORBA::Policy + { + protected: + TAO_POA_LockingPolicy (void); + public: + virtual ~TAO_POA_LockingPolicy (void); + virtual CORBA::Boolean _is_a ( + const char* logical_type_id, + CORBA::Environment &_tao_environment); + virtual void* _downcast ( + const char* logical_type_id + ); + virtual PortableServer::TAO_POA_LockingPolicyValue value (CORBA::Environment &env) = 0; + static void _get_value_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &env); + + static void _is_a_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &_tao_enviroment); + + static void copy_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &env); + + static void destroy_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &env); + + virtual void _dispatch (CORBA::ServerRequest &req, void *context, CORBA::Environment &env); + + static void _get_policy_type_skel ( + CORBA::ServerRequest &_tao_req, + void *_tao_obj, + void *_tao_context, + CORBA::Environment &_tao_env + ); + + + PortableServer::TAO_POA_LockingPolicy *_this (CORBA::Environment &_tao_environment); + virtual const char* _interface_repository_id (void) const; + }; + + +#if !defined (_PORTABLESERVER_TAO_POA_LOCKINGPOLICY___COLLOCATED_SH_) +#define _PORTABLESERVER_TAO_POA_LOCKINGPOLICY___COLLOCATED_SH_ + + class TAO_Export _tao_collocated_TAO_POA_LockingPolicy : public virtual PortableServer::TAO_POA_LockingPolicy, + public virtual POA_CORBA::_tao_collocated_Policy + { + public: + _tao_collocated_TAO_POA_LockingPolicy ( + TAO_POA_LockingPolicy_ptr servant, + STUB_Object *stub + ); + TAO_POA_LockingPolicy_ptr _get_servant (void) const; + virtual CORBA::Boolean _is_a ( + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); + virtual PortableServer::TAO_POA_LockingPolicyValue value ( + CORBA::Environment &env + ); + virtual CORBA::Policy_ptr copy ( + CORBA::Environment &_tao_environment + ); + virtual void destroy ( + CORBA::Environment &_tao_environment + ); + virtual CORBA::PolicyType policy_type ( + CORBA::Environment &_tao_environment + ); + + private: + TAO_POA_LockingPolicy_ptr servant_; + }; + + +#endif // end #if !defined + + class POAManager; typedef POAManager *POAManager_ptr; class TAO_Export POAManager : public virtual TAO_Local_ServantBase { protected: POAManager (void); - public: + public: virtual ~POAManager (void); virtual CORBA::Boolean _is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_environment); + const char* logical_type_id, + CORBA::Environment &_tao_environment); virtual void* _downcast ( - const char* logical_type_id - ); + const char* logical_type_id + ); virtual void activate ( CORBA::Environment &env) = 0; // pure virtual virtual void hold_requests (CORBA::Boolean wait_for_completion, CORBA::Environment &env) = 0; // pure virtual @@ -586,30 +667,30 @@ public: { public: _tao_collocated_POAManager ( - POAManager_ptr servant, - STUB_Object *stub - ); + POAManager_ptr servant, + STUB_Object *stub + ); POAManager_ptr _get_servant (void) const; virtual CORBA::Boolean _is_a ( - const char *logical_type_id, - CORBA::Environment &_tao_environment - ); + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); virtual void activate ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual void hold_requests ( - CORBA::Boolean wait_for_completion, - CORBA::Environment &_tao_environment - ); + CORBA::Boolean wait_for_completion, + CORBA::Environment &_tao_environment + ); virtual void discard_requests ( - CORBA::Boolean wait_for_completion, - CORBA::Environment &_tao_environment - ); + CORBA::Boolean wait_for_completion, + CORBA::Environment &_tao_environment + ); virtual void deactivate ( - CORBA::Boolean etherealize_objects, - CORBA::Boolean wait_for_completion, - CORBA::Environment &_tao_environment - ); + CORBA::Boolean etherealize_objects, + CORBA::Boolean wait_for_completion, + CORBA::Environment &_tao_environment + ); private: POAManager_ptr servant_; @@ -625,14 +706,14 @@ public: { protected: AdapterActivator (void); - public: + public: virtual ~AdapterActivator (void); virtual CORBA::Boolean _is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_environment); + const char* logical_type_id, + CORBA::Environment &_tao_environment); virtual void* _downcast ( - const char* logical_type_id - ); + const char* logical_type_id + ); virtual CORBA::Boolean unknown_adapter (PortableServer::POA_ptr parent, const char *name, CORBA::Environment &env) = 0; // pure virtual static void _is_a_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &_tao_enviroment); @@ -651,19 +732,19 @@ public: { public: _tao_collocated_AdapterActivator ( - AdapterActivator_ptr servant, - STUB_Object *stub - ); + AdapterActivator_ptr servant, + STUB_Object *stub + ); AdapterActivator_ptr _get_servant (void) const; virtual CORBA::Boolean _is_a ( - const char *logical_type_id, - CORBA::Environment &_tao_environment - ); + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); virtual CORBA::Boolean unknown_adapter ( - PortableServer::POA_ptr parent, - const char* name, - CORBA::Environment &_tao_environment - ); + PortableServer::POA_ptr parent, + const char* name, + CORBA::Environment &_tao_environment + ); private: AdapterActivator_ptr servant_; @@ -679,14 +760,14 @@ public: { protected: ServantManager (void); - public: + public: virtual ~ServantManager (void); virtual CORBA::Boolean _is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_environment); + const char* logical_type_id, + CORBA::Environment &_tao_environment); virtual void* _downcast ( - const char* logical_type_id - ); + const char* logical_type_id + ); static void _is_a_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &_tao_enviroment); virtual void _dispatch (CORBA::ServerRequest &req, void *context, CORBA::Environment &env); @@ -703,14 +784,14 @@ public: { public: _tao_collocated_ServantManager ( - ServantManager_ptr servant, - STUB_Object *stub - ); + ServantManager_ptr servant, + STUB_Object *stub + ); ServantManager_ptr _get_servant (void) const; virtual CORBA::Boolean _is_a ( - const char *logical_type_id, - CORBA::Environment &_tao_environment - ); + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); private: ServantManager_ptr servant_; @@ -726,14 +807,14 @@ public: { protected: ServantActivator (void); - public: + public: virtual ~ServantActivator (void); virtual CORBA::Boolean _is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_environment); + const char* logical_type_id, + CORBA::Environment &_tao_environment); virtual void* _downcast ( - const char* logical_type_id - ); + const char* logical_type_id + ); virtual PortableServer::Servant incarnate (const PortableServer::ObjectId &oid, PortableServer::POA_ptr adapter, CORBA::Environment &env) = 0; // pure virtual virtual void etherealize (const PortableServer::ObjectId &oid, PortableServer::POA_ptr adapter, PortableServer::Servant serv, CORBA::Boolean cleanup_in_progress, CORBA::Boolean remaining_activations, CORBA::Environment &env) = 0; // pure virtual @@ -751,31 +832,31 @@ public: #define _PORTABLESERVER_SERVANTACTIVATOR___COLLOCATED_SH_ class TAO_Export _tao_collocated_ServantActivator : public virtual PortableServer::ServantActivator, - public virtual _tao_collocated_ServantManager + public virtual _tao_collocated_ServantManager { public: _tao_collocated_ServantActivator ( - ServantActivator_ptr servant, - STUB_Object *stub - ); + ServantActivator_ptr servant, + STUB_Object *stub + ); ServantActivator_ptr _get_servant (void) const; virtual CORBA::Boolean _is_a ( - const char *logical_type_id, - CORBA::Environment &_tao_environment - ); + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); virtual PortableServer::Servant incarnate ( - const PortableServer::ObjectId & oid, - PortableServer::POA_ptr adapter, - CORBA::Environment &_tao_environment - ); + const PortableServer::ObjectId & oid, + PortableServer::POA_ptr adapter, + CORBA::Environment &_tao_environment + ); virtual void etherealize ( - const PortableServer::ObjectId & oid, - PortableServer::POA_ptr adapter, - PortableServer::Servant serv, - CORBA::Boolean cleanup_in_progress, - CORBA::Boolean remaining_activations, - CORBA::Environment &_tao_environment - ); + const PortableServer::ObjectId & oid, + PortableServer::POA_ptr adapter, + PortableServer::Servant serv, + CORBA::Boolean cleanup_in_progress, + CORBA::Boolean remaining_activations, + CORBA::Environment &_tao_environment + ); private: ServantActivator_ptr servant_; @@ -791,14 +872,14 @@ public: { protected: ServantLocator (void); - public: + public: virtual ~ServantLocator (void); virtual CORBA::Boolean _is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_environment); + const char* logical_type_id, + CORBA::Environment &_tao_environment); virtual void* _downcast ( - const char* logical_type_id - ); + const char* logical_type_id + ); virtual PortableServer::Servant preinvoke (const PortableServer::ObjectId &oid, PortableServer::POA_ptr adapter, const char *operation, @@ -820,33 +901,33 @@ public: #define _PORTABLESERVER_SERVANTLOCATOR___COLLOCATED_SH_ class TAO_Export _tao_collocated_ServantLocator : public virtual PortableServer::ServantLocator, - public virtual _tao_collocated_ServantManager + public virtual _tao_collocated_ServantManager { public: _tao_collocated_ServantLocator ( - ServantLocator_ptr servant, - STUB_Object *stub - ); + ServantLocator_ptr servant, + STUB_Object *stub + ); ServantLocator_ptr _get_servant (void) const; virtual CORBA::Boolean _is_a ( - const char *logical_type_id, - CORBA::Environment &_tao_environment - ); + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); virtual PortableServer::Servant preinvoke ( - const PortableServer::ObjectId & oid, - PortableServer::POA_ptr adapter, - const char * operation, - PortableServer::ServantLocator::Cookie & the_cookie, - CORBA::Environment &_tao_environment - ); + const PortableServer::ObjectId & oid, + PortableServer::POA_ptr adapter, + const char * operation, + PortableServer::ServantLocator::Cookie & the_cookie, + CORBA::Environment &_tao_environment + ); virtual void postinvoke ( - const PortableServer::ObjectId & oid, - PortableServer::POA_ptr adapter, - const char * operation, - PortableServer::ServantLocator::Cookie the_cookie, - PortableServer::Servant the_servant, - CORBA::Environment &_tao_environment - ); + const PortableServer::ObjectId & oid, + PortableServer::POA_ptr adapter, + const char * operation, + PortableServer::ServantLocator::Cookie the_cookie, + PortableServer::Servant the_servant, + CORBA::Environment &_tao_environment + ); private: ServantLocator_ptr servant_; @@ -862,14 +943,14 @@ public: { protected: POA (void); - public: + public: virtual ~POA (void); virtual CORBA::Boolean _is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_environment); + const char* logical_type_id, + CORBA::Environment &_tao_environment); virtual void* _downcast ( - const char* logical_type_id - ); + const char* logical_type_id + ); virtual PortableServer::POA_ptr create_POA (const char *adapter_name, PortableServer::POAManager_ptr a_POAManager, const CORBA::PolicyList &policies, CORBA::Environment &env) = 0; // pure virtual virtual PortableServer::POA_ptr find_POA (const char *adapter_name, CORBA::Boolean activate_it, CORBA::Environment &env) = 0; // pure virtual @@ -890,6 +971,14 @@ public: virtual PortableServer::RequestProcessingPolicy_ptr create_request_processing_policy (PortableServer::RequestProcessingPolicyValue value, CORBA::Environment &env) = 0; // pure virtual + // ************************************************** + // + // TAO spcific POA locking policy (non-standard) + // + // ************************************************** + + virtual PortableServer::TAO_POA_LockingPolicy_ptr create_TAO_POA_locking_policy (PortableServer::TAO_POA_LockingPolicyValue value, CORBA::Environment &env) = 0; // pure virtual + virtual char * the_name (CORBA::Environment &env) = 0; virtual PortableServer::POA_ptr the_parent (CORBA::Environment &env) = 0; @@ -946,133 +1035,145 @@ public: { public: _tao_collocated_POA ( - POA_ptr servant, - STUB_Object *stub - ); + POA_ptr servant, + STUB_Object *stub + ); POA_ptr _get_servant (void) const; virtual CORBA::Boolean _is_a ( - const char *logical_type_id, - CORBA::Environment &_tao_environment - ); + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); virtual PortableServer::POA_ptr create_POA ( - const char* adapter_name, - PortableServer::POAManager_ptr a_POAManager, - const CORBA::PolicyList & policies, - CORBA::Environment &_tao_environment - ); + const char* adapter_name, + PortableServer::POAManager_ptr a_POAManager, + const CORBA::PolicyList & policies, + CORBA::Environment &_tao_environment + ); virtual PortableServer::POA_ptr find_POA ( - const char* adapter_name, - CORBA::Boolean activate_it, - CORBA::Environment &_tao_environment - ); + const char* adapter_name, + CORBA::Boolean activate_it, + CORBA::Environment &_tao_environment + ); virtual void destroy ( - CORBA::Boolean etherealize_objects, - CORBA::Boolean wait_for_completion, - CORBA::Environment &_tao_environment - ); + CORBA::Boolean etherealize_objects, + CORBA::Boolean wait_for_completion, + CORBA::Environment &_tao_environment + ); virtual PortableServer::ThreadPolicy_ptr create_thread_policy ( - PortableServer::ThreadPolicyValue value, - CORBA::Environment &_tao_environment - ); + PortableServer::ThreadPolicyValue value, + CORBA::Environment &_tao_environment + ); virtual PortableServer::LifespanPolicy_ptr create_lifespan_policy ( - PortableServer::LifespanPolicyValue value, - CORBA::Environment &_tao_environment - ); + PortableServer::LifespanPolicyValue value, + CORBA::Environment &_tao_environment + ); virtual PortableServer::IdUniquenessPolicy_ptr create_id_uniqueness_policy ( - PortableServer::IdUniquenessPolicyValue value, - CORBA::Environment &_tao_environment - ); + PortableServer::IdUniquenessPolicyValue value, + CORBA::Environment &_tao_environment + ); virtual PortableServer::IdAssignmentPolicy_ptr create_id_assignment_policy ( - PortableServer::IdAssignmentPolicyValue value, - CORBA::Environment &_tao_environment - ); + PortableServer::IdAssignmentPolicyValue value, + CORBA::Environment &_tao_environment + ); virtual PortableServer::ImplicitActivationPolicy_ptr create_implicit_activation_policy ( - PortableServer::ImplicitActivationPolicyValue value, - CORBA::Environment &_tao_environment - ); + PortableServer::ImplicitActivationPolicyValue value, + CORBA::Environment &_tao_environment + ); virtual PortableServer::ServantRetentionPolicy_ptr create_servant_retention_policy ( - PortableServer::ServantRetentionPolicyValue value, - CORBA::Environment &_tao_environment - ); + PortableServer::ServantRetentionPolicyValue value, + CORBA::Environment &_tao_environment + ); virtual PortableServer::RequestProcessingPolicy_ptr create_request_processing_policy ( - PortableServer::RequestProcessingPolicyValue value, - CORBA::Environment &_tao_environment - ); + PortableServer::RequestProcessingPolicyValue value, + CORBA::Environment &_tao_environment + ); + + // ************************************************** + // + // TAO spcific POA locking policy (non-standard) + // + // ************************************************** + + virtual PortableServer::TAO_POA_LockingPolicy_ptr create_TAO_POA_locking_policy ( + PortableServer::TAO_POA_LockingPolicyValue value, + CORBA::Environment &_tao_environment + ); + virtual char* the_name ( - CORBA::Environment &env - ); + CORBA::Environment &env + ); virtual PortableServer::POA_ptr the_parent ( - CORBA::Environment &env - ); + CORBA::Environment &env + ); virtual PortableServer::POAManager_ptr the_POAManager ( - CORBA::Environment &env - ); + CORBA::Environment &env + ); virtual PortableServer::AdapterActivator_ptr the_activator ( - CORBA::Environment &env - ); + CORBA::Environment &env + ); virtual void the_activator (PortableServer::AdapterActivator_ptr _tao_value, - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual PortableServer::ServantManager_ptr get_servant_manager ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual void set_servant_manager ( - PortableServer::ServantManager_ptr imgr, - CORBA::Environment &_tao_environment - ); + PortableServer::ServantManager_ptr imgr, + CORBA::Environment &_tao_environment + ); virtual PortableServer::Servant get_servant ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual void set_servant ( - PortableServer::Servant p_servant, - CORBA::Environment &_tao_environment - ); + PortableServer::Servant p_servant, + CORBA::Environment &_tao_environment + ); virtual PortableServer::ObjectId * activate_object ( - PortableServer::Servant p_servant, - CORBA::Environment &_tao_environment - ); + PortableServer::Servant p_servant, + CORBA::Environment &_tao_environment + ); virtual void activate_object_with_id ( - const PortableServer::ObjectId & id, - PortableServer::Servant p_servant, - CORBA::Environment &_tao_environment - ); + const PortableServer::ObjectId & id, + PortableServer::Servant p_servant, + CORBA::Environment &_tao_environment + ); virtual void deactivate_object ( - const PortableServer::ObjectId & oid, - CORBA::Environment &_tao_environment - ); + const PortableServer::ObjectId & oid, + CORBA::Environment &_tao_environment + ); virtual CORBA::Object_ptr create_reference ( - const char *intf, - CORBA::Environment &_tao_environment - ); + const char *intf, + CORBA::Environment &_tao_environment + ); virtual CORBA::Object_ptr create_reference_with_id ( - const PortableServer::ObjectId & oid, - const char *intf, - CORBA::Environment &_tao_environment - ); + const PortableServer::ObjectId & oid, + const char *intf, + CORBA::Environment &_tao_environment + ); virtual PortableServer::ObjectId * servant_to_id ( - PortableServer::Servant p_servant, - CORBA::Environment &_tao_environment - ); + PortableServer::Servant p_servant, + CORBA::Environment &_tao_environment + ); virtual CORBA::Object_ptr servant_to_reference ( - PortableServer::Servant p_servant, - CORBA::Environment &_tao_environment - ); + PortableServer::Servant p_servant, + CORBA::Environment &_tao_environment + ); virtual PortableServer::Servant reference_to_servant ( - CORBA::Object_ptr reference, - CORBA::Environment &_tao_environment - ); + CORBA::Object_ptr reference, + CORBA::Environment &_tao_environment + ); virtual PortableServer::ObjectId * reference_to_id ( - CORBA::Object_ptr reference, - CORBA::Environment &_tao_environment - ); + CORBA::Object_ptr reference, + CORBA::Environment &_tao_environment + ); virtual PortableServer::Servant id_to_servant ( - const PortableServer::ObjectId & oid, - CORBA::Environment &_tao_environment - ); + const PortableServer::ObjectId & oid, + CORBA::Environment &_tao_environment + ); virtual CORBA::Object_ptr id_to_reference ( - const PortableServer::ObjectId & oid, - CORBA::Environment &_tao_environment - ); + const PortableServer::ObjectId & oid, + CORBA::Environment &_tao_environment + ); private: POA_ptr servant_; @@ -1088,14 +1189,14 @@ public: { protected: Current (void); - public: + public: virtual ~Current (void); virtual CORBA::Boolean _is_a ( - const char* logical_type_id, - CORBA::Environment &_tao_environment); + const char* logical_type_id, + CORBA::Environment &_tao_environment); virtual void* _downcast ( - const char* logical_type_id - ); + const char* logical_type_id + ); virtual PortableServer::POA_ptr get_POA ( CORBA::Environment &env) = 0; // pure virtual static void get_POA_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &env); @@ -1115,24 +1216,24 @@ public: #define _PORTABLESERVER_CURRENT___COLLOCATED_SH_ class TAO_Export _tao_collocated_Current : public virtual PortableServer::Current, - public virtual POA_CORBA::_tao_collocated_Current + public virtual POA_CORBA::_tao_collocated_Current { public: _tao_collocated_Current ( - Current_ptr servant, - STUB_Object *stub - ); + Current_ptr servant, + STUB_Object *stub + ); Current_ptr _get_servant (void) const; virtual CORBA::Boolean _is_a ( - const char *logical_type_id, - CORBA::Environment &_tao_environment - ); + const char *logical_type_id, + CORBA::Environment &_tao_environment + ); virtual PortableServer::POA_ptr get_POA ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); virtual PortableServer::ObjectId * get_object_id ( - CORBA::Environment &_tao_environment - ); + CORBA::Environment &_tao_environment + ); private: Current_ptr servant_; diff --git a/TAO/tao/POAS.i b/TAO/tao/POAS.i index ca38cbb8ce5..e4a2a6e3644 100644 --- a/TAO/tao/POAS.i +++ b/TAO/tao/POAS.i @@ -147,6 +147,34 @@ ACE_INLINE void POA_PortableServer::RequestProcessingPolicy::_get_policy_type_sk POA_CORBA::Policy_ptr impl = (POA_PortableServer::RequestProcessingPolicy_ptr) obj; POA_CORBA::Policy::_get_policy_type_skel (req, (POA_CORBA::Policy_ptr) impl, context, env); } + +// ************************************************** +// +// TAO spcific POA locking policy (non-standard) +// +// ************************************************** + +// skeleton destructor +ACE_INLINE +POA_PortableServer::TAO_POA_LockingPolicy::~TAO_POA_LockingPolicy (void) +{ +} +ACE_INLINE void POA_PortableServer::TAO_POA_LockingPolicy::copy_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &env) +{ + POA_CORBA::Policy_ptr impl = (POA_PortableServer::TAO_POA_LockingPolicy_ptr) obj; + POA_CORBA::Policy::copy_skel (req, (POA_CORBA::Policy_ptr) impl, context, env); +} +ACE_INLINE void POA_PortableServer::TAO_POA_LockingPolicy::destroy_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &env) +{ + POA_CORBA::Policy_ptr impl = (POA_PortableServer::TAO_POA_LockingPolicy_ptr) obj; + POA_CORBA::Policy::destroy_skel (req, (POA_CORBA::Policy_ptr) impl, context, env); +} +ACE_INLINE void POA_PortableServer::TAO_POA_LockingPolicy::_get_policy_type_skel (CORBA::ServerRequest &req, void *obj, void *context, CORBA::Environment &env) +{ + POA_CORBA::Policy_ptr impl = (POA_PortableServer::TAO_POA_LockingPolicy_ptr) obj; + POA_CORBA::Policy::_get_policy_type_skel (req, (POA_CORBA::Policy_ptr) impl, context, env); +} + // skeleton destructor ACE_INLINE POA_PortableServer::POAManager::~POAManager (void) diff --git a/TAO/tao/Principal.i b/TAO/tao/Principal.i new file mode 100644 index 00000000000..74e88caa0c5 --- /dev/null +++ b/TAO/tao/Principal.i @@ -0,0 +1,2 @@ +// $Id$ + diff --git a/TAO/tao/Sequence.h b/TAO/tao/Sequence.h index dd92c0d5616..f89606cc3ec 100644 --- a/TAO/tao/Sequence.h +++ b/TAO/tao/Sequence.h @@ -439,14 +439,6 @@ public: // Replaces the current buffer with <mb>, using only <length> bytes. // It takes a duplicate of <mb>. - friend TAO_OutputCDR& - operator <<(TAO_OutputCDR&, - const TAO_Unbounded_Sequence<CORBA::Octet>&); - - friend TAO_InputCDR& - operator <<(TAO_InputCDR&, - TAO_Unbounded_Sequence<CORBA::Octet>&); - private: ACE_Message_Block* mb_; }; diff --git a/TAO/tests/POA/NewPOA/NewPOA.cpp b/TAO/tests/POA/NewPOA/NewPOA.cpp index 9d06f61532c..a243ca3cfc9 100644 --- a/TAO/tests/POA/NewPOA/NewPOA.cpp +++ b/TAO/tests/POA/NewPOA/NewPOA.cpp @@ -43,7 +43,7 @@ main (int argc, char **argv) // _narrow() the Object to get the POA object, i.e., the root_poa. PortableServer::POA_var root_poa = - PortableServer::POA::_narrow (obj.in(), env); + PortableServer::POA::_narrow (obj.in (), env); if (env.exception () != 0) { @@ -79,7 +79,7 @@ main (int argc, char **argv) ACE_CString name = "firstPOA"; PortableServer::POA_var first_poa = root_poa->create_POA (name.c_str (), - PortableServer::POAManager::_nil(), + PortableServer::POAManager::_nil (), policies, env); if (env.exception () != 0) @@ -93,7 +93,7 @@ main (int argc, char **argv) name += "secondPOA"; PortableServer::POA_var second_poa = root_poa->create_POA (name.c_str (), - PortableServer::POAManager::_nil(), + PortableServer::POAManager::_nil (), policies, env); if (env.exception () != 0) @@ -112,7 +112,7 @@ main (int argc, char **argv) PortableServer::POA_var fifth_poa = root_poa->create_POA (name.c_str (), - PortableServer::POAManager::_nil(), + PortableServer::POAManager::_nil (), policies, env); if (env.exception () != 0) diff --git a/TAO/tests/POA/locking/Makefile b/TAO/tests/POA/locking/Makefile new file mode 100644 index 00000000000..572beb3946e --- /dev/null +++ b/TAO/tests/POA/locking/Makefile @@ -0,0 +1,229 @@ +# +# $Id$ +# + +ifndef TAO_ROOT + TAO_ROOT = $(ACE_ROOT)/TAO +endif # ! TAO_ROOT + +BIN = locking + +LSRC = $(addsuffix .cpp,$(BIN)) + +CPPFLAGS += -I$(TAO_ROOT) + +LDLIBS = -lTAO +LDFLAGS += -L$(TAO_ROOT)/tao + +VLDLIBS = $(LDLIBS:%=%$(VAR)) + +BUILD = $(VBIN) + +INSTALL = + +#---------------------------------------------------------------------------- +# Include macros and targets +#---------------------------------------------------------------------------- + +include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU +include $(ACE_ROOT)/include/makeinclude/macros.GNU +include $(TAO_ROOT)/rules.tao.GNU +include $(ACE_ROOT)/include/makeinclude/rules.common.GNU +include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU +include $(ACE_ROOT)/include/makeinclude/rules.bin.GNU +include $(ACE_ROOT)/include/makeinclude/rules.local.GNU + +#---------------------------------------------------------------------------- +# Dependencies +#---------------------------------------------------------------------------- + +# DO NOT DELETE THIS LINE -- g++dep uses it. +# DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY. + +.obj/locking.o .obj/locking.so .shobj/locking.o .shobj/locking.so: locking.cpp \ + $(ACE_ROOT)/ace/streams.h \ + $(ACE_ROOT)/ace/inc_user_config.h \ + $(ACE_ROOT)/ace/config.h \ + $(TAO_ROOT)/tao/corba.h \ + $(TAO_ROOT)/tao/orbconf.h \ + $(ACE_ROOT)/ace/OS.h \ + $(ACE_ROOT)/ace/Basic_Types.h \ + $(ACE_ROOT)/ace/Basic_Types.i \ + $(ACE_ROOT)/ace/OS.i \ + $(ACE_ROOT)/ace/Trace.h \ + $(ACE_ROOT)/ace/Log_Msg.h \ + $(ACE_ROOT)/ace/Log_Record.h \ + $(ACE_ROOT)/ace/ACE.h \ + $(ACE_ROOT)/ace/ACE.i \ + $(ACE_ROOT)/ace/Log_Priority.h \ + $(ACE_ROOT)/ace/Log_Record.i \ + $(ACE_ROOT)/ace/Get_Opt.h \ + $(ACE_ROOT)/ace/Get_Opt.i \ + $(ACE_ROOT)/ace/SOCK_Stream.h \ + $(ACE_ROOT)/ace/SOCK_IO.h \ + $(ACE_ROOT)/ace/SOCK.h \ + $(ACE_ROOT)/ace/Addr.h \ + $(ACE_ROOT)/ace/Addr.i \ + $(ACE_ROOT)/ace/IPC_SAP.h \ + $(ACE_ROOT)/ace/IPC_SAP.i \ + $(ACE_ROOT)/ace/SOCK.i \ + $(ACE_ROOT)/ace/SOCK_IO.i \ + $(ACE_ROOT)/ace/INET_Addr.h \ + $(ACE_ROOT)/ace/INET_Addr.i \ + $(ACE_ROOT)/ace/SOCK_Stream.i \ + $(ACE_ROOT)/ace/Synch_T.h \ + $(ACE_ROOT)/ace/Event_Handler.h \ + $(ACE_ROOT)/ace/Event_Handler.i \ + $(ACE_ROOT)/ace/Synch.h \ + $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ + $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ + $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ + $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ + $(ACE_ROOT)/ace/Synch.i \ + $(ACE_ROOT)/ace/Synch_T.i \ + $(ACE_ROOT)/ace/Thread.h \ + $(ACE_ROOT)/ace/Thread.i \ + $(ACE_ROOT)/ace/Atomic_Op.i \ + $(ACE_ROOT)/ace/Hash_Map_Manager.h \ + $(ACE_ROOT)/ace/SString.h \ + $(ACE_ROOT)/ace/SString.i \ + $(ACE_ROOT)/ace/Malloc.h \ + $(ACE_ROOT)/ace/Malloc.i \ + $(ACE_ROOT)/ace/Malloc_T.h \ + $(ACE_ROOT)/ace/Free_List.h \ + $(ACE_ROOT)/ace/Free_List.i \ + $(ACE_ROOT)/ace/Malloc_T.i \ + $(ACE_ROOT)/ace/Memory_Pool.h \ + $(ACE_ROOT)/ace/Signal.h \ + $(ACE_ROOT)/ace/Containers.h \ + $(ACE_ROOT)/ace/Containers.i \ + $(ACE_ROOT)/ace/Signal.i \ + $(ACE_ROOT)/ace/Object_Manager.h \ + $(ACE_ROOT)/ace/Object_Manager.i \ + $(ACE_ROOT)/ace/Managed_Object.h \ + $(ACE_ROOT)/ace/Managed_Object.i \ + $(ACE_ROOT)/ace/Mem_Map.h \ + $(ACE_ROOT)/ace/Mem_Map.i \ + $(ACE_ROOT)/ace/Memory_Pool.i \ + $(ACE_ROOT)/ace/SOCK_Acceptor.h \ + $(ACE_ROOT)/ace/Time_Value.h \ + $(ACE_ROOT)/ace/SOCK_Acceptor.i \ + $(ACE_ROOT)/ace/SOCK_Connector.h \ + $(ACE_ROOT)/ace/SOCK_Connector.i \ + $(ACE_ROOT)/ace/Strategies.h \ + $(ACE_ROOT)/ace/Strategies_T.h \ + $(ACE_ROOT)/ace/Service_Config.h \ + $(ACE_ROOT)/ace/Service_Object.h \ + $(ACE_ROOT)/ace/Shared_Object.h \ + $(ACE_ROOT)/ace/Shared_Object.i \ + $(ACE_ROOT)/ace/Service_Object.i \ + $(ACE_ROOT)/ace/Service_Config.i \ + $(ACE_ROOT)/ace/Reactor.h \ + $(ACE_ROOT)/ace/Handle_Set.h \ + $(ACE_ROOT)/ace/Handle_Set.i \ + $(ACE_ROOT)/ace/Timer_Queue.h \ + $(ACE_ROOT)/ace/Timer_Queue_T.h \ + $(ACE_ROOT)/ace/Timer_Queue_T.i \ + $(ACE_ROOT)/ace/Reactor.i \ + $(ACE_ROOT)/ace/Reactor_Impl.h \ + $(ACE_ROOT)/ace/Svc_Conf_Tokens.h \ + $(ACE_ROOT)/ace/Synch_Options.h \ + $(ACE_ROOT)/ace/Synch_Options.i \ + $(ACE_ROOT)/ace/Strategies_T.i \ + $(ACE_ROOT)/ace/Strategies.i \ + $(ACE_ROOT)/ace/Connector.h \ + $(ACE_ROOT)/ace/Map_Manager.h \ + $(ACE_ROOT)/ace/Map_Manager.i \ + $(ACE_ROOT)/ace/Svc_Handler.h \ + $(ACE_ROOT)/ace/Task.h \ + $(ACE_ROOT)/ace/Thread_Manager.h \ + $(ACE_ROOT)/ace/Thread_Manager.i \ + $(ACE_ROOT)/ace/Task.i \ + $(ACE_ROOT)/ace/Task_T.h \ + $(ACE_ROOT)/ace/Message_Queue.h \ + $(ACE_ROOT)/ace/Message_Block.h \ + $(ACE_ROOT)/ace/Message_Block.i \ + $(ACE_ROOT)/ace/IO_Cntl_Msg.h \ + $(ACE_ROOT)/ace/Message_Queue.i \ + $(ACE_ROOT)/ace/Task_T.i \ + $(ACE_ROOT)/ace/Dynamic.h \ + $(ACE_ROOT)/ace/Dynamic.i \ + $(ACE_ROOT)/ace/Singleton.h \ + $(ACE_ROOT)/ace/Singleton.i \ + $(ACE_ROOT)/ace/Svc_Handler.i \ + $(ACE_ROOT)/ace/Connector.i \ + $(ACE_ROOT)/ace/Acceptor.h \ + $(ACE_ROOT)/ace/Acceptor.i \ + $(TAO_ROOT)/tao/compat/objbase.h \ + $(TAO_ROOT)/tao/compat/initguid.h \ + $(TAO_ROOT)/tao/Align.h \ + $(TAO_ROOT)/tao/ORB.h \ + $(TAO_ROOT)/tao/Sequence.h \ + $(TAO_ROOT)/tao/Sequence.i \ + $(TAO_ROOT)/tao/Sequence_T.h \ + $(TAO_ROOT)/tao/Sequence_T.i \ + $(TAO_ROOT)/tao/Object_KeyC.h \ + $(TAO_ROOT)/tao/Object_KeyC.i \ + $(TAO_ROOT)/tao/ORB.i \ + $(TAO_ROOT)/tao/Exception.h \ + $(TAO_ROOT)/tao/Exception.i \ + $(TAO_ROOT)/tao/Any.h \ + $(TAO_ROOT)/tao/Any.i \ + $(TAO_ROOT)/tao/params.h \ + $(TAO_ROOT)/tao/params.i \ + $(TAO_ROOT)/tao/Client_Strategy_Factory.h \ + $(TAO_ROOT)/tao/Server_Strategy_Factory.h \ + $(TAO_ROOT)/tao/default_client.h \ + $(TAO_ROOT)/tao/default_client.i \ + $(TAO_ROOT)/tao/default_server.h \ + $(TAO_ROOT)/tao/ORB_Strategies_T.h \ + $(TAO_ROOT)/tao/ORB_Strategies_T.i \ + $(TAO_ROOT)/tao/default_server.i \ + $(TAO_ROOT)/tao/NVList.h \ + $(TAO_ROOT)/tao/NVList.i \ + $(TAO_ROOT)/tao/Principal.h \ + $(TAO_ROOT)/tao/Request.h \ + $(TAO_ROOT)/tao/Request.i \ + $(TAO_ROOT)/tao/Stub.h \ + $(TAO_ROOT)/tao/Stub.i \ + $(TAO_ROOT)/tao/Object.h \ + $(TAO_ROOT)/tao/Object.i \ + $(TAO_ROOT)/tao/Typecode.h \ + $(TAO_ROOT)/tao/Typecode.i \ + $(TAO_ROOT)/tao/Marshal.h \ + $(TAO_ROOT)/tao/Marshal.i \ + $(TAO_ROOT)/tao/CDR.h \ + $(TAO_ROOT)/tao/CDR.i \ + $(TAO_ROOT)/tao/PolicyC.h \ + $(TAO_ROOT)/tao/PolicyC.i \ + $(TAO_ROOT)/tao/CurrentC.h \ + $(TAO_ROOT)/tao/CurrentC.i \ + $(TAO_ROOT)/tao/POA.h \ + $(TAO_ROOT)/tao/POAC.h \ + $(TAO_ROOT)/tao/POAC.i \ + $(TAO_ROOT)/tao/Servant_Base.h \ + $(TAO_ROOT)/tao/POAS.h \ + $(TAO_ROOT)/tao/POA_CORBA.h \ + $(TAO_ROOT)/tao/POAS.i \ + $(TAO_ROOT)/tao/Object_Table.h \ + $(TAO_ROOT)/tao/POA.i \ + $(TAO_ROOT)/tao/poa_macros.h \ + $(TAO_ROOT)/tao/Connect.h \ + $(TAO_ROOT)/tao/Connect.i \ + $(TAO_ROOT)/tao/ORB_Core.h \ + $(TAO_ROOT)/tao/ORB_Core.i \ + $(ACE_ROOT)/ace/Dynamic_Service.h \ + $(TAO_ROOT)/tao/Operation_Table.h \ + $(TAO_ROOT)/tao/debug.h \ + $(TAO_ROOT)/tao/IIOP_Object.h \ + $(TAO_ROOT)/tao/IIOP_Object.i \ + $(TAO_ROOT)/tao/IIOP_ORB.h \ + $(TAO_ROOT)/tao/IIOP_ORB.i \ + $(TAO_ROOT)/tao/IIOP_Interpreter.h \ + $(TAO_ROOT)/tao/GIOP.h \ + $(TAO_ROOT)/tao/GIOP.i \ + $(TAO_ROOT)/tao/Server_Request.h \ + $(TAO_ROOT)/tao/Server_Request.i \ + $(TAO_ROOT)/tao/singletons.h + +# IF YOU PUT ANYTHING HERE IT WILL GO AWAY diff --git a/TAO/tests/POA/locking/locking.cpp b/TAO/tests/POA/locking/locking.cpp new file mode 100644 index 00000000000..71ef8785301 --- /dev/null +++ b/TAO/tests/POA/locking/locking.cpp @@ -0,0 +1,158 @@ +// $Id$ + +// ================================================== +// = LIBRARY +// TAO/tests/POA/NewPOA +// +// = FILENAME +// NewPOA.cpp +// +// = DESCRIPTION +// +// This program demonstrates creation of new POAs using TAO +// specific locking policies +// +// = AUTHOR +// Irfan Pyarali +// ================================================== + +#include "ace/streams.h" +#include "tao/corba.h" + +int +main (int argc, char **argv) +{ + CORBA::Environment env; + + // The first step Initialize the ORB + CORBA::ORB_var orb = CORBA::ORB_init (argc, argv, 0, env); + if (env.exception () != 0) + { + env.print_exception ("CORBA::ORB_init"); + return -1; + } + + // Obtain the object reference to the RootPOA. + CORBA::Object_var obj = + orb->resolve_initial_references ("RootPOA"); + + // _narrow () the Object to get the POA object, i.e., the root_poa. + PortableServer::POA_var root_poa = + PortableServer::POA::_narrow (obj.in (), env); + + if (env.exception () != 0) + { + env.print_exception ("PortableServer::POA::_narrow"); + return -1; + } + + // Policies for the new POAs + CORBA::PolicyList policies (1); + policies.length (1); + + // TAO specific threading policy + policies[0] = + root_poa->create_TAO_POA_locking_policy (PortableServer::USE_THREAD_LOCK, env); + + if (env.exception () != 0) + { + env.print_exception ("create_TAO_POA_locking"); + return -1; + } + + // Creation of the firstPOA + ACE_CString name = "firstPOA"; + PortableServer::POA_var first_poa = + root_poa->create_POA (name.c_str (), + PortableServer::POAManager::_nil (), + policies, + env); + if (env.exception () != 0) + { + env.print_exception ("PortableServer::POA::create_POA"); + return -1; + } + + // TAO specific threading policy + policies[0] = + root_poa->create_TAO_POA_locking_policy (PortableServer::USE_NULL_LOCK, env); + + if (env.exception () != 0) + { + env.print_exception ("create_TAO_POA_locking"); + return -1; + } + + // Creation of the new POA, i.e. firstPOA/secondPOA + name += TAO_POA::name_separator (); + name += "secondPOA"; + PortableServer::POA_var second_poa = + root_poa->create_POA (name.c_str (), + PortableServer::POAManager::_nil (), + policies, + env); + if (env.exception () != 0) + { + env.print_exception ("PortableServer::POA::create_POA"); + return -1; + } + + // Creation of the new POAs over, so destroy the Policy_ptr's. + for (CORBA::ULong i = 0; + i < policies.length () && env.exception () == 0; + ++i) + { + CORBA::Policy_ptr policy = policies[i]; + policy->destroy (env); + } + + if (env.exception () != 0) + { + env.print_exception ("PortableServer::POA::create_POA"); + return -1; + } + + // Get the names of all the POAs and print them out. + + CORBA::String_var root_poa_name = + root_poa->the_name (env); + if (env.exception () != 0) + { + env.print_exception ("PortableServer::POA::_narrow"); + return -1; + } + + CORBA::String_var first_poa_name = + first_poa->the_name (env); + if (env.exception () != 0) + { + env.print_exception ("PortableServer::POA::_narrow"); + return -1; + } + + CORBA::String_var second_poa_name = + second_poa->the_name (env); + if (env.exception () != 0) + { + env.print_exception ("PortableServer::POA::_narrow"); + return -1; + } + + ACE_DEBUG ((LM_DEBUG, + "%s\n%s\n%s\n", + root_poa_name.in (), + first_poa_name.in (), + second_poa_name.in ())); + + // This should destroy all its children + root_poa->destroy (CORBA::B_TRUE, + CORBA::B_TRUE, + env); + if (env.exception () != 0) + { + env.print_exception ("PortableServer::POA::destroy"); + return -1; + } + + return 0; +} diff --git a/TAO/tests/POA/locking/locking.dsp b/TAO/tests/POA/locking/locking.dsp new file mode 100644 index 00000000000..9bb14e7b461 --- /dev/null +++ b/TAO/tests/POA/locking/locking.dsp @@ -0,0 +1,91 @@ +# Microsoft Developer Studio Project File - Name="locking" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 5.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Console Application" 0x0103
+
+CFG=locking - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE
+!MESSAGE NMAKE /f "locking.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "locking.mak" CFG="locking - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "locking - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "locking - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
+
+# Begin Project
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "locking - Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir ""
+# PROP Intermediate_Dir "Release"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\.." /I "..\..\..\.." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD BASE RSC /l 0x409 /d "NDEBUG"
+# ADD RSC /l 0x409 /d "NDEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LINK32=link.exe
+# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
+# ADD LINK32 tao.lib ace.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\..\tao" /libpath:"..\..\..\..\ace"
+# SUBTRACT LINK32 /pdb:none
+
+!ELSEIF "$(CFG)" == "locking - Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir ""
+# PROP Intermediate_Dir "Debug"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "..\..\.." /I "..\..\..\.." /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
+# ADD BASE RSC /l 0x409 /d "_DEBUG"
+# ADD RSC /l 0x409 /d "_DEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LINK32=link.exe
+# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
+# ADD LINK32 aced.lib tao.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\..\tao" /libpath:"..\..\..\..\ace"
+# SUBTRACT LINK32 /pdb:none
+
+!ENDIF
+
+# Begin Target
+
+# Name "locking - Win32 Release"
+# Name "locking - Win32 Debug"
+# Begin Source File
+
+SOURCE=.\locking.cpp
+# End Source File
+# End Target
+# End Project
diff --git a/TAO/tests/POA/locking/locking.dsw b/TAO/tests/POA/locking/locking.dsw new file mode 100644 index 00000000000..5902fe2a1f2 --- /dev/null +++ b/TAO/tests/POA/locking/locking.dsw @@ -0,0 +1,29 @@ +Microsoft Developer Studio Workspace File, Format Version 5.00
+# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
+
+###############################################################################
+
+Project: "locking"=.\locking.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+}}}
+
+###############################################################################
+
+Global:
+
+Package=<5>
+{{{
+}}}
+
+Package=<3>
+{{{
+}}}
+
+###############################################################################
+
|