Class: OnebusawaySDK::Resources::ScheduleForRoute
- Inherits:
-
Object
- Object
- OnebusawaySDK::Resources::ScheduleForRoute
- Defined in:
- lib/onebusaway_sdk/resources/schedule_for_route.rb
Instance Method Summary collapse
-
#initialize(client:) ⇒ ScheduleForRoute
constructor
private
A new instance of ScheduleForRoute.
-
#retrieve(route_id, date: nil, request_options: {}) ⇒ OnebusawaySDK::Models::ScheduleForRouteRetrieveResponse
Some parameter documentations has been truncated, see Models::ScheduleForRouteRetrieveParams for more details.
Constructor Details
#initialize(client:) ⇒ ScheduleForRoute
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of ScheduleForRoute.
36 37 38 |
# File 'lib/onebusaway_sdk/resources/schedule_for_route.rb', line 36 def initialize(client:) @client = client end |
Instance Method Details
#retrieve(route_id, date: nil, request_options: {}) ⇒ OnebusawaySDK::Models::ScheduleForRouteRetrieveResponse
Some parameter documentations has been truncated, see Models::ScheduleForRouteRetrieveParams for more details.
Retrieve the full schedule for a route on a particular day
22 23 24 25 26 27 28 29 30 31 |
# File 'lib/onebusaway_sdk/resources/schedule_for_route.rb', line 22 def retrieve(route_id, params = {}) parsed, = OnebusawaySDK::ScheduleForRouteRetrieveParams.dump_request(params) @client.request( method: :get, path: ["api/where/schedule-for-route/%1$s.json", route_id], query: parsed, model: OnebusawaySDK::Models::ScheduleForRouteRetrieveResponse, options: ) end |