Public Member Functions
Node Class Reference

A node can advertise and subscribe topics, publish on advertised topics and listen to subscribed topics. More...

#include <Node.hh>

List of all members.

Public Member Functions

 Node ()
 Constructor.
virtual ~Node ()
 Destructor.
void Init (const std::string &_space="")
 Init the node.
void Fini ()
std::string GetTopicNamespace () const
 Get the topic namespace for this node.
std::string DecodeTopicName (const std::string &topic)
 Decode a topic name.
std::string EncodeTopicName (const std::string &topic)
 Encode a topic name.
unsigned int GetId () const
 Get the unique ID of the node.
void ProcessPublishers ()
 Process all publishers, which has each publisher send it's most recent message over the wire.
void ProcessIncoming ()
template<typename M >
transport::PublisherPtr Advertise (const std::string &topic, unsigned int _queueLimit=10, bool _latch=false)
 Adverise a topic.
template<typename M , typename T >
SubscriberPtr Subscribe (const std::string &topic, void(T::*fp)(const boost::shared_ptr< M const > &), T *obj, bool _latching=false)
 Subscribe to a topic, and return data on the callback.
template<typename M >
SubscriberPtr Subscribe (const std::string &topic, void(*fp)(const boost::shared_ptr< M const > &), bool _latching=false)
 Subscribe to a topic, and return data on the callback.
bool HandleData (const std::string &_topic, const std::string &_msg)
std::string GetMsgType (const std::string &_topic) const
 Get the message type for a topic.

Detailed Description

A node can advertise and subscribe topics, publish on advertised topics and listen to subscribed topics.


Member Function Documentation

std::string GetTopicNamespace ( ) const

Get the topic namespace for this node.

Returns:
The namespace
void Init ( const std::string &  _space = "")

Init the node.

Parameters:
spaceSet the global namespace of all topics. If left blank, the topic will initialize to the first namespace on the Master
void ProcessPublishers ( )

Process all publishers, which has each publisher send it's most recent message over the wire.

This is for internal use only


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