#include <topic_manager.h>
|
bool | addSubCallback (const SubscribeOptions &ops) |
|
void | getBusInfo (XmlRpc::XmlRpcValue &info) |
| Compute the info for the node's connectivity. More...
|
|
void | getBusInfoCallback (XmlRpc::XmlRpcValue ¶ms, XmlRpc::XmlRpcValue &result) |
|
void | getBusStats (XmlRpc::XmlRpcValue &stats) |
| Compute the statistics for the node's connectivity. More...
|
|
void | getBusStatsCallback (XmlRpc::XmlRpcValue ¶ms, XmlRpc::XmlRpcValue &result) |
|
void | getPublications (XmlRpc::XmlRpcValue &publications) |
| Return the list of advertised topics for the node. More...
|
|
void | getPublicationsCallback (XmlRpc::XmlRpcValue ¶ms, XmlRpc::XmlRpcValue &result) |
|
void | getSubscriptions (XmlRpc::XmlRpcValue &subscriptions) |
| Return the list of subcriptions for the node. More...
|
|
void | getSubscriptionsCallback (XmlRpc::XmlRpcValue ¶ms, XmlRpc::XmlRpcValue &result) |
|
bool | isShuttingDown () |
|
bool | isTopicAdvertised (const std::string &topic) |
|
PublicationPtr | lookupPublicationWithoutLock (const std::string &topic) |
|
void | processPublishQueues () |
|
bool | pubUpdate (const std::string &topic, const std::vector< std::string > &pubs) |
| Update local publisher lists. More...
|
|
void | pubUpdateCallback (XmlRpc::XmlRpcValue ¶ms, XmlRpc::XmlRpcValue &result) |
|
bool | registerSubscriber (const SubscriptionPtr &s, const std::string &datatype) |
|
bool | requestTopic (const std::string &topic, XmlRpc::XmlRpcValue &protos, XmlRpc::XmlRpcValue &ret) |
| Request a topic. More...
|
|
void | requestTopicCallback (XmlRpc::XmlRpcValue ¶ms, XmlRpc::XmlRpcValue &result) |
|
bool | unregisterPublisher (const std::string &topic) |
|
bool | unregisterSubscriber (const std::string &topic) |
|
Definition at line 63 of file topic_manager.h.
◆ TopicManager()
ros::TopicManager::TopicManager |
( |
| ) |
|
◆ ~TopicManager()
ros::TopicManager::~TopicManager |
( |
| ) |
|
◆ addSubCallback()
if it finds a pre-existing subscription to the same topic and of the same message type, it appends the Functor to the callback vector for that subscription. otherwise, it returns false, indicating that a new subscription needs to be created.
Definition at line 198 of file topic_manager.cpp.
◆ advertise()
◆ getAdvertisedTopics()
void ros::TopicManager::getAdvertisedTopics |
( |
V_string & |
topics | ) |
|
Get the list of topics advertised by this node.
- Parameters
-
[out] | topics | The advertised topics |
Definition at line 162 of file topic_manager.cpp.
◆ getBusInfo()
Compute the info for the node's connectivity.
This is the implementation of the xml-rpc getBusInfo function; it populates the XmlRpcValue object sent to it with various info about the node's connectivity.
Definition at line 937 of file topic_manager.cpp.
◆ getBusInfoCallback()
◆ getBusStats()
Compute the statistics for the node's connectivity.
This is the implementation of the xml-rpc getBusStats function; it populates the XmlRpcValue object sent to it with various statistics about the node's connectivity, bandwidth utilization, etc.
Definition at line 904 of file topic_manager.cpp.
◆ getBusStatsCallback()
◆ getNumPublishers()
size_t ros::TopicManager::getNumPublishers |
( |
const std::string & |
_topic | ) |
|
Return the number of publishers connected to this node on a particular topic.
- Parameters
-
_topic | the topic name to check |
- Returns
- the number of subscribers
Definition at line 883 of file topic_manager.cpp.
◆ getNumSubscribers()
size_t ros::TopicManager::getNumSubscribers |
( |
const std::string & |
_topic | ) |
|
Return the number of subscribers a node has for a particular topic:
- Parameters
-
_topic | The topic name to check |
- Returns
- number of subscribers
Definition at line 859 of file topic_manager.cpp.
◆ getNumSubscriptions()
size_t ros::TopicManager::getNumSubscriptions |
( |
| ) |
|
◆ getPublications()
Return the list of advertised topics for the node.
This is the implementation of the xml-rpc getPublications function; it populates the XmlRpcValue object sent to it with the list of advertised topics and their datatypes.
Definition at line 982 of file topic_manager.cpp.
◆ getPublicationsCallback()
◆ getSubscribedTopics()
void ros::TopicManager::getSubscribedTopics |
( |
V_string & |
topics | ) |
|
Get the list of topics subscribed to by this node.
- Parameters
-
[out] | The | subscribed topics |
Definition at line 172 of file topic_manager.cpp.
◆ getSubscriptions()
Return the list of subcriptions for the node.
This is the implementation of the xml-rpc getSubscriptions function; it populates the XmlRpcValue object sent to it with the list of subscribed topics and their datatypes.
Definition at line 962 of file topic_manager.cpp.
◆ getSubscriptionsCallback()
◆ incrementSequence()
void ros::TopicManager::incrementSequence |
( |
const std::string & |
_topic | ) |
|
◆ instance()
◆ isLatched()
bool ros::TopicManager::isLatched |
( |
const std::string & |
topic | ) |
|
◆ isShuttingDown()
bool ros::TopicManager::isShuttingDown |
( |
| ) |
|
|
inlineprivate |
◆ isTopicAdvertised()
bool ros::TopicManager::isTopicAdvertised |
( |
const std::string & |
topic | ) |
|
|
private |
◆ lookupPublication()
PublicationPtr ros::TopicManager::lookupPublication |
( |
const std::string & |
topic | ) |
|
Lookup an advertised topic.
This method iterates over advertised_topics, looking for one with name matching the given topic name. The advertised_topics_mutex is locked during this search. This method is only used internally.
- Parameters
-
topic | The topic name to look for. |
- Returns
- Pointer to the matching Publication, NULL if none is found.
Definition at line 186 of file topic_manager.cpp.
◆ lookupPublicationWithoutLock()
PublicationPtr ros::TopicManager::lookupPublicationWithoutLock |
( |
const std::string & |
topic | ) |
|
|
private |
◆ processPublishQueues()
void ros::TopicManager::processPublishQueues |
( |
| ) |
|
|
private |
◆ publish() [1/2]
template<typename M >
void ros::TopicManager::publish |
( |
const std::string & |
topic, |
|
|
const M & |
message |
|
) |
| |
|
inline |
◆ publish() [2/2]
◆ pubUpdate()
bool ros::TopicManager::pubUpdate |
( |
const std::string & |
topic, |
|
|
const std::vector< std::string > & |
pubs |
|
) |
| |
|
private |
Update local publisher lists.
Use this method to update address information for publishers on a given topic.
- Parameters
-
topic | The topic of interest |
pubs | The list of publishers to update. |
- Returns
- true on success, false otherwise.
Definition at line 550 of file topic_manager.cpp.
◆ pubUpdateCallback()
◆ registerSubscriber()
bool ros::TopicManager::registerSubscriber |
( |
const SubscriptionPtr & |
s, |
|
|
const std::string & |
datatype |
|
) |
| |
|
private |
◆ requestTopic()
Request a topic.
Negotiate a subscriber connection on a topic.
- Parameters
-
topic | The topic of interest. |
protos | List of transport protocols, in preference order |
ret | Return value |
- Returns
- true on success, false otherwise
- Todo:
- Consider making this private
Definition at line 588 of file topic_manager.cpp.
◆ requestTopicCallback()
◆ shutdown()
void ros::TopicManager::shutdown |
( |
| ) |
|
◆ start()
void ros::TopicManager::start |
( |
| ) |
|
◆ subscribe()
◆ unadvertise()
◆ unregisterPublisher()
bool ros::TopicManager::unregisterPublisher |
( |
const std::string & |
topic | ) |
|
|
private |
◆ unregisterSubscriber()
bool ros::TopicManager::unregisterSubscriber |
( |
const std::string & |
topic | ) |
|
|
private |
◆ unsubscribe()
◆ advertised_topic_names_
std::list<std::string> ros::TopicManager::advertised_topic_names_ |
|
private |
◆ advertised_topic_names_mutex_
boost::mutex ros::TopicManager::advertised_topic_names_mutex_ |
|
private |
◆ advertised_topics_
◆ advertised_topics_mutex_
boost::recursive_mutex ros::TopicManager::advertised_topics_mutex_ |
|
private |
◆ connection_manager_
◆ poll_manager_
◆ shutting_down_
volatile bool ros::TopicManager::shutting_down_ |
|
private |
◆ shutting_down_mutex_
boost::mutex ros::TopicManager::shutting_down_mutex_ |
|
private |
◆ subs_mutex_
boost::mutex ros::TopicManager::subs_mutex_ |
|
private |
◆ subscriptions_
◆ xmlrpc_manager_
The documentation for this class was generated from the following files:
roscpp
Author(s): Morgan Quigley, Josh Faust, Brian Gerkey, Troy Straszheim, Dirk Thomas
autogenerated on Mon Feb 28 2022 23:33:27