Class: Datahen::Scraper::Seeder
- Inherits:
-
Object
- Object
- Datahen::Scraper::Seeder
- Defined in:
- lib/datahen/scraper/seeder.rb
Class Method Summary collapse
Class Method Details
.exec_seeder(filename, job_id = nil, save = false, keep_outputs = false) ⇒ Object
5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/datahen/scraper/seeder.rb', line 5 def self.exec_seeder(filename, job_id=nil, save=false, keep_outputs=false) extname = File.extname(filename) case extname when '.rb' executor = RubySeederExecutor.new( filename: filename, job_id: job_id, keep_outputs: keep_outputs ) executor.exec_seeder(save) else puts "Unable to find a seeder executor for file type \"#{extname}\"" end end |