(self, controller, environ, start_response)
return controller(environ, start_response)
Dispatches to a controller, will instantiate the controller
        if necessary.

        Override this to change how the controller dispatch is handled.
Dispatches to a controller, will instantiate the controller
        if necessary.
Dispatches to a controller will instantiate the controller if necessary .
def dispatch(self, controller, environ, start_response):
        """Dispatches to a controller, will instantiate the controller
        if necessary.

        Override this to change how the controller dispatch is handled.

        """
        log_debug = self.log_debug
        if not controller:
            if log_debug:
                log.debug("No controller found, returning 404 HTTP Not Found")
            return HTTPNotFound()(environ, start_response)

        # Is it a responder?
        if 'responder' in environ['pylons.routes_dict']:
            return controller(environ['pylons.pylons'].request)

        # Is it a class? Then its a WSGIController
        if hasattr(controller, '__bases__'):
            if log_debug:
                log.debug("Controller appears to be a class, instantiating")
            controller = controller()
            controller._pylons_log_debug = log_debug

        # Add a reference to the controller app located
        environ['pylons.controller'] = controller

        # Controller is assumed to handle a WSGI call
        if log_debug:
            log.debug("Calling controller class with WSGI interface")
        return controller(environ, start_response)
def dispatch ( self , controller , environ , start_response ) : log_debug = self . log_debug if not controller : if log_debug : log . debug ( "No controller found, returning 404 HTTP Not Found" ) return HTTPNotFound ( ) ( environ , start_response ) # Is it a responder? if 'responder' in environ [ 'pylons.routes_dict' ] : return controller ( environ [ 'pylons.pylons' ] . request ) # Is it a class? Then its a WSGIController if hasattr ( controller , '__bases__' ) : if log_debug : log . debug ( "Controller appears to be a class, instantiating" ) controller = controller ( ) controller . _pylons_log_debug = log_debug # Add a reference to the controller app located environ [ 'pylons.controller' ] = controller # Controller is assumed to handle a WSGI call if log_debug : log . debug ( "Calling controller class with WSGI interface" ) return controller ( environ , start_response )