Class: JarvisbotSongfinder::UnknownSearchProvider
- Inherits:
-
Object
- Object
- JarvisbotSongfinder::UnknownSearchProvider
- Defined in:
- lib/jarvisbot_songfinder/providers/unknown_search_provider.rb
Overview
NullObject for handling cases where searching any other provider did not found anything
Instance Attribute Summary collapse
-
#errors ⇒ Object
readonly
Returns the value of attribute errors.
Instance Method Summary collapse
-
#initialize ⇒ UnknownSearchProvider
constructor
A new instance of UnknownSearchProvider.
- #valid? ⇒ Boolean
Constructor Details
#initialize ⇒ UnknownSearchProvider
Returns a new instance of UnknownSearchProvider.
9 10 11 |
# File 'lib/jarvisbot_songfinder/providers/unknown_search_provider.rb', line 9 def initialize @errors = [ReplyMessage::Search.not_found] end |
Instance Attribute Details
#errors ⇒ Object (readonly)
Returns the value of attribute errors.
7 8 9 |
# File 'lib/jarvisbot_songfinder/providers/unknown_search_provider.rb', line 7 def errors @errors end |
Instance Method Details
#valid? ⇒ Boolean
13 14 15 |
# File 'lib/jarvisbot_songfinder/providers/unknown_search_provider.rb', line 13 def valid? false end |