Class: Licensee::Matchers::Package
- Defined in:
- lib/licensee/matchers/package.rb
Constant Summary
Constants inherited from Matcher
Instance Attribute Summary
Attributes inherited from Matcher
Instance Method Summary collapse
Methods inherited from Matcher
Methods included from HashHelper
Constructor Details
This class inherits a constructor from Licensee::Matchers::Matcher
Instance Method Details
#confidence ⇒ Object
16 17 18 |
# File 'lib/licensee/matchers/package.rb', line 16 def confidence 90 end |
#license_property ⇒ Object
20 21 22 |
# File 'lib/licensee/matchers/package.rb', line 20 def license_property raise 'Not implemented' end |
#match ⇒ Object
6 7 8 9 10 11 12 13 14 |
# File 'lib/licensee/matchers/package.rb', line 6 def match return @match if defined? @match return if license_property.nil? || license_property.to_s.empty? @match = Licensee.licenses(hidden: true).find do |license| license.key == license_property end @match ||= License.find('other') end |