Package turbogears :: Module dispatchers :: Class VirtualPathDispatcher

Class VirtualPathDispatcher

source code

object --+
         |
        VirtualPathDispatcher

Dispatcher that makes CherryPy ignorant of a URL root path.

That is, you can mount your app so the URI "/users/~rdel/myapp/" maps to the root object "/".

Note that this can not be done by a hook since they are run too late.

Instance Methods
 
__init__(self, next_dispatcher=None, webpath='')
x.__init__(...) initializes x; see help(type(x)) for signature
source code
 
__call__(self, path_info)
Determine the relevant path info by stripping off prefixes.
source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties

Inherited from object: __class__

Method Details

__init__(self, next_dispatcher=None, webpath='')
(Constructor)

source code 

x.__init__(...) initializes x; see help(type(x)) for signature

Overrides: object.__init__
(inherited documentation)

__call__(self, path_info)
(Call operator)

source code 

Determine the relevant path info by stripping off prefixes.

Strips webpath and request.script_name from request.path_info.