module Roda::RodaPlugins::ClassMatchers::RequestMethods
Public Instance Methods
Source
# File lib/roda/plugins/class_matchers.rb, line 116 def _consume_segment(convert_meth) rp = @remaining_path if _match_class_String if convert_meth if captures = scope.send(convert_meth, @captures.pop) if captures.is_a?(Array) @captures.concat(captures) else @captures << captures end else @remaining_path = rp nil end else true end end end
Use faster approach for segment matching. This is used for matchers based on the String class matcher, and avoids the use of regular expressions for scanning.