Object
# File lib/http_router/node.rb, line 39 def add_arbitrary(blk, allow_partial, param_names) add(Arbitrary.new(@router, self, allow_partial, blk, param_names)) end
# File lib/http_router/node.rb, line 55 def add_destination(route, path, param_names = []) add(Path.new(@router, self, route, path, param_names)) end
# File lib/http_router/node.rb, line 51 def add_free_match(regexp) add(FreeRegex.new(@router, self, regexp)) end
# File lib/http_router/node.rb, line 26 def add_glob add(Glob.new(@router, self)) end
# File lib/http_router/node.rb, line 30 def add_glob_regexp(matcher) add(GlobRegex.new(@router, self, matcher)) end
# File lib/http_router/node.rb, line 59 def add_lookup(part) add(Lookup.new(@router, self)).add(part) end
# File lib/http_router/node.rb, line 43 def add_match(regexp, matching_indicies = [0], splitting_indicies = nil) add(Regex.new(@router, self, regexp, matching_indicies, splitting_indicies)) end
# File lib/http_router/node.rb, line 34 def add_request(opts) raise unless opts add(Request.new(@router, self, opts)) end
# File lib/http_router/node.rb, line 47 def add_spanning_match(regexp, matching_indicies = [0], splitting_indicies = nil) add(SpanningRegex.new(@router, self, regexp, matching_indicies, splitting_indicies)) end
# File lib/http_router/node.rb, line 22 def add_variable add(Variable.new(@router, self)) end
# File lib/http_router/node.rb, line 84 def depth @parent.send(:depth) + 1 end
# File lib/http_router/node.rb, line 67 def inspect ins = "#{' ' * depth}#{inspect_label}" body = inspect_matchers_body unless body =~ /^\s*$/ ins << "\n" << body end ins end
# File lib/http_router/node.rb, line 76 def inspect_label "#{self.class.name.split("::").last} (#{@matchers.size} matchers)" end
Generated with the Darkfish Rdoc Generator 2.