Sha256: e4712985173b12d8c8e547bc05744d94d5bceadac1963ecda8a336e6b6f134a0

Contents?: true

Size: 369 Bytes

Versions: 11

Compression:

Stored size: 369 Bytes

Contents

module Licensee
  module Matchers
    class Exact
      attr_reader :file

      def initialize(file)
        @file = file
      end

      def match
        Licensee.licenses(hidden: true).find do |license|
          license.length == @file.length && license.wordset == @file.wordset
        end
      end

      def confidence
        100
      end
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
licensee-8.9.2 lib/licensee/matchers/exact_matcher.rb
licensee-8.9.0 lib/licensee/matchers/exact_matcher.rb
licensee-8.8.5 lib/licensee/matchers/exact_matcher.rb
licensee-8.8.4 lib/licensee/matchers/exact_matcher.rb
licensee-8.8.3 lib/licensee/matchers/exact_matcher.rb
licensee-8.8.2 lib/licensee/matchers/exact_matcher.rb
licensee-8.8.1 lib/licensee/matchers/exact_matcher.rb
licensee-8.8.0 lib/licensee/matchers/exact_matcher.rb
licensee-8.7.0 lib/licensee/matchers/exact_matcher.rb
licensee-8.6.1 lib/licensee/matchers/exact_matcher.rb
licensee-8.6.0 lib/licensee/matchers/exact_matcher.rb