milla.dispatch.traversal¶
URL Dispatching
Created: | Mar 26, 2011 |
---|---|
Author: | dustin |
Updated: | $Date$ |
Updater: | $Author$ |
-
class
milla.dispatch.traversal.
Traverser
(root)[source]¶ Default URL dispatcher
Parameters: root – The root object at which lookup will begin The default URL dispatcher uses object attribute traversal to locate a handler for a given path. For example, consider the following class:
class Root(object): def foo(self): return 'Hello, world!'
The path
/foo
would resolve to thefoo
method of theRoot
class.If a path cannot be resolved,
UnresolvedPath
will be raised.