Sha256: 636c814457701aab77d018f7f4930f1aebf6b315ae7a9bad6f4715a4fa934f21
Contents?: true
Size: 861 Bytes
Versions: 2
Compression:
Stored size: 861 Bytes
Contents
module Csvlint module ErrorCollector attr_reader :errors, :warnings, :info_messages def build_errors(type, category = nil, row = nil, column = nil, content = nil, constraints = {}) @errors << Csvlint::ErrorMessage.new(type, category, row, column, content, constraints) end def build_warnings(type, category = nil, row = nil, column = nil, content = nil, constraints = {}) @warnings << Csvlint::ErrorMessage.new(type, category, row, column, content, constraints) end def build_info_messages(type, category = nil, row = nil, column = nil, content = nil, constraints = {}) @info_messages << Csvlint::ErrorMessage.new(type, category, row, column, content, constraints) end def valid? errors.empty? end def reset @errors = [] @warnings = [] @info_messages = [] end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
csvlint-0.1.1 | lib/csvlint/error_collector.rb |
csvlint-0.1.0 | lib/csvlint/error_collector.rb |