RT_Protocols_Hooks.h

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 
00003 // ===================================================================
00004 /**
00005  *  @file   RT_Protocols_Hooks.h
00006  *
00007  *  RT_Protocols_Hooks.h,v 1.18 2006/03/10 07:19:16 jtc Exp
00008  *
00009  *  @author Priyanka Gontla <pgontla@ece.uci.edu>
00010  */
00011 // ===================================================================
00012 
00013 #ifndef TAO_RT_PROTOCOLS_HOOKS_H
00014 #define TAO_RT_PROTOCOLS_HOOKS_H
00015 
00016 #include /**/ "ace/pre.h"
00017 
00018 #include "tao/orbconf.h"
00019 
00020 #if defined (TAO_HAS_CORBA_MESSAGING) && TAO_HAS_CORBA_MESSAGING != 0
00021 
00022 #include "tao/RTCORBA/Priority_Mapping_Manager.h"
00023 #include "tao/RTCORBA/Network_Priority_Mapping_Manager.h"
00024 
00025 #include "tao/Protocols_Hooks.h"
00026 
00027 #include "ace/Service_Config.h"
00028 
00029 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00030 # pragma once
00031 #endif /* ACE_LACKS_PRAGMA_ONCE */
00032 
00033 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00034 
00035 class TAO_RTCORBA_Export TAO_RT_Protocols_Hooks : public TAO_Protocols_Hooks
00036 {
00037 public:
00038 
00039   /// Constructor
00040   TAO_RT_Protocols_Hooks (void);
00041 
00042   /// Destructor
00043   virtual ~TAO_RT_Protocols_Hooks (void);
00044 
00045   /// Initialize the protocols hooks instance.
00046   void init_hooks (TAO_ORB_Core *orb_core
00047                    ACE_ENV_ARG_DECL);
00048 
00049   CORBA::Boolean set_client_network_priority (IOP::ProfileId protocol_tag,
00050                                               TAO_Stub *stub
00051                                               ACE_ENV_ARG_DECL);
00052 
00053   CORBA::Boolean set_server_network_priority (IOP::ProfileId protocol_tag,
00054                                               CORBA::Policy *policy
00055                                               ACE_ENV_ARG_DECL);
00056 
00057   void server_protocol_properties_at_orb_level (TAO_IIOP_Protocol_Properties &protocol_properties
00058                                                 ACE_ENV_ARG_DECL);
00059 
00060   void client_protocol_properties_at_orb_level (TAO_IIOP_Protocol_Properties &protocol_properties
00061                                                 ACE_ENV_ARG_DECL);
00062 
00063   void server_protocol_properties_at_orb_level (TAO_UIOP_Protocol_Properties &protocol_properties
00064                                                 ACE_ENV_ARG_DECL);
00065 
00066   void client_protocol_properties_at_orb_level (TAO_UIOP_Protocol_Properties &protocol_properties
00067                                                 ACE_ENV_ARG_DECL);
00068 
00069   void server_protocol_properties_at_orb_level (TAO_SHMIOP_Protocol_Properties &protocol_properties
00070                                                 ACE_ENV_ARG_DECL);
00071 
00072   void client_protocol_properties_at_orb_level (TAO_SHMIOP_Protocol_Properties &protocol_properties
00073                                                 ACE_ENV_ARG_DECL);
00074 
00075   void server_protocol_properties_at_orb_level (TAO_DIOP_Protocol_Properties &protocol_properties
00076                                                 ACE_ENV_ARG_DECL);
00077 
00078   void client_protocol_properties_at_orb_level (TAO_DIOP_Protocol_Properties &protocol_properties
00079                                                 ACE_ENV_ARG_DECL);
00080 
00081   void server_protocol_properties_at_orb_level (TAO_SCIOP_Protocol_Properties &protocol_properties
00082                                                 ACE_ENV_ARG_DECL);
00083 
00084   void client_protocol_properties_at_orb_level (TAO_SCIOP_Protocol_Properties &protocol_properties
00085                                                 ACE_ENV_ARG_DECL);
00086 
00087   CORBA::Long get_dscp_codepoint (void);
00088 
00089   void rt_service_context (TAO_Stub *stub,
00090                            TAO_Service_Context &service_context,
00091                            CORBA::Boolean restart
00092                            ACE_ENV_ARG_DECL);
00093 
00094   void add_rt_service_context_hook (TAO_Service_Context &service_context,
00095                                     CORBA::Policy *model_policy,
00096                                     CORBA::Short &client_priority
00097                                     ACE_ENV_ARG_DECL);
00098 
00099   void get_selector_hook (CORBA::Policy *model_policy,
00100                           CORBA::Boolean
00101                           &is_client_propagated,
00102                           CORBA::Short &server_priority);
00103 
00104   void get_selector_bands_policy_hook (CORBA::Policy *bands_policy,
00105                                        CORBA::Short priority,
00106                                        CORBA::Short &min_priority,
00107                                        CORBA::Short &max_priority,
00108                                        int &in_range);
00109 
00110   /**
00111    * Accessor and modifier to the current thread priority, used to
00112    * implement the RTCORBA::Current interface, but it is faster for
00113    * some critical components.
00114    */
00115   //@{
00116   int get_thread_CORBA_priority (CORBA::Short &
00117                                  ACE_ENV_ARG_DECL);
00118 
00119   int get_thread_native_priority (CORBA::Short &
00120                                   ACE_ENV_ARG_DECL);
00121 
00122   int get_thread_CORBA_and_native_priority (CORBA::Short &,
00123                                             CORBA::Short &
00124                                             ACE_ENV_ARG_DECL);
00125 
00126   int set_thread_CORBA_priority (CORBA::Short
00127                                  ACE_ENV_ARG_DECL);
00128 
00129   int set_thread_native_priority (CORBA::Short
00130                                   ACE_ENV_ARG_DECL);
00131 
00132   //@}
00133 
00134 protected:
00135 
00136   RTCORBA::ProtocolProperties_ptr server_protocol_properties (IOP::ProfileId protocol_tag,
00137                                                               CORBA::Policy_ptr policy
00138                                                               ACE_ENV_ARG_DECL);
00139 
00140   RTCORBA::ProtocolProperties_ptr client_protocol_properties (IOP::ProfileId protocol_tag,
00141                                                               CORBA::Policy_ptr policy
00142                                                               ACE_ENV_ARG_DECL);
00143 
00144   RTCORBA::ProtocolProperties_ptr server_protocol_properties_at_orb_level (IOP::ProfileId protocol_tag
00145                                                                            ACE_ENV_ARG_DECL);
00146 
00147   RTCORBA::ProtocolProperties_ptr client_protocol_properties_at_orb_level (IOP::ProfileId protocol_tag
00148                                                                            ACE_ENV_ARG_DECL);
00149 
00150   RTCORBA::ProtocolProperties_ptr client_protocol_properties_at_object_level (IOP::ProfileId protocol_tag,
00151                                                                               TAO_Stub *stub
00152                                                                               ACE_ENV_ARG_DECL);
00153 
00154   void extract_protocol_properties (TAO_IIOP_Protocol_Properties &to,
00155                                     RTCORBA::ProtocolProperties_ptr from
00156                                     ACE_ENV_ARG_DECL);
00157 
00158   void extract_protocol_properties (TAO_UIOP_Protocol_Properties &to,
00159                                     RTCORBA::ProtocolProperties_ptr from
00160                                     ACE_ENV_ARG_DECL);
00161 
00162   void extract_protocol_properties (TAO_SHMIOP_Protocol_Properties &to,
00163                                     RTCORBA::ProtocolProperties_ptr from
00164                                     ACE_ENV_ARG_DECL);
00165 
00166   void extract_protocol_properties (TAO_DIOP_Protocol_Properties &to,
00167                                     RTCORBA::ProtocolProperties_ptr from
00168                                     ACE_ENV_ARG_DECL);
00169 
00170   void extract_protocol_properties (TAO_SCIOP_Protocol_Properties &to,
00171                                     RTCORBA::ProtocolProperties_ptr from
00172                                     ACE_ENV_ARG_DECL);
00173 
00174   CORBA::Boolean set_network_priority (IOP::ProfileId protocol_tag,
00175                                        RTCORBA::ProtocolProperties_ptr protocol_properties
00176                                        ACE_ENV_ARG_DECL);
00177 
00178 protected:
00179 
00180   TAO_ORB_Core *orb_core_;
00181 
00182   // Save a reference to the priority mapping manager.
00183   TAO_Priority_Mapping_Manager_var mapping_manager_;
00184   TAO_Network_Priority_Mapping_Manager_var network_mapping_manager_;
00185 
00186   RTCORBA::Current_var current_;
00187 };
00188 
00189 TAO_END_VERSIONED_NAMESPACE_DECL
00190 
00191 ACE_STATIC_SVC_DECLARE_EXPORT (TAO_RTCORBA, TAO_RT_Protocols_Hooks)
00192 ACE_FACTORY_DECLARE (TAO_RTCORBA, TAO_RT_Protocols_Hooks)
00193 
00194 #endif /* TAO_HAS_CORBA_MESSAGING && TAO_HAS_CORBA_MESSAGING != 0 */
00195 
00196 #include /**/ "ace/post.h"
00197 #endif /* TAO_RT_PROTOCOLS_HOOKS_H */

Generated on Thu Nov 9 12:58:02 2006 for TAO_RTCORBA by doxygen 1.3.6