Class: ROS::Master::Publisher

Inherits:
Object
  • Object
show all
Defined in:
lib/ros/master.rb

Overview

Publisher struct for Master

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Constructor Details

- (Publisher) initialize(caller_id, topic_name, topic_type, api)

Returns a new instance of Publisher

Parameters:

  • caller_id (String)

    caller_id of publisher node

  • topic_name (String)

    name of topic

  • api (String)

    XMLRPC URI of publisher node



132
133
134
135
136
137
# File 'lib/ros/master.rb', line 132

def initialize(caller_id, topic_name, topic_type, api)
  @caller_id = caller_id
  @name = topic_name
  @msg_type = topic_type
  @api = api
end

Instance Attribute Details

- (String) api

Get XMLRPC API URI

Returns:

  • (String)

    URI of this publisher (XMLPRC URI).



153
154
155
# File 'lib/ros/master.rb', line 153

def api
  @api
end

- (String) caller_id

Get caller_id.

Returns:

  • (String)

    caller_id



141
142
143
# File 'lib/ros/master.rb', line 141

def caller_id
  @caller_id
end

- (String) msg_type

Get type of topic.

Returns:

  • (String)

    type of topic in String.



149
150
151
# File 'lib/ros/master.rb', line 149

def msg_type
  @msg_type
end

- (String) name

Get the name of topic.

Returns:

  • (String)

    name of topic.



145
146
147
# File 'lib/ros/master.rb', line 145

def name
  @name
end