Now the 'router' library is part of 'wsf'
Move hello_routed_world under tests/dev since it was not really an example, but more a dev workspace/test
This commit is contained in:
14
library/server/wsf/doc/router.txt
Normal file
14
library/server/wsf/doc/router.txt
Normal file
@@ -0,0 +1,14 @@
|
||||
This library introduce the notion of router and handler in the folder "router"
|
||||
The Router manages the association between URI,URI template and Handler
|
||||
The Router is in charge to route/dispatch a request to one of the Handler according to the URI and how the Handler is mapped in the Router.
|
||||
|
||||
Common usage
|
||||
|
||||
router: REQUEST_ROUTER
|
||||
hello_handler: REQUEST_HANDLER
|
||||
|
||||
create {REQUEST_URI_TEMPLATE_ROUTER} router.make
|
||||
create {REQUEST_AGENT_HANDLER} hello_handler.make (agent handle_hello)
|
||||
|
||||
router.map ("/hello/{name}", hello_handler)
|
||||
router.map_agent ("/hello/{name}", agent handle_hello)
|
||||
Reference in New Issue
Block a user