class Lib::TL1::Message::Field::AlarmCode
Constants
- ALARM_CODE
Public Class Methods
new(field)
click to toggle source
Calls superclass method
# File lib/lib/tl1/message/field/alarm_code.rb, line 20 def initialize(field) raise ArgumentError, "Unknown Alarm Code - #{field}" unless ALARM_CODE.key? field.to_s.upcase.to_sym super field.to_s.upcase.to_sym end
Public Instance Methods
description()
click to toggle source
# File lib/lib/tl1/message/field/alarm_code.rb, line 30 def description ALARM_CODE[@field] end
to_s()
click to toggle source
# File lib/lib/tl1/message/field/alarm_code.rb, line 26 def to_s @field.to_s.upcase end
to_sym()
click to toggle source
# File lib/lib/tl1/message/field/alarm_code.rb, line 34 def to_sym @field end