Class: Crawler::Cinema::Provider::Entries
- Inherits:
-
Object
- Object
- Crawler::Cinema::Provider::Entries
- Includes:
- Enumerable
- Defined in:
- lib/crawler/cinema/provider.rb
Instance Method Summary collapse
- #each ⇒ Object
-
#initialize(method_name) ⇒ Entries
constructor
A new instance of Entries.
Constructor Details
#initialize(method_name) ⇒ Entries
Returns a new instance of Entries.
18 19 20 |
# File 'lib/crawler/cinema/provider.rb', line 18 def initialize(method_name) @method_name = method_name end |
Instance Method Details
#each ⇒ Object
22 23 24 25 26 27 28 29 |
# File 'lib/crawler/cinema/provider.rb', line 22 def each providers = Provider.new providers.each do |provider| provider.public_send(@method_name).each do |entry| yield entry end end end |