original_string: public function createController($route, $owner = null)
      {
          if ($owner === null) {
              $owner = $this;
          }
  
          if ($route) {
              list($handler, $vars) = $route;
              if ($handler instanceof Closure) {
                  $handler->__invoke($this->getComponent('request'));
                  $this->end();
              } else {
                  list($className, $actionName) = $handler;
                  $controller = Creator::createObject($className, time(), $owner === $this ? null : $owner, $this->getComponent('request'));
                  return [$controller, $actionName, array_merge($_GET, $vars)];
              }
          }
  
          return null;
      }
code: public function createController($route, $owner = null)
      {
          if ($owner === null) {
              $owner = $this;
          }
  
          if ($route) {
              list($handler, $vars) = $route;
              if ($handler instanceof Closure) {
                  $handler->__invoke($this->getComponent('request'));
                  $this->end();
              } else {
                  list($className, $actionName) = $handler;
                  $controller = Creator::createObject($className, time(), $owner === $this ? null : $owner, $this->getComponent('request'));
                  return [$controller, $actionName, array_merge($_GET, $vars)];
              }
          }
  
          return null;
      }
code_tokens: public function createController ( $ route , $ owner = null ) { if ( $ owner === null ) { $ owner = $ this ; } if ( $ route ) { list ( $ handler , $ vars ) = $ route ; if ( $ handler instanceof Closure ) { $ handler -> __invoke ( $ this -> getComponent ( 'request' ) ) ; $ this -> end ( ) ; } else { list ( $ className , $ actionName ) = $ handler ; $ controller = Creator :: createObject ( $ className , time ( ) , $ owner === $ this ? null : $ owner , $ this -> getComponent ( 'request' ) ) ; return [ $ controller , $ actionName , array_merge ( $ _GET , $ vars ) ] ; } } return null ; }
docstring: Creates a controller instance based on a route.
  The route should contain the controller ID and the action ID.
  It may also contain additional GET variables. All these must be concatenated together with slashes.
  
  This method will attempt to create a controller in the following order:
  <ol>
  <li>If the first segment is found in {@link controllerMap}, the corresponding
  controller configuration will be used to create the controller;</li>
  <li>If the first segment is found to be a module ID, the corresponding module
  will be used to create the controller;</li>
  <li>Otherwise, it will search under the {@link controllerPath} to create
  the corresponding controller. For example, if the route is "admin/user/create",
  then the controller will be created using the class file "protected/controllers/admin/UserController.php".</li>
  </ol>
  @param \Mindy\Router\Route $route the route of the request.
  @param \Mindy\Base\Module $owner the module that the new controller will belong to. Defaults to null, meaning the application
  instance is the owner.
  @return array the controller instance and the action ID. Null if the controller class does not exist or the route is invalid.
docstring_tokens: Creates a controller instance based on a route . The route should contain the controller ID and the action ID . It may also contain additional GET variables . All these must be concatenated together with slashes .