Class: WeatherLink::RecordType

Inherits:
Struct
  • Object
show all
Defined in:
lib/weatherlink.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#idObject

Returns the value of attribute id



52
53
54
# File 'lib/weatherlink.rb', line 52

def id
  @id
end

#nameObject

Returns the value of attribute name



52
53
54
# File 'lib/weatherlink.rb', line 52

def name
  @name
end

#systemObject

Returns the value of attribute system



52
53
54
# File 'lib/weatherlink.rb', line 52

def system
  @system
end

#typeObject

Returns the value of attribute type



52
53
54
# File 'lib/weatherlink.rb', line 52

def type
  @type
end

Instance Method Details

#archive?Boolean



61
62
63
# File 'lib/weatherlink.rb', line 61

def archive?
  type == :archive
end

#current_conditions?Boolean



57
58
59
# File 'lib/weatherlink.rb', line 57

def current_conditions?
  type == :current_conditions
end

#descriptionObject



53
54
55
# File 'lib/weatherlink.rb', line 53

def description
  "#{system.name} - #{name}"
end

#health?Boolean



65
66
67
# File 'lib/weatherlink.rb', line 65

def health?
  type == :health
end