Class: Mutant::Expression::Namespace::Exact Private

Inherits:
Mutant::Expression::Namespace show all
Defined in:
lib/mutant/expression/namespace.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Exact namespace expression

Constant Summary collapse

MATCHER =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Matcher::Scope
REGEXP =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

/\A#{SCOPE_NAME_PATTERN}\z/

Constants inherited from Mutant::Expression

SCOPE_NAME_PATTERN, SCOPE_SYMBOL_PATTERN

Instance Method Summary collapse

Methods inherited from Mutant::Expression

#match_length, new, #prefix?, try_parse

Instance Method Details

#matcher(env:) ⇒ Matcher

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Matcher matcher on expression

Returns:



70
71
72
73
74
75
76
77
78
# File 'lib/mutant/expression/namespace.rb', line 70

def matcher(env:)
  raw_scope = find_raw_scope

  if raw_scope
    Matcher::Scope.new(scope: Scope.new(expression: self, raw: raw_scope))
  else
    Matcher::Null.new
  end
end