Class: SeeYouCup::Waypoint

Inherits:
Object
  • Object
show all
Defined in:
lib/see_you_cup/waypoint.rb

Constant Summary collapse

STYLE_MAP =
{
  0 => 'Unknown',
  1 => 'Waypoint',
  2 => 'Airfield with grass surface runway',
  3 => 'Outlanding',
  4 => 'Gliding airfield',
  5 => 'Airfield with solid surface runway',
  6 => 'Mountain Pass',
  7 => 'Mountain Top',
  8 => 'Transmitter Mast',
  9 => 'VOR',
  10 => 'NDB',
  11 => 'Cooling Tower',
  12 => 'Dam',
  13 => 'Tunnel',
  14 => 'Bridge',
  15 => 'Power Plant',
  16 => 'Castle',
  17 => 'Intersection'
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#codeObject

Returns the value of attribute code.



26
27
28
# File 'lib/see_you_cup/waypoint.rb', line 26

def code
  @code
end

#countryObject

Returns the value of attribute country.



26
27
28
# File 'lib/see_you_cup/waypoint.rb', line 26

def country
  @country
end

#descObject

Returns the value of attribute desc.



26
27
28
# File 'lib/see_you_cup/waypoint.rb', line 26

def desc
  @desc
end

#elevObject

Returns the value of attribute elev.



26
27
28
# File 'lib/see_you_cup/waypoint.rb', line 26

def elev
  @elev
end

#freqObject

Returns the value of attribute freq.



26
27
28
# File 'lib/see_you_cup/waypoint.rb', line 26

def freq
  @freq
end

#latObject

Returns the value of attribute lat.



27
28
29
# File 'lib/see_you_cup/waypoint.rb', line 27

def lat
  @lat
end

#lonObject

Returns the value of attribute lon.



27
28
29
# File 'lib/see_you_cup/waypoint.rb', line 27

def lon
  @lon
end

#nameObject

Returns the value of attribute name.



26
27
28
# File 'lib/see_you_cup/waypoint.rb', line 26

def name
  @name
end

#rwydirObject

Returns the value of attribute rwydir.



26
27
28
# File 'lib/see_you_cup/waypoint.rb', line 26

def rwydir
  @rwydir
end

#rwylenObject

Returns the value of attribute rwylen.



26
27
28
# File 'lib/see_you_cup/waypoint.rb', line 26

def rwylen
  @rwylen
end

Instance Method Details

#styleObject



41
42
43
# File 'lib/see_you_cup/waypoint.rb', line 41

def style
  STYLE_MAP[@style]
end

#style=(style) ⇒ Object



37
38
39
# File 'lib/see_you_cup/waypoint.rb', line 37

def style=(style)
  @style = style.to_i
end