class Fear::PartialFunction::Guard::Or
@api private
Attributes
c1[R]
c2[R]
Public Class Methods
new(c1, c2)
click to toggle source
@param c1 [Fear::PartialFunction::Guard] @param c2 [Fear::PartialFunction::Guard]
# File lib/fear/partial_function/guard/or.rb, line 10 def initialize(c1, c2) @c1 = c1 @c2 = c2 end
Public Instance Methods
===(arg)
click to toggle source
@param arg [any] @return [Boolean]
# File lib/fear/partial_function/guard/or.rb, line 32 def ===(arg) (c1 === arg) || (c2 === arg) end
and(other)
click to toggle source
@param other [Fear::PartialFunction::Guard] @return [Fear::PartialFunction::Guard]
# File lib/fear/partial_function/guard/or.rb, line 20 def and(other) Guard::And.new(self, other) end
or(other)
click to toggle source
@param other [Fear::PartialFunction::Guard] @return [Fear::PartialFunction::Guard]
# File lib/fear/partial_function/guard/or.rb, line 26 def or(other) Guard::Or.new(self, other) end