Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

Connector_Impl.h

Go to the documentation of this file.
00001 
00002 // -*- C++ -*-
00003 // ===================================================================
00004 /**
00005  *  @file   Connector_Impl.h
00006  *
00007  *  $Id: Connector_Impl.h,v 1.1.1.1 2001/12/04 14:34:41 chad Exp $
00008  *
00009  *  @author Balachandran Natarajan <bala@cs.wustl.edu>
00010  */
00011 // ===================================================================
00012 
00013 #ifndef TAO_CONNECTOR_IMPL_H
00014 #define TAO_CONNECTOR_IMPL_H
00015 #include "ace/pre.h"
00016 #include "tao/corbafwd.h"
00017 
00018 
00019 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00020 # pragma once
00021 #endif /* ACE_LACKS_PRAGMA_ONCE */
00022 
00023 
00024 #include "ace/Strategies_T.h"
00025 
00026 class TAO_ORB_Core;
00027 class ACE_Thread_Manager;
00028 
00029 /**
00030  * @class TAO_Connect_Creation_Strategy
00031  *
00032  * @brief Creation strategy helper
00033  *
00034  * Creates the TAO_*_Connection_Handler object for the TAO_*_Connector
00035  * objects. This template class can now be used by all the Connector
00036  * objects instead of having to duplicate code. This class can be used
00037  * to set any required properties on the connection handlers at
00038  * creation time.
00039  *
00040  */
00041 
00042 template <class SVC_HANDLER>
00043 class TAO_Connect_Creation_Strategy : public ACE_Creation_Strategy<SVC_HANDLER>
00044 {
00045 public:
00046 
00047   /// Constructor. <arg> parameter is used to pass any special
00048   /// state/info to the service handler upon creation.  Currently used
00049   /// by IIOP and UIOP to pass protocol configuration properties.
00050   TAO_Connect_Creation_Strategy (ACE_Thread_Manager * = 0,
00051                                  TAO_ORB_Core* orb_core = 0,
00052                                  void *arg = 0,
00053                                  CORBA::Boolean flag = 0);
00054 
00055   /// Makes TAO_*_Client_Connection_Handlers
00056   virtual int make_svc_handler (SVC_HANDLER *&sh);
00057 
00058 
00059 private:
00060 
00061   /// Pointer to the ORB_Core on which we are activated
00062   TAO_ORB_Core* orb_core_;
00063 
00064   /// Some info/state to be passed to the service handler we create.
00065   void *arg_;
00066 
00067   /// Are we using GIOP lite?
00068   CORBA::Boolean lite_flag_;
00069 };
00070 
00071 
00072 
00073 /**
00074  * @class TAO_Connect_Concurrency_Strategy
00075  *
00076  * @brief Concurrency strategy helper
00077  *
00078  * Activates the Svc_Handler, and then if the correct wait strategy is
00079  * in use registers the handler with the reactor.
00080  *
00081  */
00082 
00083 template <class SVC_HANDLER>
00084 class TAO_Connect_Concurrency_Strategy :
00085   public ACE_Concurrency_Strategy<SVC_HANDLER>
00086 {
00087 public:
00088 
00089   /// Constructor.
00090   TAO_Connect_Concurrency_Strategy (TAO_ORB_Core *orb_core);
00091 
00092 
00093   /// Activates the Svc_Handler, and if the right wait strategy is in
00094   /// use, registers the handle with the reactor.
00095   int activate_svc_handler (SVC_HANDLER *svc_handler,
00096                             void *arg);
00097 
00098 private:
00099 
00100   /// Pointer to the ORB Core.
00101   TAO_ORB_Core *orb_core_;
00102 
00103 };
00104 
00105 
00106 #if defined(__ACE_INLINE__)
00107 #include "tao/Connector_Impl.inl"
00108 #endif /* __ACE_INLINE__ */
00109 
00110 #if defined (ACE_TEMPLATES_REQUIRE_SOURCE)
00111 #include "tao/Connector_Impl.cpp"
00112 #endif /* ACE_TEMPLATES_REQUIRE_SOURCE */
00113 
00114 #if defined (ACE_TEMPLATES_REQUIRE_PRAGMA)
00115 #pragma implementation ("Connector_Impl.cpp")
00116 #endif /* ACE_TEMPLATES_REQUIRE_PRAGMA */
00117 
00118 #include "ace/post.h"
00119 #endif /*TAO_CONNECTOR_IMPL_H*/

Generated on Mon Jun 16 13:48:06 2003 for TAO by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002