mqtt_cpp
sub_con_map.hpp
Go to the documentation of this file.
1 // Copyright Takatoshi Kondo 2020
2 //
3 // Distributed under the Boost Software License, Version 1.0.
4 // (See accompanying file LICENSE_1_0.txt or copy at
5 // http://www.boost.org/LICENSE_1_0.txt)
6 
7 #if !defined(MQTT_BROKER_SUB_CON_MAP_HPP)
8 #define MQTT_BROKER_SUB_CON_MAP_HPP
9 
10 #include <mqtt/config.hpp>
11 
15 
17 
18 struct buffer_hasher {
19  std::size_t operator()(buffer const& b) const noexcept {
20  std::size_t result = 0;
21  boost::hash_combine(result, b);
22  return result;
23  }
24 };
25 
27 
29 
30 #endif // MQTT_BROKER_SUB_CON_MAP_HPP
#define MQTT_BROKER_NS_END
Definition: broker_namespace.hpp:22
#define MQTT_BROKER_NS_BEGIN
Definition: broker_namespace.hpp:21
const_buffer buffer(MQTT_NS::buffer const &data)
create boost::asio::const_buffer from the MQTT_NS::buffer boost::asio::const_buffer is a kind of view...
Definition: buffer.hpp:253
Definition: sub_con_map.hpp:18
std::size_t operator()(buffer const &b) const noexcept
Definition: sub_con_map.hpp:19