Class: OnebusawaySDK::Resources::SearchForStop
- Inherits:
-
Object
- Object
- OnebusawaySDK::Resources::SearchForStop
- Defined in:
- lib/onebusaway_sdk/resources/search_for_stop.rb
Instance Method Summary collapse
-
#initialize(client:) ⇒ SearchForStop
constructor
private
A new instance of SearchForStop.
-
#list(input: , max_count: nil, request_options: {}) ⇒ OnebusawaySDK::Models::SearchForStopListResponse
Search for a stop based on its name.
Constructor Details
#initialize(client:) ⇒ SearchForStop
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 SearchForStop.
33 34 35 |
# File 'lib/onebusaway_sdk/resources/search_for_stop.rb', line 33 def initialize(client:) @client = client end |
Instance Method Details
#list(input: , max_count: nil, request_options: {}) ⇒ OnebusawaySDK::Models::SearchForStopListResponse
Search for a stop based on its name.
19 20 21 22 23 24 25 26 27 28 |
# File 'lib/onebusaway_sdk/resources/search_for_stop.rb', line 19 def list(params) parsed, = OnebusawaySDK::SearchForStopListParams.dump_request(params) @client.request( method: :get, path: "api/where/search/stop.json", query: parsed.transform_keys(max_count: "maxCount"), model: OnebusawaySDK::Models::SearchForStopListResponse, options: ) end |