Class: Rosette::Core::PathMatcherFactory::NotNode
- Defined in:
- lib/rosette/core/path_matcher_factory.rb
Overview
A logical “NOT”.
Instance Attribute Summary
Attributes inherited from UnaryNode
Instance Method Summary collapse
-
#matches?(path) ⇒ Boolean
Determines if the given path does NOT match the child’s conditions.
-
#to_s ⇒ String
Generates a string representation of this node.
Methods inherited from UnaryNode
Methods included from NodeOperatorFactory
Methods included from NodeFactory
#match_file_extension, #match_file_extensions, #match_path, #match_paths, #match_regex, #match_regexes
Constructor Details
This class inherits a constructor from Rosette::Core::PathMatcherFactory::UnaryNode
Instance Method Details
#matches?(path) ⇒ Boolean
Determines if the given path does NOT match the child’s conditions.
221 222 223 |
# File 'lib/rosette/core/path_matcher_factory.rb', line 221 def matches?(path) !child.matches?(path) end |
#to_s ⇒ String
Generates a string representation of this node.
228 229 230 |
# File 'lib/rosette/core/path_matcher_factory.rb', line 228 def to_s "(NOT #{child.to_s})" end |