Class: FuzzyWhere::Configuration
- Inherits:
-
Object
- Object
- FuzzyWhere::Configuration
- Includes:
- ActiveSupport::Configurable
- Defined in:
- lib/fuzzy_where/config.rb
Overview
FuzzyWhere Configuration class
Instance Attribute Summary collapse
-
#membership_degree_column_name ⇒ String
Membership degree column name definition.
-
#predicates_file ⇒ Object
configuration file location.
-
#where_method_name ⇒ String
Search method name definition.
Instance Method Summary collapse
-
#fuzzy_predicate(key) ⇒ Hash
Return a fuzzy predicate definition.
Instance Attribute Details
#membership_degree_column_name ⇒ String
Returns membership degree column name definition.
30 |
# File 'lib/fuzzy_where/config.rb', line 30 config_accessor :membership_degree_column_name |
#predicates_file ⇒ Object
configuration file location
33 |
# File 'lib/fuzzy_where/config.rb', line 33 config_accessor :predicates_file |
#where_method_name ⇒ String
Returns search method name definition.
27 |
# File 'lib/fuzzy_where/config.rb', line 27 config_accessor :where_method_name |
Instance Method Details
#fuzzy_predicate(key) ⇒ Hash
Return a fuzzy predicate definition
38 39 40 41 |
# File 'lib/fuzzy_where/config.rb', line 38 def fuzzy_predicate(key) @fuzzy_predicates = load_yml(predicates_file) @fuzzy_predicates["#{key}"] end |