mqtt_cpp
Classes | Public Types | Public Member Functions | Protected Member Functions | Static Protected Member Functions | Protected Attributes | List of all members
subscription_map_base< Value > Class Template Reference

#include <subscription_map.hpp>

Inheritance diagram for subscription_map_base< Value >:
Inheritance graph
[legend]

Public Types

using node_id_t = std::size_t
 
using path_entry_key = std::pair< node_id_t, buffer >
 
using handle = path_entry_key
 

Public Member Functions

std::size_t internal_size () const
 
std::size_t size () const
 
optional< handlelookup (string_view topic_filter)
 
std::string handle_to_topic_filter (handle const &h) const
 

Protected Member Functions

map_type_iterator get_root ()
 
map_type_const_iterator get_root () const
 
map_type_iterator get_key (path_entry_key key)
 
map_type_iterator begin ()
 
map_type_iterator end ()
 
map_type const & get_map () const
 
handle path_to_handle (std::vector< map_type_iterator > const &path) const
 
std::vector< map_type_iterator > find_topic_filter (string_view topic_filter)
 
std::vector< map_type_iterator > create_topic_filter (string_view topic_filter)
 
void remove_topic_filter (std::vector< map_type_iterator > const &path)
 
template<typename Output >
void find_match (string_view topic, Output &&callback) const
 
template<typename Output >
void modify_match (string_view topic, Output &&callback)
 
std::vector< map_type_iterator > handle_to_iterators (handle const &h)
 
void increase_subscriptions (handle const &h)
 
void increase_map_size ()
 
void decrease_map_size ()
 
void increase_subscriptions (std::vector< map_type_iterator > const &path)
 
 subscription_map_base ()
 

Static Protected Member Functions

template<typename ThisType , typename Output >
static void find_match_impl (ThisType &self, string_view topic, Output &&callback)
 
template<typename ThisType , typename Output >
static void handle_to_iterators (ThisType &self, handle const &h, Output &&output)
 
static void throw_invalid_topic_filter ()
 
static void throw_invalid_handle ()
 
static void throw_max_stored_topics ()
 

Protected Attributes

path_entry_key root_key
 
node_id_t root_node_id
 
size_t map_size = 0
 

Member Typedef Documentation

◆ handle

template<typename Value >
using subscription_map_base< Value >::handle = path_entry_key

◆ node_id_t

template<typename Value >
using subscription_map_base< Value >::node_id_t = std::size_t

◆ path_entry_key

template<typename Value >
using subscription_map_base< Value >::path_entry_key = std::pair<node_id_t, buffer>

Constructor & Destructor Documentation

◆ subscription_map_base()

template<typename Value >
subscription_map_base< Value >::subscription_map_base ( )
inlineprotected

Member Function Documentation

◆ begin()

template<typename Value >
map_type_iterator subscription_map_base< Value >::begin ( )
inlineprotected

◆ create_topic_filter()

template<typename Value >
std::vector<map_type_iterator> subscription_map_base< Value >::create_topic_filter ( string_view  topic_filter)
inlineprotected

◆ decrease_map_size()

template<typename Value >
void subscription_map_base< Value >::decrease_map_size ( )
inlineprotected

◆ end()

template<typename Value >
map_type_iterator subscription_map_base< Value >::end ( )
inlineprotected

◆ find_match()

template<typename Value >
template<typename Output >
void subscription_map_base< Value >::find_match ( string_view  topic,
Output &&  callback 
) const
inlineprotected

◆ find_match_impl()

template<typename Value >
template<typename ThisType , typename Output >
static void subscription_map_base< Value >::find_match_impl ( ThisType &  self,
string_view  topic,
Output &&  callback 
)
inlinestaticprotected

◆ find_topic_filter()

template<typename Value >
std::vector< map_type_iterator> subscription_map_base< Value >::find_topic_filter ( string_view  topic_filter)
inlineprotected

◆ get_key()

template<typename Value >
map_type_iterator subscription_map_base< Value >::get_key ( path_entry_key  key)
inlineprotected

◆ get_map()

template<typename Value >
map_type const& subscription_map_base< Value >::get_map ( ) const
inlineprotected

◆ get_root() [1/2]

template<typename Value >
map_type_iterator subscription_map_base< Value >::get_root ( )
inlineprotected

◆ get_root() [2/2]

template<typename Value >
map_type_const_iterator subscription_map_base< Value >::get_root ( ) const
inlineprotected

◆ handle_to_iterators() [1/2]

template<typename Value >
std::vector<map_type_iterator> subscription_map_base< Value >::handle_to_iterators ( handle const &  h)
inlineprotected

◆ handle_to_iterators() [2/2]

template<typename Value >
template<typename ThisType , typename Output >
static void subscription_map_base< Value >::handle_to_iterators ( ThisType &  self,
handle const &  h,
Output &&  output 
)
inlinestaticprotected

◆ handle_to_topic_filter()

template<typename Value >
std::string subscription_map_base< Value >::handle_to_topic_filter ( handle const &  h) const
inline

◆ increase_map_size()

template<typename Value >
void subscription_map_base< Value >::increase_map_size ( )
inlineprotected

◆ increase_subscriptions() [1/2]

template<typename Value >
void subscription_map_base< Value >::increase_subscriptions ( handle const &  h)
inlineprotected

◆ increase_subscriptions() [2/2]

template<typename Value >
void subscription_map_base< Value >::increase_subscriptions ( std::vector< map_type_iterator > const &  path)
inlineprotected

◆ internal_size()

template<typename Value >
std::size_t subscription_map_base< Value >::internal_size ( ) const
inline

◆ lookup()

template<typename Value >
optional<handle> subscription_map_base< Value >::lookup ( string_view  topic_filter)
inline

◆ modify_match()

template<typename Value >
template<typename Output >
void subscription_map_base< Value >::modify_match ( string_view  topic,
Output &&  callback 
)
inlineprotected

◆ path_to_handle()

template<typename Value >
handle subscription_map_base< Value >::path_to_handle ( std::vector< map_type_iterator > const &  path) const
inlineprotected

◆ remove_topic_filter()

template<typename Value >
void subscription_map_base< Value >::remove_topic_filter ( std::vector< map_type_iterator > const &  path)
inlineprotected

◆ size()

template<typename Value >
std::size_t subscription_map_base< Value >::size ( ) const
inline

◆ throw_invalid_handle()

template<typename Value >
static void subscription_map_base< Value >::throw_invalid_handle ( )
inlinestaticprotected

◆ throw_invalid_topic_filter()

template<typename Value >
static void subscription_map_base< Value >::throw_invalid_topic_filter ( )
inlinestaticprotected

◆ throw_max_stored_topics()

template<typename Value >
static void subscription_map_base< Value >::throw_max_stored_topics ( )
inlinestaticprotected

Member Data Documentation

◆ map_size

template<typename Value >
size_t subscription_map_base< Value >::map_size = 0
protected

◆ root_key

template<typename Value >
path_entry_key subscription_map_base< Value >::root_key
protected

◆ root_node_id

template<typename Value >
node_id_t subscription_map_base< Value >::root_node_id
protected

The documentation for this class was generated from the following file: