Class: Licensee::Matchers::Exact
- Inherits:
-
Object
- Object
- Licensee::Matchers::Exact
- Defined in:
- lib/licensee/matchers/exact_matcher.rb
Instance Method Summary collapse
- #confidence ⇒ Object
-
#initialize(file) ⇒ Exact
constructor
A new instance of Exact.
- #match ⇒ Object
Constructor Details
#initialize(file) ⇒ Exact
4 5 6 |
# File 'lib/licensee/matchers/exact_matcher.rb', line 4 def initialize(file) @file = file end |
Instance Method Details
#confidence ⇒ Object
12 13 14 |
# File 'lib/licensee/matchers/exact_matcher.rb', line 12 def confidence 100 end |
#match ⇒ Object
8 9 10 |
# File 'lib/licensee/matchers/exact_matcher.rb', line 8 def match Licensee.licenses(:hidden => true).find { |l| l.wordset == @file.wordset } end |