Class: ActsAsRecursiveTree::Options::Values::SingleValue

Inherits:
Base
  • Object
show all
Defined in:
lib/acts_as_recursive_tree/options/values.rb

Direct Known Subclasses

ActiveRecord

Instance Attribute Summary

Attributes inherited from Base

#config, #value

Instance Method Summary collapse

Methods inherited from Base

#initialize, #prepared_value

Constructor Details

This class inherits a constructor from ActsAsRecursiveTree::Options::Values::Base

Instance Method Details

#apply_negated_to(attribute) ⇒ Object



28
29
30
# File 'lib/acts_as_recursive_tree/options/values.rb', line 28

def apply_negated_to(attribute)
  attribute.not_eq(prepared_value)
end

#apply_to(attribute) ⇒ Object



24
25
26
# File 'lib/acts_as_recursive_tree/options/values.rb', line 24

def apply_to(attribute)
  attribute.eq(prepared_value)
end