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/sender.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/sender.hpp')
| -rw-r--r-- | libcmix-common/sender.hpp | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/libcmix-common/sender.hpp b/libcmix-common/sender.hpp index ea16a81..c722e30 100644 --- a/libcmix-common/sender.hpp +++ b/libcmix-common/sender.hpp @@ -25,6 +25,7 @@ struct Sender : private ProtobufClient<CMixProtoFunctor> friend SenderReceiver; using ProtobufClient::ProtobufClient; + using ProtobufClient::operator=; using ProtobufClient::async_send; @@ -36,3 +37,33 @@ struct Sender : private ProtobufClient<CMixProtoFunctor> using ProtobufClient::is_open; }; + +/*! + * \brief forward declaration for SenderReceiver to allow for the friend declaration. + */ +struct SSLSenderReceiver; + +/*! + * \brief The Sender struct is a shim around ProtobufClient and only exposes things needed + * for sending messages. + */ +struct SSLSender : private SSLProtobufClient<CMixProtoFunctor> +{ + /*! + * The friend declaration that allows for the Sender to be upgraded to a SenderReceiver. + */ + friend SSLSenderReceiver; + + using SSLProtobufClient::SSLProtobufClient; + using SSLProtobufClient::operator=; + + using SSLProtobufClient::async_send; + + using SSLProtobufClient::async_connect; + + using SSLProtobufClient::close; + + using SSLProtobufClient::on_done; + + using SSLProtobufClient::is_open; +}; |
