src/Dispatch/Dispatcher.php
public function resolveApp()
    {
        // Determine the correct vhost first
        $this->determineVirtualHost();

        // Resolve the application to start
        $path = $this->vhost->getPath($this->request->url);

        $resolved = $this->resolver->resolve("app", $path);

        if ($resolved !== null)
        {
            if ($resolved['ext'])
            {
                $mime = new FileType($resolved['ext'], "");
                if (!empty($mime))
                {
                    $str = $mime->getMimeType() . ";q=1.5," . (string)$this->request->accept;
                    $this->request->setAccept(new Accept($str));
                }
                $this->suffix = $resolved['ext'];
            }
            $this->route = $resolved['route'];
            $this->app = $resolved['path'];
            $this->arguments = new Dictionary($resolved['remainder']);
        }
        else
        {
            $this->route = null;
            $this->app = null;
            $this->arguments = new Dictionary();
        }
    }
public function resolveApp()
    {
        // Determine the correct vhost first
        $this->determineVirtualHost();

        // Resolve the application to start
        $path = $this->vhost->getPath($this->request->url);

        $resolved = $this->resolver->resolve("app", $path);

        if ($resolved !== null)
        {
            if ($resolved['ext'])
            {
                $mime = new FileType($resolved['ext'], "");
                if (!empty($mime))
                {
                    $str = $mime->getMimeType() . ";q=1.5," . (string)$this->request->accept;
                    $this->request->setAccept(new Accept($str));
                }
                $this->suffix = $resolved['ext'];
            }
            $this->route = $resolved['route'];
            $this->app = $resolved['path'];
            $this->arguments = new Dictionary($resolved['remainder']);
        }
        else
        {
            $this->route = null;
            $this->app = null;
            $this->arguments = new Dictionary();
        }
    }
Resolve the app to run based on the incoming URL