Class: PistePal::DayPass

Inherits:
Object
  • Object
show all
Defined in:
lib/piste_pal/day_pass.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#dateObject

Returns the value of attribute date.



3
4
5
# File 'lib/piste_pal/day_pass.rb', line 3

def date
  @date
end

#distance(system = "imperial") ⇒ Object

convert meters to km / miles



36
37
38
# File 'lib/piste_pal/day_pass.rb', line 36

def distance
  @distance
end

#liftsObject

Returns the value of attribute lifts.



3
4
5
# File 'lib/piste_pal/day_pass.rb', line 3

def lifts
  @lifts
end

#longest_run(system = "imperial") ⇒ Object

convert meters to miles



75
76
77
# File 'lib/piste_pal/day_pass.rb', line 75

def longest_run
  @longest_run
end

#maximum_speed(system = "imperial") ⇒ Object

convert mp/h to km/h



10
11
12
# File 'lib/piste_pal/day_pass.rb', line 10

def maximum_speed
  @maximum_speed
end

#peak_altitude(system = "imperial") ⇒ Object

convert meters to feet



23
24
25
# File 'lib/piste_pal/day_pass.rb', line 23

def peak_altitude
  @peak_altitude
end

#resortObject

Returns the value of attribute resort.



3
4
5
# File 'lib/piste_pal/day_pass.rb', line 3

def resort
  @resort
end

#runsObject

Returns the value of attribute runs.



3
4
5
# File 'lib/piste_pal/day_pass.rb', line 3

def runs
  @runs
end

#tallest_run(system = "imperial") ⇒ Object

convert meters to feet



62
63
64
# File 'lib/piste_pal/day_pass.rb', line 62

def tallest_run
  @tallest_run
end

#trackpointsObject

Returns the value of attribute trackpoints.



3
4
5
# File 'lib/piste_pal/day_pass.rb', line 3

def trackpoints
  @trackpoints
end

#vertical(system = "imperial") ⇒ Object

convert meters to feet



49
50
51
# File 'lib/piste_pal/day_pass.rb', line 49

def vertical
  @vertical
end

Class Method Details

.purchase(file_content) ⇒ Object



5
6
7
# File 'lib/piste_pal/day_pass.rb', line 5

def self.purchase file_content
  new(file_content: file_content)
end