2023-10-31 15:10:34 +01:00
|
|
|
[/
|
|
|
|
Copyright (c) 2023 Mireo
|
|
|
|
|
|
|
|
Distributed under the Boost Software License, Version 1.0. (See accompanying
|
|
|
|
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
|
|
|
]
|
|
|
|
|
2023-11-03 13:40:03 +01:00
|
|
|
[section:examples Examples]
|
2023-11-15 09:20:59 +01:00
|
|
|
The main class in __Self__ is __Client__, and the upcoming sections will briefly explain how to use it.
|
2023-10-31 15:10:34 +01:00
|
|
|
|
2023-11-15 09:20:59 +01:00
|
|
|
The first two examples will demonstrate using __Client__ as a publisher and receiver.
|
|
|
|
|
|
|
|
* [link async_mqtt5.examples.publisher The publisher]
|
|
|
|
* [link async_mqtt5.examples.receiver The receiver]
|
|
|
|
|
|
|
|
The following two sections serve as reference.
|
2023-11-03 13:40:03 +01:00
|
|
|
The first section will show how to use different underlying transport protocols (such as TCP, SSL and WebSocket)
|
2023-11-15 09:20:59 +01:00
|
|
|
to establish a connection to an MQTT Broker.
|
2023-10-31 15:10:34 +01:00
|
|
|
|
2023-11-03 13:40:03 +01:00
|
|
|
* [link async_mqtt5.examples.network_connection Establishing a network connection with different protocols]
|
2023-10-31 15:10:34 +01:00
|
|
|
|
2023-11-15 09:20:59 +01:00
|
|
|
The second section will showcase how to use asynchronous functions in __Client__
|
|
|
|
with different completion tokens.
|
2023-10-31 15:10:34 +01:00
|
|
|
|
2023-11-03 13:40:03 +01:00
|
|
|
* [link async_mqtt5.examples.asio Compatibility with Boost.Asio]
|
|
|
|
* [link async_mqtt5.examples.asio.callbacks Async functions with callbacks]
|
|
|
|
* [link async_mqtt5.examples.asio.cpp20_coroutines Async functions with C++20 coroutines]
|
|
|
|
* [link async_mqtt5.examples.asio.futures Async functions with futures]
|
2023-11-15 09:20:59 +01:00
|
|
|
|
|
|
|
|
|
|
|
[include examples/Basic_examples.qbk]
|
2023-11-03 13:40:03 +01:00
|
|
|
[include examples/Network_connection.qbk]
|
|
|
|
[include examples/Asio_compatibility.qbk]
|
2023-11-02 12:50:08 +01:00
|
|
|
|
2023-10-31 15:10:34 +01:00
|
|
|
[endsect]
|