Sha256: 5c86e4818e0919f072a7ac4864ab9c15fad880eded611b53bfa43973a404792b

Contents?: true

Size: 246 Bytes

Versions: 4

Compression:

Stored size: 246 Bytes

Contents

module Casino
  class Intersection
    module Match
      class Expression < Equivalence
        def eligible?
          field.is_a? Regexp
        end

        def evaluate
          !(value =~ field).nil?
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
mongoid-casino-0.0.4 lib/casino/intersection/match/expression.rb
mongoid-casino-0.0.3 lib/casino/intersection/match/expression.rb
mongoid-casino-0.0.2 lib/casino/intersection/match/expression.rb
mongoid-casino-0.0.1 lib/casino/intersection/match/expression.rb