module TokyoMetro::Modules::Common::Info::Decision::TrainType

Public Instance Methods

express?() click to toggle source
# File lib/tokyo_metro/modules/common/info/decision/train_type.rb, line 34
def express?
  __express__? or train_type_of?( "odpt.TrainType:Toei.Express" )
end
is_limited_express_or_romance_car?()
is_romance_car_specific_train?()
limited_express_or_romance_car?() click to toggle source

@!group ロマンスカー関連

# File lib/tokyo_metro/modules/common/info/decision/train_type.rb, line 67
def limited_express_or_romance_car?
  limited_express? or romance_car? or romance_car_specific_train?
end
local?() click to toggle source
# File lib/tokyo_metro/modules/common/info/decision/train_type.rb, line 30
def local?
  __local__? or train_type_of?( "odpt.TrainType:Toei.Local" )
end
romance_car_specific_train?() click to toggle source
# File lib/tokyo_metro/modules/common/info/decision/train_type.rb, line 80
def romance_car_specific_train?
  train_of?( ::TokyoMetro::Modules::Common::Dictionary::RomanceCar.train_names.values )
end

Private Instance Methods

change_into?( on: nil , at: nil ) click to toggle source

「化け種別」の判定 @todo 具体的な定義

# File lib/tokyo_metro/modules/common/info/decision/train_type.rb, line 104
def change_into?( on: nil , at: nil )
  if on.present?
    nil
  else
    nil
  end
end
is_train_of?( *args , compared )
Alias for: train_of?
is_train_type_of?( *args , compared )
Alias for: train_type_of?
train_of?( *args , compared ) click to toggle source
# File lib/tokyo_metro/modules/common/info/decision/train_type.rb, line 96
def train_of?( *args , compared )
  compare_base( args , compared )
end
Also aliased as: is_train_of?
train_type_of?( *args , compared ) click to toggle source

@!endgroup

# File lib/tokyo_metro/modules/common/info/decision/train_type.rb, line 90
def train_type_of?( *args , compared )
  compare_base( args , compared )
end
Also aliased as: is_train_type_of?