Module: FuzzyInfer::ActiveRecordInstanceMethods
- Defined in:
- lib/fuzzy_infer/active_record_instance_methods.rb
Instance Method Summary collapse
-
#fuzzy_infer(*targets) ⇒ Object
Shortcut to creating a FIM and immediately calling it.
-
#fuzzy_inference_machine(*targets) ⇒ Object
Returns a new FuzzyInferenceMachine instance that can infer this target (field).
Instance Method Details
#fuzzy_infer(*targets) ⇒ Object
Shortcut to creating a FIM and immediately calling it
9 10 11 |
# File 'lib/fuzzy_infer/active_record_instance_methods.rb', line 9 def fuzzy_infer(*targets) fuzzy_inference_machine(*targets).infer end |
#fuzzy_inference_machine(*targets) ⇒ Object
Returns a new FuzzyInferenceMachine instance that can infer this target (field)
4 5 6 |
# File 'lib/fuzzy_infer/active_record_instance_methods.rb', line 4 def fuzzy_inference_machine(*targets) FuzzyInferenceMachine.new self, targets, Registry.config_for(self.class.name, targets) end |