Module: Leftovers::MatcherBuilders::NodePairKey

Defined in:
lib/leftovers/matcher_builders/node_pair_key.rb

Class Method Summary collapse

Class Method Details

.build(key_matcher) ⇒ Object



6
7
8
9
10
11
12
13
# File 'lib/leftovers/matcher_builders/node_pair_key.rb', line 6

def self.build(key_matcher)
  return unless key_matcher

  And.build([
    Matchers::NodeType.new(:pair),
    Matchers::NodePairKey.new(key_matcher)
  ])
end