updated config file and examples

This commit is contained in:
Jocelyn Fiat
2011-09-13 17:07:17 +02:00
parent f0c6eec23d
commit 92105ca7b3
3 changed files with 16 additions and 10 deletions

View File

@@ -35,17 +35,27 @@ feature {NONE} -- Initialization
setup_router
local
ra: REQUEST_AGENT_HANDLER [REQUEST_URI_TEMPLATE_HANDLER_CONTEXT]
rag: DEFAULT_REQUEST_URI_TEMPLATE_ROUTING_HANDLER
do
router.map_agent ("/home", agent execute_home)
create rag.make (3)
create ra.make (agent handle_hello)
router.map ("/hello/{name}.{format}", ra)
router.map ("/hello.{format}/{name}", ra)
router.map ("/hello/{name}", ra)
rag.map ("/hello/{name}.{format}", ra)
rag.map ("/hello.{format}/{name}", ra)
rag.map ("/hello/{name}", ra)
-- router.map ("/hello/{name}.{format}", ra)
-- router.map ("/hello.{format}/{name}", ra)
-- router.map ("/hello/{name}", ra)
create ra.make (agent handle_anonymous_hello)
router.map ("/hello", ra)
router.map ("/hello.{format}", ra)
rag.map ("/hello", ra)
rag.map ("/hello.{format}", ra)
-- router.map ("/hello", ra)
-- router.map ("/hello.{format}", ra)
router.map ("/hello", rag)
router.map_agent_with_request_methods ("/method/any", agent handle_method_any, Void)
router.map_agent_with_request_methods ("/method/guess", agent handle_method_get_or_post, <<"GET", "POST">>)