Class: Renalware::UKRDC::Incoming::FileList
- Inherits:
-
Object
- Object
- Renalware::UKRDC::Incoming::FileList
- Defined in:
- app/models/renalware/ukrdc/incoming/file_list.rb
Instance Method Summary collapse
-
#each_file ⇒ Object
Helper which yields each file in the incoming folder.
Instance Method Details
#each_file ⇒ Object
Helper which yields each file in the incoming folder.
12 13 14 15 16 17 |
# File 'app/models/renalware/ukrdc/incoming/file_list.rb', line 12 def each_file Dir.glob(paths.incoming.join(pattern)).sort.each do |filepath| filename = File.basename(filepath) yield(Pathname(filepath), filename) if block_given? end end |