Class: RSMP::Alarm

Inherits:
Message show all
Defined in:
lib/rsmp/alarm.rb,
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 = {}) ⇒ Alarm

Returns a new instance of Alarm.


6
7
8
9
10
11
12
# File 'lib/rsmp/alarm.rb', line 6

def initialize code: code, blocked: blocked=false, suspended: suspended=false, acknowledged: acknowledged=false
  @code = code
  @code = code
  @blocked = blocked
  @suspended = suspended
  @acknowledged = acknowledged
end