Class: DataMapper::Query::Conditions::NotOperation
- Inherits:
-
AbstractOperation
- Object
- AbstractOperation
- DataMapper::Query::Conditions::NotOperation
- Defined in:
- lib/dm-core/query/conditions/operation.rb
Overview
class OrOperation
Instance Attribute Summary
Attributes inherited from AbstractOperation
Instance Method Summary collapse
-
#<<(operand) ⇒ Object
TODO: document.
-
#matches?(record) ⇒ Boolean
TODO: document.
Methods inherited from AbstractOperation
descendants, #each, inherited, #inspect, #slug, slug, #sorted_operands, #valid?
Methods included from Equalizer
Instance Method Details
#<<(operand) ⇒ Object
TODO: document
182 183 184 185 |
# File 'lib/dm-core/query/conditions/operation.rb', line 182 def <<(operand) raise ArgumentError, "#{self.class} cannot have more than one operand" if @operands.size > 0 super end |
#matches?(record) ⇒ Boolean
TODO: document
176 177 178 |
# File 'lib/dm-core/query/conditions/operation.rb', line 176 def matches?(record) not @operands.first.matches?(record) end |