Neos\Fusion\View\FusionView::getTypoScriptPathForCurrentRequest PHP Method

getTypoScriptPathForCurrentRequest() protected method

Determines the TypoScript path depending on the current controller and action
    protected function getTypoScriptPathForCurrentRequest()
    {
        if ($this->typoScriptPath === null) {
            $typoScriptPath = $this->getOption('typoScriptPath');
            if ($typoScriptPath !== null) {
                $this->typoScriptPath = $typoScriptPath;
            } else {
                /** @var $request ActionRequest */
                $request = $this->controllerContext->getRequest();
                $typoScriptPathForCurrentRequest = $request->getControllerObjectName();
                $typoScriptPathForCurrentRequest = str_replace('\\Controller\\', '\\', $typoScriptPathForCurrentRequest);
                $typoScriptPathForCurrentRequest = str_replace('\\', '/', $typoScriptPathForCurrentRequest);
                $typoScriptPathForCurrentRequest = trim($typoScriptPathForCurrentRequest, '/');
                $typoScriptPathForCurrentRequest .= '/' . $request->getControllerActionName();
                $this->typoScriptPath = $typoScriptPathForCurrentRequest;
            }
        }
        return $this->typoScriptPath;
    }