class NdrImport::UniversalImporterHelper::TableEnumProxy
Helper class to allow multiple source enumerators to contribute to one overall table.
Public Class Methods
new()
click to toggle source
# File lib/ndr_import/universal_importer_helper.rb, line 14 def initialize @table_enums = [] end
Public Instance Methods
add_table_enum(table_enum)
click to toggle source
# File lib/ndr_import/universal_importer_helper.rb, line 18 def add_table_enum(table_enum) @table_enums << table_enum end
each(&block)
click to toggle source
# File lib/ndr_import/universal_importer_helper.rb, line 22 def each(&block) return enum_for(:each) unless block @table_enums.each { |table_enum| table_enum.each(&block) } end