Class: JarvisbotSongfinder::SearchQuery
- Inherits:
-
Object
- Object
- JarvisbotSongfinder::SearchQuery
- Defined in:
- lib/jarvisbot_songfinder/helpers/search_query.rb
Overview
Reponsible for handling search (words) based requests
JarvisbotSongfinder::SearchQuery.new("Paramore Misery").track.length
# => 211
Instance Method Summary collapse
-
#initialize(query, config: JarvisbotSongfinder.configuration) ⇒ SearchQuery
constructor
A new instance of SearchQuery.
- #track ⇒ Object
Constructor Details
#initialize(query, config: JarvisbotSongfinder.configuration) ⇒ SearchQuery
Returns a new instance of SearchQuery.
8 9 10 11 12 |
# File 'lib/jarvisbot_songfinder/helpers/search_query.rb', line 8 def initialize(query, config: JarvisbotSongfinder.configuration) @query = query @config = config @provider = select_provider end |
Instance Method Details
#track ⇒ Object
14 15 16 |
# File 'lib/jarvisbot_songfinder/helpers/search_query.rb', line 14 def track @provider end |