Sha256: 57243f1883782591456545b81426394b2b1f7f6a73b3684a37816dd7e363b7ee

Contents?: true

Size: 588 Bytes

Versions: 1

Compression:

Stored size: 588 Bytes

Contents

# 乗り換え可能路線の一覧を扱うクラス
class TokyoMetro::Api::Station::Info::ConnectingRailwayLine::List < TokyoMetro::Api::Station::Info::Common::List

  def self.factory_for_seeding_this_class
    factory_for_seeding_connecting_railway_lines_of_each_station
  end

  def set_index_in_station!
    self.each.with_index(1) do | connecting_railway_line , i |
      connecting_railway_line.send( :set_index_in_station , i )
    end
    return self
  end

  def sort!
    self.sort_by!( &:index_in_station )
  end

  def railway_lines
    self.map( &:railway_line )
  end

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
tokyo_metro-0.10.1 lib/tokyo_metro/api/station/info/connecting_railway_line/list.rb