Class: Streamer::Finder
- Inherits:
-
Object
- Object
- Streamer::Finder
- Extended by:
- Forwardable
- Defined in:
- lib/streamer/finder.rb
Overview
Finder maintains a consistent interface for all of the fact_providers It allows the Stream to have a consistent finding pattern.
Instance Attribute Summary collapse
-
#fact_provider ⇒ Object
readonly
Returns the value of attribute fact_provider.
Instance Method Summary collapse
-
#initialize(provider = nil) ⇒ Finder
constructor
A new instance of Finder.
Constructor Details
#initialize(provider = nil) ⇒ Finder
Returns a new instance of Finder.
9 10 11 12 |
# File 'lib/streamer/finder.rb', line 9 def initialize(provider = nil) return @fact_provider = provider if provider @fact_provider = Streamer::FactProviders::HashProvider.new end |
Instance Attribute Details
#fact_provider ⇒ Object (readonly)
Returns the value of attribute fact_provider.
6 7 8 |
# File 'lib/streamer/finder.rb', line 6 def fact_provider @fact_provider end |