| Apache2::REST::Overview |
The client performs a HTTP method on a resource uri.
the Apache2::REST manpage splits the uri in fragments.
Apache2::REST builds a the Apache2::REST::Handler manpage and let it handle the root fragment
Apache2::REST then writes the response back to the client with the appropriate writer.
If the response is written as a string (which is true for defaults writers), this string is a unicode string encoded in UTF-8 bytes.
If the requested resource is terminal, it performs the requested HTTP method (if allowed).
If the requested resource is not terminal, it solves the next fragment buy building the next handler. By default, the next handler is a class one level down in the package hierachy.
Client request: GET /foo/bar
URI fragments are (foo bar)
A root handler is built according to Apache2RESTHandlerRootClass - See the Apache2::REST manpage. Let's assume this root handler is MyApp::REST::API. See the Apache2::REST::Handler manpage.
This root handle is not terminal for this request, so it builds the next handler.
The next handler will be a MyApp::REST::API::foo
One more step and the terminal handler is a MyApp::REST::API::foo::bar
The method GET is called on the MyApp::REST::API::foo::bar instance.
The the Apache2::REST::Response manpage is written back to the client by the Apache2::REST::Handler manpage
| Apache2::REST::Overview |