Class: Waw::StaticController::AndMatcher
- Inherits:
-
AbstractMatcher
- Object
- AbstractMatcher
- Waw::StaticController::AndMatcher
- Defined in:
- lib/waw/controllers/static/matcher.rb
Instance Attribute Summary
Attributes inherited from AbstractMatcher
Instance Method Summary collapse
-
#initialize(wawaccess, left, right) ⇒ AndMatcher
constructor
A new instance of AndMatcher.
-
#matches?(env) ⇒ Boolean
Does the matcher matches a given path?.
Methods inherited from AbstractMatcher
#&, #folder, #negate, #req_path, #|
Methods included from Waw::ScopeUtils
#config, #find_kernel_context, #logger, #params, #rack_env, #real_session, #request, #resources, #response, #root_folder, #session
Constructor Details
#initialize(wawaccess, left, right) ⇒ AndMatcher
Returns a new instance of AndMatcher.
77 78 79 80 |
# File 'lib/waw/controllers/static/matcher.rb', line 77 def initialize(wawaccess, left, right) super(wawaccess) @left, @right = left, right end |
Instance Method Details
#matches?(env) ⇒ Boolean
Does the matcher matches a given path?
83 84 85 |
# File 'lib/waw/controllers/static/matcher.rb', line 83 def matches?(env) @left.matches?(env) && @right.matches?(env) end |