mirror of
https://github.com/boostorg/mqtt5.git
synced 2025-11-12 05:29:52 +01:00
Support multiple subscription identifiers in received messages.
Summary: - refactor property encoding - change user property type to be std::pair<std::string, std::string> Reviewers: ivica Reviewed By: ivica Subscribers: korina Differential Revision: https://repo.mireo.local/D27867
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
#include <optional>
|
||||
#include <vector>
|
||||
|
||||
#include <boost/container/small_vector.hpp>
|
||||
#include <boost/range/iterator_range_core.hpp>
|
||||
#include <boost/type_traits/remove_cv_ref.hpp>
|
||||
|
||||
@@ -30,6 +31,21 @@ constexpr bool is_vector = is_specialization<
|
||||
boost::remove_cv_ref_t<T>, std::vector
|
||||
>;
|
||||
|
||||
template <typename... Args>
|
||||
constexpr std::true_type is_small_vector_impl(
|
||||
boost::container::small_vector_base<Args...> const &
|
||||
);
|
||||
constexpr std::false_type is_small_vector_impl( ... );
|
||||
|
||||
template <typename T>
|
||||
constexpr bool is_small_vector =
|
||||
decltype(is_small_vector_impl(std::declval<T>()))::value;
|
||||
|
||||
template <typename T>
|
||||
constexpr bool is_pair = is_specialization<
|
||||
boost::remove_cv_ref_t<T>, std::pair
|
||||
>;
|
||||
|
||||
template <typename T>
|
||||
constexpr bool is_boost_iterator = is_specialization<
|
||||
boost::remove_cv_ref_t<T>, boost::iterator_range
|
||||
|
||||
Reference in New Issue
Block a user