Class: Ratis::Stop

Inherits:
Object
  • Object
show all
Defined in:
lib/ratis/stop.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(params) ⇒ Stop

:description=>“JEFFERSON STREET/1ST AVE LIGHT RAIL STN”, :area=>“Phoenix”, :stopid=>“10013”, :atisstopid=>“10891”, :lat=>“33.448188”, :long=>“-112.075198”, :walkdist=>“0.08”, :walkdir=>“S”, :stopposition=>“O”, :heading=>“NB”, :side=>“Far”, :routedirs=>:routedir=>“LTRL-E”



12
13
14
15
16
17
18
19
20
21
22
23
24
25
# File 'lib/ratis/stop.rb', line 12

def initialize(params)
  @description   = params[:description]
  @area          = params[:area]
  @stop_id       = params[:stopid]
  @atis_stop_id  = params[:atisstopid]
  @latitude      = params[:lat]
  @longitude     = params[:long]
  @walk_dist     = params[:walkdist]
  @walk_dir      = params[:walkdir]
  @stop_position = params[:stopposition]
  @heading       = params[:heading]
  @side          = params[:side]
  @route_dirs    = params[:routedirs]
end

Instance Attribute Details

#areaObject

Returns the value of attribute area.



3
4
5
# File 'lib/ratis/stop.rb', line 3

def area
  @area
end

#atis_stop_idObject

Returns the value of attribute atis_stop_id.



3
4
5
# File 'lib/ratis/stop.rb', line 3

def atis_stop_id
  @atis_stop_id
end

#descriptionObject

Returns the value of attribute description.



3
4
5
# File 'lib/ratis/stop.rb', line 3

def description
  @description
end

#headingObject

Returns the value of attribute heading.



3
4
5
# File 'lib/ratis/stop.rb', line 3

def heading
  @heading
end

#latitudeObject Also known as: lat

Returns the value of attribute latitude.



3
4
5
# File 'lib/ratis/stop.rb', line 3

def latitude
  @latitude
end

#longitudeObject Also known as: lng

Returns the value of attribute longitude.



3
4
5
# File 'lib/ratis/stop.rb', line 3

def longitude
  @longitude
end

#route_dirsObject

Returns the value of attribute route_dirs.



3
4
5
# File 'lib/ratis/stop.rb', line 3

def route_dirs
  @route_dirs
end

#sideObject

Returns the value of attribute side.



3
4
5
# File 'lib/ratis/stop.rb', line 3

def side
  @side
end

#stop_idObject

Returns the value of attribute stop_id.



3
4
5
# File 'lib/ratis/stop.rb', line 3

def stop_id
  @stop_id
end

#stop_positionObject

Returns the value of attribute stop_position.



3
4
5
# File 'lib/ratis/stop.rb', line 3

def stop_position
  @stop_position
end

#walk_dirObject

Returns the value of attribute walk_dir.



3
4
5
# File 'lib/ratis/stop.rb', line 3

def walk_dir
  @walk_dir
end

#walk_distObject

Returns the value of attribute walk_dist.



3
4
5
# File 'lib/ratis/stop.rb', line 3

def walk_dist
  @walk_dist
end

Instance Method Details

#route_dirObject



27
28
29
# File 'lib/ratis/stop.rb', line 27

def route_dir
  @route_dirs[:routedir]
end