class Repeatable::Expression::Base
Public Class Methods
===(other)
click to toggle source
Calls superclass method
# File lib/repeatable/expression/base.rb, line 12 def self.===(other) case other when Class other.ancestors.include?(self) else super end end
Public Instance Methods
deconstruct_keys(_keys)
click to toggle source
# File lib/repeatable/expression/base.rb, line 31 def deconstruct_keys(_keys) to_h end
difference(other)
click to toggle source
# File lib/repeatable/expression/base.rb, line 49 def difference(other) Difference.new(included: self, excluded: other) end
Also aliased as: -
include?(date)
click to toggle source
# File lib/repeatable/expression/base.rb, line 22 def include?(date) end
intersection(other)
click to toggle source
# File lib/repeatable/expression/base.rb, line 43 def intersection(other) Intersection.new(self, other) end
Also aliased as: &
to_h()
click to toggle source
# File lib/repeatable/expression/base.rb, line 26 def to_h {hash_key => hash_value} end
union(other)
click to toggle source
# File lib/repeatable/expression/base.rb, line 36 def union(other) Union.new(self, other) end
Private Instance Methods
hash_key()
click to toggle source
# File lib/repeatable/expression/base.rb, line 57 def hash_key T.must(T.must(self.class.name).split("::").last) .gsub(/(?<!\b)[A-Z]/) { "_#{T.must(Regexp.last_match)[0]}" } .downcase .to_sym end
hash_value()
click to toggle source
# File lib/repeatable/expression/base.rb, line 65 def hash_value end