3 // ===================================================================
5 * @file Connector_Impl.h
7 * @author Balachandran Natarajan <bala@cs.wustl.edu>
9 // ===================================================================
11 #ifndef TAO_CONNECTOR_IMPL_H
12 #define TAO_CONNECTOR_IMPL_H
14 #include /**/ "ace/pre.h"
15 #include "ace/Strategies_T.h"
17 #if !defined (ACE_LACKS_PRAGMA_ONCE)
19 #endif /* ACE_LACKS_PRAGMA_ONCE */
21 #include "tao/Basic_Types.h"
23 ACE_BEGIN_VERSIONED_NAMESPACE_DECL
24 class ACE_Thread_Manager
;
25 ACE_END_VERSIONED_NAMESPACE_DECL
27 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
32 * @class TAO_Connect_Creation_Strategy
34 * @brief Creation strategy helper
36 * Creates the TAO_*_Connection_Handler object for the TAO_*_Connector
37 * objects. This template class can now be used by all the Connector
38 * objects instead of having to duplicate code. This class can be used
39 * to set any required properties on the connection handlers at
43 template <class SVC_HANDLER
>
44 class TAO_Connect_Creation_Strategy
: public ACE_Creation_Strategy
<SVC_HANDLER
>
48 TAO_Connect_Creation_Strategy (ACE_Thread_Manager
* = 0,
49 TAO_ORB_Core
* orb_core
= 0);
51 /// Makes TAO_*_Client_Connection_Handlers
52 virtual int make_svc_handler (SVC_HANDLER
*&sh
);
56 /// Pointer to the ORB_Core on which we are activated
57 TAO_ORB_Core
* const orb_core_
;
63 * @class TAO_Connect_Concurrency_Strategy
65 * @brief Concurrency strategy helper
67 * Activates the Svc_Handler, and then if the correct wait strategy is
68 * in use registers the handler with the reactor.
71 template <class SVC_HANDLER
>
72 class TAO_Connect_Concurrency_Strategy
:
73 public ACE_Concurrency_Strategy
<SVC_HANDLER
>
77 TAO_Connect_Concurrency_Strategy (TAO_ORB_Core
*orb_core
);
80 /// Activates the Svc_Handler, and if the right wait strategy is in
81 /// use, registers the handle with the reactor.
82 int activate_svc_handler (SVC_HANDLER
*svc_handler
, void *arg
);
85 /// Pointer to the ORB Core.
86 TAO_ORB_Core
* const orb_core_
;
89 TAO_END_VERSIONED_NAMESPACE_DECL
92 #if defined (ACE_TEMPLATES_REQUIRE_SOURCE)
93 #include "tao/Connector_Impl.cpp"
94 #endif /* ACE_TEMPLATES_REQUIRE_SOURCE */
96 #if defined (ACE_TEMPLATES_REQUIRE_PRAGMA)
97 #pragma implementation ("Connector_Impl.cpp")
98 #endif /* ACE_TEMPLATES_REQUIRE_PRAGMA */
100 #include /**/ "ace/post.h"
101 #endif /*TAO_CONNECTOR_IMPL_H*/