Class: FuzzyMatch::Rule::StopWord
- Inherits:
-
FuzzyMatch::Rule
- Object
- FuzzyMatch::Rule
- FuzzyMatch::Rule::StopWord
- Defined in:
- lib/fuzzy_match/rule/stop_word.rb
Overview
A stop word is ignored
Instance Attribute Summary
Attributes inherited from FuzzyMatch::Rule
Instance Method Summary collapse
-
#apply!(str) ⇒ Object
Destructively remove stop words from the string.
Methods inherited from FuzzyMatch::Rule
Constructor Details
This class inherits a constructor from FuzzyMatch::Rule
Instance Method Details
#apply!(str) ⇒ Object
Destructively remove stop words from the string
6 7 8 |
# File 'lib/fuzzy_match/rule/stop_word.rb', line 6 def apply!(str) str.gsub! regexp, '' end |