Revert "Minor modernization of DynamicAny code"
[ACE_TAO.git] / TAO / tao / Strategies / UIOP_Connector.h
blob3d9a4c6df3061cabda14a77d5d27ccaf2f3913aa
1 // -*- C++ -*-
3 //=============================================================================
4 /**
5 * @file UIOP_Connector.h
7 * UIOP specific connector processing
9 * @author Fred Kuhns <fredk@cs.wustl.edu>
10 * @author Ossama Othman <ossama@uci.edu>
12 //=============================================================================
15 #ifndef TAO_UIOP_CONNECTOR_H
16 #define TAO_UIOP_CONNECTOR_H
18 #include /**/ "ace/pre.h"
20 #include "tao/orbconf.h"
22 #if !defined (ACE_LACKS_PRAGMA_ONCE)
23 # pragma once
24 #endif /* ACE_LACKS_PRAGMA_ONCE */
26 # if TAO_HAS_UIOP == 1
28 #include "ace/LSOCK_Connector.h"
29 #include "ace/Connector.h"
30 #include "tao/Transport_Connector.h"
31 #include "tao/Strategies/UIOP_Connection_Handler.h"
32 #include "tao/Resource_Factory.h"
33 #include "tao/Connector_Impl.h"
35 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
37 class TAO_UIOP_Endpoint;
38 class TAO_Endpoint;
40 /**
41 * @class TAO_UIOP_Connector
43 * @brief UIOP-specific Connector bridge for pluggable protocols.
45 class TAO_Strategies_Export TAO_UIOP_Connector : public TAO_Connector
47 public:
48 /**
49 * Constructor.
50 * @@ Do we want to pass in the tag here or should it be statically
51 * defined?
53 TAO_UIOP_Connector ();
55 /// Destructor
56 ~TAO_UIOP_Connector ();
58 /**
59 * @name The TAO_Connector Methods
61 * Please check the documentation in Transport_Connector.h for details.
63 //@{
64 int open (TAO_ORB_Core *orb_core);
65 int close ();
67 TAO_Profile *create_profile (TAO_InputCDR& cdr);
69 virtual int check_prefix (const char *endpoint);
71 virtual TAO_Profile *corbaloc_scan (const char *str, size_t &len);
73 virtual char object_key_delimiter () const;
75 /// Cancel the passed cvs handler from the connector
76 virtual int cancel_svc_handler (TAO_Connection_Handler * svc_handler);
77 //@}
79 public:
80 typedef TAO_Connect_Concurrency_Strategy<TAO_UIOP_Connection_Handler>
81 TAO_UIOP_CONNECT_CONCURRENCY_STRATEGY;
83 typedef TAO_Connect_Creation_Strategy<TAO_UIOP_Connection_Handler>
84 TAO_UIOP_CONNECT_CREATION_STRATEGY;
86 typedef ACE_Connect_Strategy<TAO_UIOP_Connection_Handler,
87 ACE_LSOCK_CONNECTOR>
88 TAO_UIOP_CONNECT_STRATEGY;
90 typedef ACE_Strategy_Connector<TAO_UIOP_Connection_Handler,
91 ACE_LSOCK_CONNECTOR>
92 TAO_UIOP_BASE_CONNECTOR;
94 protected:
95 /**
96 * @name More TAO_Connector methods
98 * Please check the documentation in Transport_Connector.h.
100 //@{
101 int set_validate_endpoint (TAO_Endpoint *endpoint);
103 TAO_Transport *make_connection (TAO::Profile_Transport_Resolver *r,
104 TAO_Transport_Descriptor_Interface &desc,
105 ACE_Time_Value *timeout = 0);
107 virtual TAO_Profile *make_profile ();
109 //@}
111 private:
112 /// Return the remote endpoint, a helper function
113 TAO_UIOP_Endpoint *remote_endpoint (TAO_Endpoint *ep);
115 private:
116 /// Our connect strategy
117 TAO_UIOP_CONNECT_STRATEGY connect_strategy_;
119 /// The connector initiating connection requests for UIOP.
120 TAO_UIOP_BASE_CONNECTOR base_connector_;
123 TAO_END_VERSIONED_NAMESPACE_DECL
125 # endif /* TAO_HAS_UIOP == 1 */
127 #include /**/ "ace/post.h"
129 #endif /* TAO_UIOP_CONNECTOR_H */