class ActiveExcel::ValidatedRecords

Public Class Methods

new(table_name, records) click to toggle source
# File lib/active_excel/validated_records.rb, line 5
def initialize(table_name, records)
  @table_name = table_name
  @records    = records
end

Public Instance Methods

all_records() click to toggle source
# File lib/active_excel/validated_records.rb, line 10
def all_records
  @records
end
invalid_records() click to toggle source
# File lib/active_excel/validated_records.rb, line 18
def invalid_records
  @records.reject(&:valid?)
end
valid_records() click to toggle source
# File lib/active_excel/validated_records.rb, line 14
def valid_records
  @records.select(&:valid?)
end