Module: ArelExtensions::BooleanFunctions
- Included in:
- Arel::Nodes::And, Arel::Nodes::Binary, Arel::Nodes::Function, Arel::Nodes::Or, Nodes::Blank, Nodes::IsNotNull, Nodes::IsNull, Nodes::NotBlank
- Defined in:
- lib/arel_extensions/boolean_functions.rb
Instance Method Summary collapse
- #and(*others) ⇒ Object
- #or(*others) ⇒ Object
- #then(t, f = nil) ⇒ Object
- #⋀(other) ⇒ Object
- #⋁(other) ⇒ Object
Instance Method Details
#and(*others) ⇒ Object
9 10 11 |
# File 'lib/arel_extensions/boolean_functions.rb', line 9 def and *others Arel::Nodes::And.new self, others end |
#or(*others) ⇒ Object
17 18 19 |
# File 'lib/arel_extensions/boolean_functions.rb', line 17 def or *others Arel::Nodes::Or.new self, others end |
#then(t, f = nil) ⇒ Object
21 22 23 |
# File 'lib/arel_extensions/boolean_functions.rb', line 21 def then(t, f = nil) ArelExtensions::Nodes::Then.new [self, t, f] end |
#⋀(other) ⇒ Object
5 6 7 |
# File 'lib/arel_extensions/boolean_functions.rb', line 5 def ⋀(other) self.and(other) end |
#⋁(other) ⇒ Object
13 14 15 |
# File 'lib/arel_extensions/boolean_functions.rb', line 13 def ⋁(other) self.or(other) end |