Sha256: 200484063280a3d2c99323ffab8942f832665c1db3f96be067114cb024db15f3

Contents?: true

Size: 463 Bytes

Versions: 1

Compression:

Stored size: 463 Bytes

Contents

module Pluginscan
  Finding = Struct.new(:lineno, :line, :match, :ignored)

  class CheckFindings
    attr_reader :findings
    attr_reader :check

    def initialize(check)
      @check = check
      @findings = []
    end

    def add(more_findings)
      @findings += more_findings
    end

    def any_findings?
      !findings.empty?
    end

    def all_ignored?
      @findings.all?(&:ignored)
    end

    def count
      findings.count
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
pluginscan-0.9.0 lib/pluginscan/reports/issues_report/issues_models/check_findings.rb