MRPT  1.9.9
mrpt::comms::TopicDirectory Class Reference

Detailed Description

The central directory of existing topics for pub/sub.

Definition at line 108 of file nodelets.h.

#include <mrpt/comms/nodelets.h>

Inheritance diagram for mrpt::comms::TopicDirectory:
Inheritance graph

Public Types

using Ptr = std::shared_ptr< TopicDirectory >

Public Member Functions

template<typename PATH >
Topic::Ptr getTopic (PATH &&path)
void cleanupTopic (const std::string &key)

Static Public Member Functions

static Ptr create ()

Private Member Functions

 TopicDirectory ()

Private Attributes

std::mutex m_mutex
std::unordered_map< std::string, std::weak_ptr< Topic > > m_mapService

Member Typedef Documentation

◆ Ptr

Constructor & Destructor Documentation

◆ TopicDirectory()

TopicDirectory::TopicDirectory ( )

Definition at line 55 of file nodelets.cpp.

Member Function Documentation

◆ cleanupTopic()

void TopicDirectory::cleanupTopic ( const std::string key)

Definition at line 57 of file nodelets.cpp.

References m_mapService, and m_mutex.

◆ create()

TopicDirectory::Ptr TopicDirectory::create ( )

Definition at line 63 of file nodelets.cpp.

◆ getTopic()

template<typename PATH >
Topic::Ptr mrpt::comms::TopicDirectory::getTopic ( PATH &&  path)

Definition at line 117 of file nodelets.h.

References mrpt::comms::Topic::create(), m_mapService, and m_mutex.

Member Data Documentation

◆ m_mapService

std::unordered_map<std::string, std::weak_ptr<Topic> > mrpt::comms::TopicDirectory::m_mapService

Definition at line 139 of file nodelets.h.

Referenced by cleanupTopic(), and getTopic().

◆ m_mutex

std::mutex mrpt::comms::TopicDirectory::m_mutex

Definition at line 138 of file nodelets.h.

Referenced by cleanupTopic(), and getTopic().

Page generated by Doxygen 1.8.14 for MRPT 1.9.9 Git: 7d5e6d718 Fri Aug 24 01:51:28 2018 +0200 at lun nov 2 08:35:50 CET 2020