Class: ActiveRecord::Refined::AST::And
- Defined in:
- lib/active_record/refined/ast.rb
Instance Attribute Summary collapse
-
#left ⇒ Object
readonly
Returns the value of attribute left.
-
#right ⇒ Object
readonly
Returns the value of attribute right.
Instance Method Summary collapse
-
#initialize(left, right) ⇒ And
constructor
A new instance of And.
- #to_arel(table, model) ⇒ Object
Methods inherited from Predicate
Methods inherited from Node
Constructor Details
#initialize(left, right) ⇒ And
Returns a new instance of And.
1432 1433 1434 1435 |
# File 'lib/active_record/refined/ast.rb', line 1432 def initialize(left, right) @left = left @right = right end |
Instance Attribute Details
#left ⇒ Object (readonly)
Returns the value of attribute left.
1430 1431 1432 |
# File 'lib/active_record/refined/ast.rb', line 1430 def left @left end |
#right ⇒ Object (readonly)
Returns the value of attribute right.
1430 1431 1432 |
# File 'lib/active_record/refined/ast.rb', line 1430 def right @right end |
Instance Method Details
#to_arel(table, model) ⇒ Object
1437 1438 1439 |
# File 'lib/active_record/refined/ast.rb', line 1437 def to_arel(table, model) left.to_arel(table, model).and(right.to_arel(table, model)) end |