Class: Linguist::NegativePattern
- Inherits:
-
Object
- Object
- Linguist::NegativePattern
- Defined in:
- lib/linguist/heuristics.rb
Instance Method Summary collapse
-
#initialize(pat) ⇒ NegativePattern
constructor
A new instance of NegativePattern.
- #match(input) ⇒ Object
Constructor Details
#initialize(pat) ⇒ NegativePattern
Returns a new instance of NegativePattern.
162 163 164 |
# File 'lib/linguist/heuristics.rb', line 162 def initialize(pat) @pat = pat end |
Instance Method Details
#match(input) ⇒ Object
166 167 168 |
# File 'lib/linguist/heuristics.rb', line 166 def match(input) return !@pat.match(input) end |