Class: TokyoMetro::ApiProcessor::RealTimeInfos::RailwayLine::Info
- Inherits:
-
Object
- Object
- TokyoMetro::ApiProcessor::RealTimeInfos::RailwayLine::Info
- Defined in:
- lib/tokyo_metro/api_processor/real_time_infos/info.rb
Instance Attribute Summary collapse
-
#http_client ⇒ Object
readonly
Returns the value of attribute http_client.
-
#railway_line ⇒ Object
readonly
Returns the value of attribute railway_line.
Instance Method Summary collapse
- #dc_date_of_train_operation_info ⇒ Object (also: #dc_date_time_of_train_operation_info)
- #has_any_train_location? ⇒ Boolean
- #has_train_operation_info? ⇒ Boolean
-
#initialize(railway_line, http_client) ⇒ Info
constructor
A new instance of Info.
- #railway_line_same_as ⇒ Object
Constructor Details
#initialize(railway_line, http_client) ⇒ Info
Returns a new instance of Info.
3 4 5 6 |
# File 'lib/tokyo_metro/api_processor/real_time_infos/info.rb', line 3 def initialize( railway_line , http_client ) @railway_line = railway_line @http_client = http_client end |
Instance Attribute Details
#http_client ⇒ Object (readonly)
Returns the value of attribute http_client.
9 10 11 |
# File 'lib/tokyo_metro/api_processor/real_time_infos/info.rb', line 9 def http_client @http_client end |
#railway_line ⇒ Object (readonly)
Returns the value of attribute railway_line.
8 9 10 |
# File 'lib/tokyo_metro/api_processor/real_time_infos/info.rb', line 8 def railway_line @railway_line end |
Instance Method Details
#dc_date_of_train_operation_info ⇒ Object Also known as: dc_date_time_of_train_operation_info
15 16 17 |
# File 'lib/tokyo_metro/api_processor/real_time_infos/info.rb', line 15 def dc_date_of_train_operation_info @train_operation_info.dc_date end |
#has_any_train_location? ⇒ Boolean
20 21 22 |
# File 'lib/tokyo_metro/api_processor/real_time_infos/info.rb', line 20 def has_any_train_location? @train_location_infos.present? end |
#has_train_operation_info? ⇒ Boolean
11 12 13 |
# File 'lib/tokyo_metro/api_processor/real_time_infos/info.rb', line 11 def has_train_operation_info? @trian_information.present? end |
#railway_line_same_as ⇒ Object
24 25 26 |
# File 'lib/tokyo_metro/api_processor/real_time_infos/info.rb', line 24 def railway_line_same_as @railway_line.same_as end |