Class: Warning

Inherits:
Weatherzone::Resource show all
Includes:
Weatherzone::Helpers::DateParser
Defined in:
lib/weatherzone/resources/warning.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Weatherzone::Helpers::DateParser

included

Methods inherited from Weatherzone::Resource

has_attribute, has_elements, inherited, #settings

Instance Attribute Details

#idObject (readonly)

Override id and type



11
12
13
# File 'lib/weatherzone/resources/warning.rb', line 11

def id
  @id
end

#typeObject (readonly)

Override id and type



11
12
13
# File 'lib/weatherzone/resources/warning.rb', line 11

def type
  @type
end

Instance Method Details

#eql?(other) ⇒ Boolean

Returns:

  • (Boolean)


17
18
19
# File 'lib/weatherzone/resources/warning.rb', line 17

def eql?(other)
  self.id == other.id
end

#hashObject



13
14
15
# File 'lib/weatherzone/resources/warning.rb', line 13

def hash
  id.hash
end