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.
49 50 51 52 53 54 |
# File 'lib/ransack/adapters/active_record/3.0/compat.rb', line 49 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.
47 48 49 |
# File 'lib/ransack/adapters/active_record/3.0/compat.rb', line 47 def children @children end |
Instance Method Details
#left ⇒ Object
56 57 58 |
# File 'lib/ransack/adapters/active_record/3.0/compat.rb', line 56 def left children.first end |
#right ⇒ Object
60 61 62 |
# File 'lib/ransack/adapters/active_record/3.0/compat.rb', line 60 def right children[1] end |