Falcon v1.0.0 Documentation
to an instance of falcon.HTTPError raise falcon.HTTPError(falcon.HTTP_792) add_route(uri_template, resource, *args, **kwargs)[source] Associates a templatized URI path with a resource. Note field expressions: /repos/{org}/{repo}/compare/{usr0}:{branch0}...{usr1}:{branch1} Parameters: uri_template (str) – A templatized URI. Care must be taken to ensure the template does not mask any sink patterns query_string str – Query string portion of the request URL, without the preceding ‘?’ character. uri_template str – The template for the route that was matched for this request. May be None if the request0 码力 | 312 页 | 368.58 KB | 1 年前3Falcon v1.0.0 Documentation
modify resp manually in order to communicate information about the issue to the client. add_route(uri_template, resource, *args, **kwargs)[source] Associates a templatized URI path with a resource. A resource expressions. For example: /repos/{org}/{repo}/compare/{usr0}:{branch0}...{usr1}:{branch1} Parameters: uri_template (str) – A templatized URI. Care must be taken to ensure the template does not mask any sink patterns FancyRouter(object): def add_route(self, uri_template, method_map, resource): """Adds a route between URI path template and resource. Args: uri_template (str): The URI template to add.0 码力 | 249 页 | 406.22 KB | 1 年前3Falcon v3.0.0-b1 Documentation
had been appended to the original middleware list passed to the class initializer. add_route(uri_template, resource, **kwargs)[source] Associate a templatized URI path with a resource. Falcon routes custom router object to the App initializer. (See also: Routing) Parameters: Keyword Arguments: uri_template (str [https://docs.python.org/3/library/stdtypes.html#str]) – A templatized URI. Care must be any are registered. (See also: add_sink()) Warning If strip_url_path_trailing_slash is enabled, uri_template should be provided without a trailing slash. (See also: How does Falcon handle a trailing slash0 码力 | 1028 页 | 725.86 KB | 1 年前3Falcon v3.0.0 Documentation
had been appended to the original middleware list passed to the class initializer. add_route(uri_template, resource, **kwargs)[source] Associate a templatized URI path with a resource. Falcon routes custom router object to the App initializer. (See also: Routing) Parameters: Keyword Arguments: uri_template (str [https://docs.python.org/3/library/stdtypes.html#str]) – A templatized URI. Care must be any are registered. (See also: add_sink()) Warning If strip_url_path_trailing_slash is enabled, uri_template should be provided without a trailing slash. (See also: How does Falcon handle a trailing slash0 码力 | 1055 页 | 739.30 KB | 1 年前3Falcon v3.0.1 Documentation
had been appended to the original middleware list passed to the class initializer. add_route(uri_template, resource, **kwargs)[source] Associate a templatized URI path with a resource. Falcon routes custom router object to the App initializer. (See also: Routing) Parameters: Keyword Arguments: uri_template (str [https://docs.python.org/3/library/stdtypes.html#str]) – A templatized URI. Care must be any are registered. (See also: add_sink()) Warning If strip_url_path_trailing_slash is enabled, uri_template should be provided without a trailing slash. (See also: How does Falcon handle a trailing slash0 码力 | 1058 页 | 741.59 KB | 1 年前3Falcon v3.0.0-b2 Documentation
had been appended to the original middleware list passed to the class initializer. add_route(uri_template, resource, **kwargs)[source] Associate a templatized URI path with a resource. Falcon routes custom router object to the App initializer. (See also: Routing) Parameters: Keyword Arguments: uri_template (str [https://docs.python.org/3/library/stdtypes.html#str]) – A templatized URI. Care must be any are registered. (See also: add_sink()) Warning If strip_url_path_trailing_slash is enabled, uri_template should be provided without a trailing slash. (See also: How does Falcon handle a trailing slash0 码力 | 1041 页 | 730.21 KB | 1 年前3Falcon v1.2.0 Documentation
to an instance of falcon.HTTPError raise falcon.HTTPError(falcon.HTTP_792) add_route(uri_template, resource, *args, **kwargs) Associates a templatized URI path with a resource. Note The following correspond to argument names in responder methods, they must be valid Python identifiers. Parameters: uri_template (str) – A templatized URI. Care must be taken to ensure the template does not mask any sink patterns query_string str – Query string portion of the request URL, without the preceding ‘?’ character. uri_template str – The template for the route that was matched for this request. May be None if the request0 码力 | 177 页 | 252.56 KB | 1 年前3Falcon v0.2.0 Documentation
modify resp manually in order to communicate information about the issue to the client. add_route(uri_template, resource)[source] Associates a templatized URI path with a resource. A resource is an instance “/user/kgriffs” would be routed to: def on_put(self, req, resp, name): pass Parameters: uri_template (str) – A templatized URI. Care must be taken to ensure the template does not mask any sink patterns start_response(resp.status, headers) return body [docs] def add_route(self, uri_template, resource): """Associates a templatized URI path with a resource. A resource is0 码力 | 188 页 | 358.44 KB | 1 年前3Falcon v3.1.1 Documentation
had been appended to the original middleware list passed to the class initializer. add_route(uri_template, resource, **kwargs) Associate a templatized URI path with a resource. Falcon routes incoming custom router object to the App initializer. (See also: Routing) Parameters: Keyword Arguments: uri_template (str [https://docs.python.org/3/library/stdtypes.html#str]) – A templatized URI. Care must be any are registered. (See also: add_sink()) Warning If strip_url_path_trailing_slash is enabled, uri_template should be provided without a trailing slash. (See also: How does Falcon handle a trailing slash0 码力 | 540 页 | 476.60 KB | 1 年前3Falcon v3.1.1-rc1 Documentation
had been appended to the original middleware list passed to the class initializer. add_route(uri_template, resource, **kwargs) Associate a templatized URI path with a resource. Falcon routes incoming custom router object to the App initializer. (See also: Routing) Parameters: Keyword Arguments: uri_template (str [https://docs.python.org/3/library/stdtypes.html#str]) – A templatized URI. Care must be any are registered. (See also: add_sink()) Warning If strip_url_path_trailing_slash is enabled, uri_template should be provided without a trailing slash. (See also: How does Falcon handle a trailing slash0 码力 | 540 页 | 476.61 KB | 1 年前3
共 20 条
- 1
- 2