Fetch the scope required for the action id.

@param string $actionId
@return ?string the required scope or `null` if no scope is required.
321026
protected function fetchActionScope($actionId)
    {
        if (empty($this->actionScopes)) {
            return null;
        }

        $ownerId = $this->owner->getUniqueId();
        foreach ($this->actionScopes as $actionPattern => $scope) {

            if (StringHelper::matchWildcard(
                "$ownerId/$actionPattern",
                $actionId
            )) {
                return $scope;
            }
        }

        return null;
    }
120914
public function displayNiceView($controller = null, $url = '', $action = '')
    {
        if (!$controller) {
            $controller = $this->owner;
        }

        return singleton('director')->create_view($controller, $url, $action);
    }
1323485
public function redirectTo($defaultActionId = 'index')
    {
        if ($this->returnUrl !== null) {
            return $this->controller->redirect($this->returnUrl);
        }

        return $this->controller->redirect($defaultActionId);
    }
283645
public function getAction($id)
    {
        $manager = $this->getTaskManager();

        return $this->handleView($this->view($manager->findById($id)));
    }
1125097
public function moduleForAction($action)
    {
        if (!isset($this->actions[$action])) {
            return null;
        }

        return $this->modules[$this->actions[$action]];
    }
416390
private function getControllerActionAnnotations($controller, $action)
    {
        if ($controller instanceof \Closure) {
            return $this->annotation->readFunction($controller);
        }

        return $this->annotation->readMethod($controller, $action . 'Action');
    }
638728
public function getAction($id)
    {
        return $this->handleView(
            $this->view(
                $this->get('sulu_contact.country_repository')->find($id)
            )
        );
    }
1063438
public function getPrefetchAddressFields($storeId = null)
    {
        return $this->getScopeConfig()->getValue(
            self::XML_PATH_PREFETCH_ADDRESS_FIELDS,
            ScopeInterface::SCOPE_STORE,
            $storeId
        );
    }
582318
public ActionResult getActionResult(String actionId) {
        if (actionId == null) {
            return null;
        }
        for (ListIterator<ContentResult> iterator = listIterator(size()); iterator.hasPrevious();) {
            ContentResult contentResult = iterator.previous();
            ActionResult actionResult = contentResult.getActionResult(actionId);
            if (actionResult != null) {
                return actionResult;
            }
        }
        return null;
    }
182503
public function getAction($id)
    {
        $findCallback = function($id) {
            $targetGroup = $this->getTargetGroupRepository()->find($id);

            return $targetGroup;
        };

        $view = $this->responseGetById($id, $findCallback);

        return $this->handleView($view);
    }
958608
public function load($objectId)
    {
        $success = null;
        $value   = $this->adapter->getItem($objectId, $success);

        if ($success) {
            return $value;
        }

        return null;
    }
559475
public function get($uri, $action)
    {
        $uri = $this->buildUri($uri);

        return $this->addResponseType(Route::get($uri, $action));
    }
93218
public function getByAction($action)
	{
		return isset($this->actionList[$action]) ? $this->actionList[$action] : null;
	}
328696
public function getPositionByName($controller, $action = null)
    {
        if ($action === null) {
            list($controller, $action) = explode('.', $controller);
        }
        return array_search("{$controller}.{$action}", $this->action_names);
    }
947011
protected function getTemplateIdentifier($actionName = null)
    {
        if ($actionName === null) {
            /** @var $actionRequest \TYPO3\Flow\Mvc\ActionRequest */
            $actionRequest = $this->controllerContext->getRequest();
            $actionName = $actionRequest->getControllerActionName();
        }
        $templatePathAndFilename = $this->getTemplatePathAndFilename($actionName);
        $controllerName = $this->controllerContext->getRequest()->getControllerName();
        $prefix = $controllerName . '_action_' . $actionName;
        return $this->createIdentifierForFile($templatePathAndFilename, $prefix);
    }
473812
public function getRequiredRights(MenuAction $action)
    {
        $rights = [];
        $resolvedAction = $this->getResolvedAction($action);
        if(!is_null($resolvedAction)){
            try {
                $rights  = ControllerHelper::getRequiredRights(
                    $resolvedAction['controller'],
                    $resolvedAction['action']
                );
            } catch(\Exception $e){
                \common_Logger::d('do not handle permissions for action : ' . $action->getName() . ' ' . $action->getUrl());
            }
        }

        return $rights;
    }
822935
protected function createActionFromMap($actionMap, $actionId)
    {
        if (!isset($actionMap[$actionId])) {
            return null;
        }
        $config = $actionMap[$actionId];
        if (!is_array($config)) {
            $config = ['class' => $config];
        }

        if (!isset($config['class'])) {
            throw new Exception('对象配置必须执行"class"元素', 100500304);
        }
        if (isset($config['enable']) && !$config['enable']) {
            return null;
        }
        unset($config['enable']);
        return Unit::createObject($config, $this, $actionId);
    }