19 #ifndef INCLUDE_RCF_INPROCESSTRANSPORT_HPP
20 #define INCLUDE_RCF_INPROCESSTRANSPORT_HPP
22 #include <RCF/ClientTransport.hpp>
23 #include <RCF/Export.hpp>
24 #include <RCF/RcfSession.hpp>
28 class InProcessRemoteAddress :
public RemoteAddress
31 InProcessRemoteAddress(InProcessTransport & transport) : mTransport(transport)
37 std::string string()
const
39 return "In process endpoint.";
42 InProcessTransport & mTransport;
45 class RCF_EXPORT InProcessTransport :
46 public ClientTransport,
48 public ServerTransport,
49 public ServerTransportEx
52 InProcessTransport(RcfServer & server, RcfServer * pCallbackServer = NULL);
53 ~InProcessTransport();
55 TransportType getTransportType();
60 RcfServer * mpCallbackServer;
61 RcfSessionPtr mSessionPtr;
62 RcfSessionPtr mOppositeSessionPtr;
64 InProcessRemoteAddress mRemoteAddress;
68 void doInProcessCall(ClientStub & clientStub);
71 std::auto_ptr<ClientTransport> clone()
const;
73 EndpointPtr getEndpointPtr()
const;
76 ClientTransportCallback & clientStub,
77 const std::vector<ByteBuffer> & data,
78 unsigned int timeoutMs);
81 ClientTransportCallback & clientStub,
82 ByteBuffer & byteBuffer,
83 unsigned int timeoutMs);
88 ClientTransportCallback & clientStub,
89 unsigned int timeoutMs);
92 unsigned int timeoutMs);
94 void setTransportFilters(
95 const std::vector<FilterPtr> & filters);
97 void getTransportFilters(
98 std::vector<FilterPtr> & filters);
101 boost::uint32_t timeoutMs,
102 ClientTransportCallback * pClientStub);
106 ByteBuffer getReadByteBuffer();
107 void postWrite(std::vector<ByteBuffer> &byteBuffers);
109 ServerTransport & getServerTransport();
110 const RemoteAddress & getRemoteAddress();
115 ServerTransportPtr clone();
118 ClientTransportAutoPtr
119 createClientTransport(
120 const Endpoint &endpoint);
124 ClientTransportAutoPtr & clientTransportAutoPtr,
125 StubEntryPtr stubEntryPtr,
126 bool keepClientConnection);
128 ClientTransportAutoPtr
129 createClientTransport(
130 SessionPtr sessionPtr);
134 const SessionPtr &sessionPtr1,
135 const SessionPtr &sessionPtr2);
139 const SessionPtr &sessionPtr);
144 #endif // ! INCLUDE_RCF_INPROCESSTRANSPORT_HPP