Remote Call Framework 3.1
RcfFwd.hpp
Go to the documentation of this file.
1 
2 //******************************************************************************
3 // RCF - Remote Call Framework
4 //
5 // Copyright (c) 2005 - 2019, Delta V Software. All rights reserved.
6 // http://www.deltavsoft.com
7 //
8 // RCF is distributed under dual licenses - closed source or GPL.
9 // Consult your particular license for conditions of use.
10 //
11 // If you have not purchased a commercial license, you are using RCF
12 // under GPL terms.
13 //
14 // Version: 3.1
15 // Contact: support <at> deltavsoft.com
16 //
17 //******************************************************************************
18 
20 
21 #ifndef INCLUDE_RCF_RCFFWD_HPP
22 #define INCLUDE_RCF_RCFFWD_HPP
23 
24 #include <functional>
25 #include <memory>
26 
27 #include <RCF/Enums.hpp>
28 
29 namespace RCF
30 {
31 
32  class RcfServer;
33  class RcfSession;
34  class ClientTransport;
35  class ServerTransport;
36  class Endpoint;
37  class I_RcfClient;
38  typedef std::shared_ptr<I_RcfClient> RcfClientPtr;
39  typedef std::shared_ptr<RcfSession> RcfSessionPtr;
40  typedef std::weak_ptr<RcfSession> RcfSessionWeakPtr;
41 
43  typedef std::unique_ptr<ClientTransport> ClientTransportUniquePtr;
44 
46  typedef std::shared_ptr<ServerTransport> ServerTransportPtr;
47 
48  class Exception;
49  typedef std::shared_ptr<Exception> ExceptionPtr;
50 
51  template<typename T> class RcfClient;
52  class I_RequestSubscription;
53  class I_Null;
54 
55  class PublisherBase;
56  typedef std::shared_ptr<PublisherBase> PublisherPtr;
57  typedef std::weak_ptr<PublisherBase> PublisherWeakPtr;
58 
59  class PublishingService;
60 
61  class SubscriptionService;
62  class SubscriptionParms;
63  class Subscription;
64  typedef std::shared_ptr<Subscription> SubscriptionPtr;
65  typedef std::weak_ptr<Subscription> SubscriptionWeakPtr;
66 
67  typedef std::shared_ptr<Subscription> SubscriptionPtr;
68  typedef std::weak_ptr<Subscription> SubscriptionWeakPtr;
69 
71  typedef std::function<bool(RcfSession &, const std::string &)> OnSubscriberConnect;
72 
74  typedef std::function<void(RcfSession &, const std::string &)> OnSubscriberDisconnect;
75 
77  typedef std::function<void(RcfSession &)> OnSubscriptionDisconnect;
78 
80  typedef std::function<void(SubscriptionPtr, ExceptionPtr)> OnAsyncSubscribeCompleted;
81 
82  enum RemoteCallAction;
84 
86  typedef std::function<void(const RemoteCallProgressInfo&, RemoteCallAction&)> RemoteCallProgressCallback;
87 
88  template<typename T>
89  class Future;
90 
91  template<typename T>
92  class FutureConverter;
93 
94  struct Void;
95  class CallOptions;
96  class ConnectionResetGuard;
97  class I_Parameters;
98  class Certificate;
99  class ClientStub;
100  class ClientProgress;
101  class I_Future;
102  class IpClientTransport;
103  class FileTransferProgress;
104  class OpenSslEncryptionFilter;
105  class SspiFilter;
106  class OverlappedAmi;
107  class FileManifest;
108  class Filter;
109 
111  typedef std::shared_ptr<Certificate> CertificatePtr;
112 
114  typedef std::function<bool(Certificate *)> CertificateValidationCallback;
115 
117  typedef std::shared_ptr<Endpoint> EndpointPtr;
118 
119  typedef std::shared_ptr<Filter> FilterPtr;
120  typedef std::shared_ptr<ClientStub> ClientStubPtr;
121  typedef std::shared_ptr<ClientProgress> ClientProgressPtr;
122  typedef std::shared_ptr<OverlappedAmi> OverlappedAmiPtr;
123 
124  class FileDownloadInfo;
125  class FileUploadInfo;
126 
128  typedef std::shared_ptr<BandwidthQuota> BandwidthQuotaPtr;
129 
131  typedef std::function<void(const FileTransferProgress &, RemoteCallAction&)> FileProgressCallback;
132 
134  typedef std::function<void(RcfSession&, FileDownloadInfo &)> DownloadProgressCallback;
135 
137  typedef std::function<void(RcfSession&, FileUploadInfo &)> UploadProgressCallback;
138 
140  typedef std::function<BandwidthQuotaPtr(RcfSession &)> BandwidthQuotaCallback;
141 
143  typedef BandwidthQuotaCallback UploadBandwidthQuotaCallback;
144 
146  typedef BandwidthQuotaCallback DownloadBandwidthQuotaCallback;
147 
148 
149  template<
150  typename R,
151  typename A1,
152  typename A2,
153  typename A3,
154  typename A4,
155  typename A5,
156  typename A6,
157  typename A7,
158  typename A8,
159  typename A9,
160  typename A10,
161  typename A11,
162  typename A12,
163  typename A13,
164  typename A14,
165  typename A15>
166  class AllocateClientParameters;
167 
168  template<
169  typename R,
170  typename A1,
171  typename A2,
172  typename A3,
173  typename A4,
174  typename A5,
175  typename A6,
176  typename A7,
177  typename A8,
178  typename A9,
179  typename A10,
180  typename A11,
181  typename A12,
182  typename A13,
183  typename A14,
184  typename A15>
185  class ClientParameters;
186 
187  class I_Service;
188  class IpServerTransport;
189  class PingBackService;
190  class FileTransferService;
191  class FilterService;
192  class SessionTimeoutService;
193  class PublishingService;
194  class CallbackConnectionService;
195  class ServerObjectService;
196  class ProxyEndpointService;
197 
198  typedef std::shared_ptr<I_Service> ServicePtr;
199  typedef std::shared_ptr<PingBackService> PingBackServicePtr;
200  typedef std::shared_ptr<FileTransferService> FileTransferServicePtr;
201  typedef std::shared_ptr<FilterService> FilterServicePtr;
202  typedef std::shared_ptr<SessionTimeoutService> SessionTimeoutServicePtr;
203  typedef std::shared_ptr<PublishingService> PublishingServicePtr;
204  typedef std::shared_ptr<SubscriptionService> SubscriptionServicePtr;
205  typedef std::shared_ptr<CallbackConnectionService> CallbackConnectionServicePtr;
206  typedef std::shared_ptr<ServerObjectService> ServerObjectServicePtr;
207  typedef std::shared_ptr<ProxyEndpointService> ProxyEndpointServicePtr;
208 
209  template<typename Interface>
210  class Publisher;
211 
212  class BandwidthQuota;
213 
215  typedef std::shared_ptr<BandwidthQuota> BandwidthQuotaPtr;
216 
217  class FileDownloadInfo;
218  class FileUploadInfo;
219 
220  class JsonRpcRequest;
221  class JsonRpcResponse;
222 
223  class HttpSession;
224  typedef std::shared_ptr<HttpSession> HttpSessionPtr;
225 
226  class HttpCookie;
227 
228  typedef std::function<void(RcfSessionPtr, ClientTransportUniquePtr)> OnCallbackConnectionCreated;
229 
230  typedef RcfSessionPtr SessionPtr;
231 
232  enum TransportProtocol;
233  enum SslImplementation;
234  enum TransportType;
235  enum CertificateImplementationType;
236 
237  class PublisherParms;
238 
239  class I_CreateCallbackConnection;
240 
241  typedef std::shared_ptr<ClientTransport> ClientTransportPtr;
242 
243  typedef std::shared_ptr< ClientTransportUniquePtr > ClientTransportUniquePtrPtr;
244 
245  typedef std::unique_ptr<ServerTransport> ServerTransportUniquePtr;
246 
247 
249 
250  typedef std::shared_ptr<ServerBinding> ServerBindingPtr;
251 
252  class MethodInvocationRequest;
253 
254  class NetworkSession;
255  class ByteBuffer;
256 
258 
260  typedef std::shared_ptr<Win32Certificate> Win32CertificatePtr;
261 
262  class X509Certificate;
263  typedef std::shared_ptr<X509Certificate> X509CertificatePtr;
264 
265  class UdpServerTransport;
266  class UdpNetworkSession;
267 
268  class FileStreamImpl;
269 
270  typedef std::shared_ptr<FileUploadInfo> FileUploadInfoPtr;
271  typedef std::shared_ptr<FileDownloadInfo> FileDownloadInfoPtr;
272 
273  typedef std::pair<std::uint32_t, RcfSessionWeakPtr> PingBackTimerEntry;
274 
275  class RemoteAddress;
276  class RemoteCallInfo;
277  class FileStream;
278  class FileUpload;
279  class FileDownload;
280 
281  class AsioNetworkSession;
282 
283  template<
284  typename R,
285  typename A1,
286  typename A2,
287  typename A3,
288  typename A4,
289  typename A5,
290  typename A6,
291  typename A7,
292  typename A8,
293  typename A9,
294  typename A10,
295  typename A11,
296  typename A12,
297  typename A13,
298  typename A14,
299  typename A15>
300  class AllocateServerParameters;
301 
302  template<
303  typename R,
304  typename A1,
305  typename A2,
306  typename A3,
307  typename A4,
308  typename A5,
309  typename A6,
310  typename A7,
311  typename A8,
312  typename A9,
313  typename A10,
314  typename A11,
315  typename A12,
316  typename A13,
317  typename A14,
318  typename A15>
319  class ServerParameters;
320 
321  class ServerBinding;
322 
324  typedef std::shared_ptr<ServerBinding> ServerBindingPtr;
325 
327  typedef std::function<bool(int)> AccessControlCallback;
328 
329 } // namespace RCF
330 
331 #endif // ! INCLUDE_RCF_RCFFWD_HPP
Describes the network address of a remote peer.
Definition: ServerTransport.hpp:37
Contains details about the currently executing remote call.
Definition: MethodInvocation.hpp:63
std::function< BandwidthQuotaPtr(RcfSession &)> BandwidthQuotaCallback
Describes user-provided callback functions for assigning custom bandwidth quotas to a RcfSession...
Definition: RcfFwd.hpp:140
std::function< void(RcfSession &, FileDownloadInfo &)> DownloadProgressCallback
Describes user-provided callback functions for server-side monitoring of a file download.
Definition: RcfFwd.hpp:134
Represents the binding of a server-side servant object to a RCF interface.
Definition: ServerStub.hpp:326
Describes the status of a remote call while in progress. See RCF::ClientStub::setRemoteCallProgressCa...
Definition: ClientProgress.hpp:32
std::function< void(const RemoteCallProgressInfo &, RemoteCallAction &)> RemoteCallProgressCallback
Describes a user-provided callback function to be called periodically on the client side...
Definition: RcfFwd.hpp:83
std::shared_ptr< BandwidthQuota > BandwidthQuotaPtr
Reference counted wrapper for RCF::BandwidthQuota.
Definition: RcfFwd.hpp:127
Controls the client side of a RCF connection.
Definition: ClientStub.hpp:82
std::shared_ptr< Endpoint > EndpointPtr
Reference counted wrapper for RCF::Endpoint.
Definition: RcfFwd.hpp:117
std::shared_ptr< Certificate > CertificatePtr
Reference counted wrapper for RCF::Certificate.
Definition: RcfFwd.hpp:108
std::unique_ptr< ClientTransport > ClientTransportUniquePtr
Unique pointer wrapper for RCF::ClientTransport.
Definition: RcfFwd.hpp:43
std::shared_ptr< Win32Certificate > Win32CertificatePtr
Reference counted wrapper for RCF::Win32Certificate.
Definition: RcfFwd.hpp:257
Server-side information about a file download taking place from a RcfServer.
Definition: FileTransferService.hpp:98
std::function< void(RcfSession &, const std::string &)> OnSubscriberDisconnect
Describes a user-provided callback function to be called on the publisher side, whenever a subscriber...
Definition: RcfFwd.hpp:74
BandwidthQuotaCallback DownloadBandwidthQuotaCallback
Describes user-provided callback functions for assigning custom bandwidth quotas to a RcfSession...
Definition: RcfFwd.hpp:146
std::function< bool(Certificate *)> CertificateValidationCallback
Describes user-provided callback functions for validating a certificate.
Definition: RcfFwd.hpp:114
Provides the ability for remote calls to be executed asynchronously.
Definition: Future.hpp:51
Base class for all RCF exceptions.
Definition: Exception.hpp:64
std::function< void(const FileTransferProgress &, RemoteCallAction &)> FileProgressCallback
Describes user-provided callback functions for client-side monitoring of a file transfer (download or...
Definition: RcfFwd.hpp:131
BandwidthQuotaCallback UploadBandwidthQuotaCallback
Describes user-provided callback functions for assigning custom bandwidth quotas to a RcfSession...
Definition: RcfFwd.hpp:143
std::function< bool(int)> AccessControlCallback
Describes user-provided function for determining whether a client connections should be able to acces...
Definition: RcfFwd.hpp:327
SslImplementation
Describes which SSL implementation to use.
Definition: Enums.hpp:85
Represents an in-memory certificate, either from a remote peer or loaded from a local certificate sto...
Definition: Win32Certificate.hpp:38
Utility class used by RCF to determine whether a remote call should be performed synchronously or asy...
Definition: Future.hpp:35
std::shared_ptr< ServerBinding > ServerBindingPtr
Reference counted wrapper for RCF::ServerBinding.
Definition: RcfFwd.hpp:248
Describes a unit of bandwidth, to be used by downloads or uploads, for a single connection or a group...
Definition: FileStream.hpp:337
Base class for IP-based client transports. Provides IP-related functionality.
Definition: IpClientTransport.hpp:28
std::function< void(RcfSession &, FileUploadInfo &)> UploadProgressCallback
Describes user-provided callback functions for server-side monitoring of a file upload.
Definition: RcfFwd.hpp:137
Represents an in-memory certificate, usually from a remote peer. Only applicable to OpenSSL...
Definition: OpenSslEncryptionFilter.hpp:73
std::function< void(RcfSession &)> OnSubscriptionDisconnect
Describes a user-provided callback function to be called on the subscriber side, whenever a subscribe...
Definition: RcfFwd.hpp:77
Represents a single publisher within a RcfServer. To create a publisher, use RcfServer::createPublish...
Definition: PublishingService.hpp:94
Base class for IP-based server transports. Provides IP-related functionality.
Definition: IpServerTransport.hpp:37
Definition: ByteBuffer.hpp:40
TransportProtocol
Describes the transport protocols used by a RCF connection. Transport protocols are layered on top of...
Definition: Enums.hpp:63
General configuration of a subscription.
Definition: SubscriptionService.hpp:91
Definition: AmiIoHandler.hpp:24
TransportType
Describes the transport types used by a RCF connection.
Definition: Enums.hpp:34
Server-side information about a file upload taking place to a RcfServer.
Definition: FileTransferService.hpp:66
Base class for all RCF certificate classes.
Definition: Certificate.hpp:30
General configuration of a publisher.
Definition: PublishingService.hpp:38
std::function< bool(RcfSession &, const std::string &)> OnSubscriberConnect
Describes a user-provided callback function to be called on the publisher side, whenever a subscriber...
Definition: RcfFwd.hpp:71
std::shared_ptr< ServerTransport > ServerTransportPtr
Unique pointer wrapper for RCF::ServerTransport.
Definition: RcfFwd.hpp:46
Describes progress of a file download or upload.
Definition: FileStream.hpp:266
Base class of all publishers.
Definition: PublishingService.hpp:64
RemoteCallAction
Describes whether a remote call should continue or be canceled.
Definition: Enums.hpp:196
Represents a subscription to a RCF publisher. To create a subscription, use RcfServer::createSubscrip...
Definition: SubscriptionService.hpp:40
std::function< void(SubscriptionPtr, ExceptionPtr)> OnAsyncSubscribeCompleted
Describes a user-provided callback function to be called on the subscriber side, when an subscription...
Definition: RcfFwd.hpp:80