Class: Yweather::Wind

Inherits:
Object
  • Object
show all
Defined in:
lib/yweather/wind.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(data) ⇒ Wind

Returns a new instance of Wind.



8
9
10
11
12
# File 'lib/yweather/wind.rb', line 8

def initialize(data)
  @chill = data[:chill].to_i
  @direction = data[:direction].to_i
  @speed = data[:speed].to_i
end

Instance Attribute Details

#chillObject (readonly)

Returns the value of attribute chill.



4
5
6
# File 'lib/yweather/wind.rb', line 4

def chill
  @chill
end

#directionObject (readonly)

Returns the value of attribute direction.



5
6
7
# File 'lib/yweather/wind.rb', line 5

def direction
  @direction
end

#speedObject (readonly)

Returns the value of attribute speed.



6
7
8
# File 'lib/yweather/wind.rb', line 6

def speed
  @speed
end