Class: Flipper::Expressions::Comparable
- Inherits:
-
Object
- Object
- Flipper::Expressions::Comparable
show all
- Defined in:
- lib/flipper/expressions/comparable.rb
Class Method Summary
collapse
Class Method Details
.call(left, right) ⇒ Object
8
9
10
|
# File 'lib/flipper/expressions/comparable.rb', line 8
def self.call(left, right)
left.respond_to?(operator) && right.respond_to?(operator) && left.public_send(operator, right)
end
|
.operator ⇒ Object
4
5
6
|
# File 'lib/flipper/expressions/comparable.rb', line 4
def self.operator
raise NotImplementedError
end
|