Class: Hx::Path::AssumeCircumfix
- Inherits:
-
Object
- Object
- Hx::Path::AssumeCircumfix
- Includes:
- Selector
- Defined in:
- lib/hx/path.rb
Class Method Summary collapse
Instance Method Summary collapse
- #accept_path?(path) ⇒ Boolean
-
#initialize(selector, prefix, suffix) ⇒ AssumeCircumfix
constructor
A new instance of AssumeCircumfix.
Methods included from Selector
#&, #assume_circumfix, #elide_circumfix, #literal?, #|, #~
Constructor Details
#initialize(selector, prefix, suffix) ⇒ AssumeCircumfix
Returns a new instance of AssumeCircumfix.
167 168 169 170 171 |
# File 'lib/hx/path.rb', line 167 def initialize(selector, prefix, suffix) @selector = selector @prefix = prefix @suffix = suffix end |
Class Method Details
Instance Method Details
#accept_path?(path) ⇒ Boolean
173 174 175 |
# File 'lib/hx/path.rb', line 173 def accept_path?(path) @selector.accept_path?("#{@prefix}#{path}#{@suffix}") end |