00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014 #ifndef TAO_IIOP_TRANSPORT_H
00015 #define TAO_IIOP_TRANSPORT_H
00016
00017 #include "ace/pre.h"
00018
00019 #include "tao/orbconf.h"
00020
00021 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00022 # pragma once
00023 #endif
00024
00025 #if defined (TAO_HAS_IIOP) && (TAO_HAS_IIOP != 0)
00026
00027 #include "tao/Transport.h"
00028
00029 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00030
00031 namespace IIOP
00032 {
00033 class ListenPointList;
00034 }
00035
00036
00037 class TAO_IIOP_Connection_Handler;
00038 class TAO_ORB_Core;
00039 class TAO_Operation_Details;
00040 class TAO_Acceptor;
00041 class TAO_Adapter;
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052 class TAO_Export TAO_IIOP_Transport : public TAO_Transport
00053 {
00054 public:
00055
00056
00057 TAO_IIOP_Transport (TAO_IIOP_Connection_Handler *handler,
00058 TAO_ORB_Core *orb_core);
00059
00060 protected:
00061
00062
00063
00064
00065
00066
00067 virtual ~TAO_IIOP_Transport (void);
00068
00069
00070
00071
00072
00073
00074
00075
00076 virtual ACE_Event_Handler * event_handler_i (void);
00077
00078 virtual ssize_t send (iovec *iov, int iovcnt,
00079 size_t &bytes_transferred,
00080 const ACE_Time_Value *timeout = 0);
00081
00082 #if TAO_HAS_SENDFILE == 1
00083 virtual ssize_t sendfile (TAO_MMAP_Allocator * allocator,
00084 iovec * iov,
00085 int iovcnt,
00086 size_t &bytes_transferred,
00087 ACE_Time_Value const * timeout = 0);
00088 #endif
00089
00090
00091 virtual ssize_t recv (char *buf, size_t len, const ACE_Time_Value *s = 0);
00092
00093
00094 public:
00095
00096
00097 void update_protocol_properties (int send_buffer_size,
00098 int recv_buffer_size,
00099 int no_delay,
00100 int enable_network_priority);
00101
00102
00103
00104 virtual int send_request (TAO_Stub *stub,
00105 TAO_ORB_Core *orb_core,
00106 TAO_OutputCDR &stream,
00107 TAO_Message_Semantics message_semantics,
00108 ACE_Time_Value *max_wait_time);
00109
00110 virtual int send_message (TAO_OutputCDR &stream,
00111 TAO_Stub *stub = 0,
00112 TAO_Message_Semantics message_semantics = TAO_Transport::TAO_TWOWAY_REQUEST,
00113 ACE_Time_Value *max_time_wait = 0);
00114
00115 virtual int generate_request_header (TAO_Operation_Details &opdetails,
00116 TAO_Target_Specification &spec,
00117 TAO_OutputCDR &msg);
00118
00119 virtual int tear_listen_point_list (TAO_InputCDR &cdr);
00120
00121 virtual TAO_Connection_Handler * connection_handler_i (void);
00122
00123
00124
00125 private:
00126
00127
00128 void set_bidir_context_info (TAO_Operation_Details &opdetails);
00129
00130
00131
00132
00133 int get_listen_point (IIOP::ListenPointList &listen_point_list,
00134 TAO_Acceptor *acceptor);
00135 private:
00136
00137
00138
00139 TAO_IIOP_Connection_Handler *connection_handler_;
00140 };
00141
00142 TAO_END_VERSIONED_NAMESPACE_DECL
00143
00144 #endif
00145
00146 #include "ace/post.h"
00147
00148 #endif