diff options
| author | Dennis Brentjes <d.brentjes@gmail.com> | 2016-10-21 14:01:26 +0200 |
|---|---|---|
| committer | Dennis Brentjes <d.brentjes@gmail.com> | 2016-10-21 18:15:46 +0200 |
| commit | 510ce3bec7915a790fbf75ace5521e437d9d416a (patch) | |
| tree | 7b9286875652b677a110287d11d024f85879cc7a /libcmix-common/receiver.hpp | |
| parent | 640e0ad7a762d0473581c2114c2c945961bea80f (diff) | |
| download | cmix-510ce3bec7915a790fbf75ace5521e437d9d416a.tar.gz cmix-510ce3bec7915a790fbf75ace5521e437d9d416a.tar.bz2 cmix-510ce3bec7915a790fbf75ace5521e437d9d416a.zip | |
Adds SSL connections between nodes.
Diffstat (limited to 'libcmix-common/receiver.hpp')
| -rw-r--r-- | libcmix-common/receiver.hpp | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/libcmix-common/receiver.hpp b/libcmix-common/receiver.hpp index 8a73e9c..efd3753 100644 --- a/libcmix-common/receiver.hpp +++ b/libcmix-common/receiver.hpp @@ -21,6 +21,7 @@ struct Receiver : private ProtobufClient<CMixProtoFunctor> friend SenderReceiver; using ProtobufClient::ProtobufClient; + using ProtobufClient::operator=; using ProtobufClient::async_receive; @@ -32,3 +33,30 @@ struct Receiver : private ProtobufClient<CMixProtoFunctor> using ProtobufClient::is_open; }; + +struct SSLSenderReceiver; + +/*! + * \brief The Receiver struct is a shim around ProtobufClient and only exposes things needed + * for receiving messages. + */ +struct SSLReceiver : private SSLProtobufClient<CMixProtoFunctor> +{ + /*! + * \brief friend decleration allowing Receivers to be upgraded to SenderReceivers. + */ + friend SSLSenderReceiver; + + using SSLProtobufClient::SSLProtobufClient; + using SSLProtobufClient::operator=; + + using SSLProtobufClient::async_receive; + + using SSLProtobufClient::async_connect; + + using SSLProtobufClient::close; + + using SSLProtobufClient::on_done; + + using SSLProtobufClient::is_open; +}; |
