Class: Arel::Nodes::And
- Defined in:
- lib/ransack/adapters/active_record/3.0/compat.rb
Instance Attribute Summary collapse
-
#children ⇒ Object
readonly
Returns the value of attribute children.
Instance Method Summary collapse
-
#initialize(children, right = nil) ⇒ And
constructor
A new instance of And.
- #left ⇒ Object
- #right ⇒ Object
Methods inherited from Node
Constructor Details
#initialize(children, right = nil) ⇒ And
Returns a new instance of And.
46 47 48 49 50 51 |
# File 'lib/ransack/adapters/active_record/3.0/compat.rb', line 46 def initialize children, right = nil unless Array === children children = [children, right] end @children = children end |
Instance Attribute Details
#children ⇒ Object (readonly)
Returns the value of attribute children.
44 45 46 |
# File 'lib/ransack/adapters/active_record/3.0/compat.rb', line 44 def children @children end |
Instance Method Details
#left ⇒ Object
53 54 55 |
# File 'lib/ransack/adapters/active_record/3.0/compat.rb', line 53 def left children.first end |
#right ⇒ Object
57 58 59 |
# File 'lib/ransack/adapters/active_record/3.0/compat.rb', line 57 def right children[1] end |