Class: SplitIoClient::ContainsAnyMatcher
- Inherits:
-
SetMatcher
- Object
- SetMatcher
- SplitIoClient::ContainsAnyMatcher
- Defined in:
- lib/splitclient-rb/engine/matchers/contains_any_matcher.rb
Constant Summary collapse
- MATCHER_TYPE =
'CONTAINS_ANY'
Instance Attribute Summary collapse
-
#attribute ⇒ Object
readonly
Returns the value of attribute attribute.
Instance Method Summary collapse
Methods inherited from SetMatcher
Instance Attribute Details
#attribute ⇒ Object (readonly)
Returns the value of attribute attribute.
7 8 9 |
# File 'lib/splitclient-rb/engine/matchers/contains_any_matcher.rb', line 7 def attribute @attribute end |
Instance Method Details
#match?(args) ⇒ Boolean
9 10 11 12 13 14 |
# File 'lib/splitclient-rb/engine/matchers/contains_any_matcher.rb', line 9 def match?(args) matches = local_set(args[:attributes], @attribute).intersect? @remote_set @logger.log_if_debug("[ContainsAnyMatcher] Remote Set #{@remote_set} contains any \ #{@attribute} or #{args[:attributes]}-> #{matches}") matches end |