Class: RSMP::Version

Inherits:
Message show all
Defined in:
lib/rsmp/message.rb

Instance Attribute Summary

Attributes inherited from Message

#attributes, #direction, #json, #now, #out, #timestamp

Instance Method Summary collapse

Methods inherited from Message

#attribute, bin_to_chars, build, #ensure_message_id, #generate_json, #m_id, #m_id_short, make_m_id, parse_attributes, shorten_m_id, #type, #valid?, #validate, #validate_id, validate_message_type, #validate_type

Methods included from Inspect

#inspect, #inspector

Constructor Details

#initialize(attributes = {}) ⇒ Version

Returns a new instance of Version.


160
161
162
163
164
# File 'lib/rsmp/message.rb', line 160

def initialize attributes = {}
  super({
    "type" => "Version",
  }.merge attributes)
end

Instance Method Details

#versionsObject


166
167
168
# File 'lib/rsmp/message.rb', line 166

def versions
  attribute("RSMP").map{ |item| item["vers"] }
end