class Topic(object):
Known subclasses: niryo_libraries.rospy.Publisher
, niryo_libraries.rospy.Subscriber
Constructor: Topic(name, data_class, reg_type)
Base class of L{Publisher} and L{Subscriber}
Method | __init__ |
@param name: graph resource name of topic, e.g. 'laser'. @type name: str @param data_class: message class for serialization @type data_class: L{Message} @param reg_type Registration.PUB or Registration... |
Method | get |
get the number of connections to other ROS nodes for this topic. For a Publisher, this corresponds to the number of nodes subscribing. For a Subscriber, the number of publishers. @return: number of connections @rtype: int... |
Method | unregister |
unpublish/unsubscribe from topic. Topic instance is no longer valid after this call. Additional calls to unregister() have no effect. |
Instance Variable | data |
Undocumented |
Instance Variable | impl |
Undocumented |
Instance Variable | md5sum |
Undocumented |
Instance Variable | name |
Undocumented |
Instance Variable | reg |
Undocumented |
Instance Variable | resolved |
Undocumented |
Instance Variable | type |
Undocumented |
niryo_libraries.rospy.Publisher
, niryo_libraries.rospy.Subscriber
@param name: graph resource name of topic, e.g. 'laser'. @type name: str @param data_class: message class for serialization @type data_class: L{Message} @param reg_type Registration.PUB or Registration.SUB @type reg_type: str @raise ValueError: if parameters are invalid
get the number of connections to other ROS nodes for this topic. For a Publisher, this corresponds to the number of nodes subscribing. For a Subscriber, the number of publishers. @return: number of connections @rtype: int
niryo_libraries.rospy.Subscriber
unpublish/unsubscribe from topic. Topic instance is no longer valid after this call. Additional calls to unregister() have no effect.