‪TYPO3CMS  ‪main
ActionController.php
Go to the documentation of this file.
1 <?php
2 
3 /*
4  * This file is part of the TYPO3 CMS project.
5  *
6  * It is free software; you can redistribute it and/or modify it under
7  * the terms of the GNU General Public License, either version 2
8  * of the License, or any later version.
9  *
10  * For the full copyright and license information, please read the
11  * LICENSE.txt file that was distributed with this source code.
12  *
13  * The TYPO3 project - inspiring people to share!
14  */
15 
17 
18 use Psr\EventDispatcher\EventDispatcherInterface;
19 use Psr\Http\Message\ResponseFactoryInterface;
20 use Psr\Http\Message\ResponseInterface;
21 use Psr\Http\Message\StreamFactoryInterface;
22 use Psr\Http\Message\UriInterface;
56 use TYPO3Fluid\Fluid\View\AbstractTemplateView;
57 use TYPO3Fluid\Fluid\View\ViewInterface;
58 
63 {
64  protected ResponseFactoryInterface ‪$responseFactory;
65  protected StreamFactoryInterface ‪$streamFactory;
67 
72 
77 
83  protected ‪$view;
84 
91  protected string ‪$defaultViewObjectName = TemplateView::class;
92 
98  protected string ‪$actionMethodName = 'indexAction';
99 
103  protected string ‪$errorMethodName = 'errorAction';
104 
106  protected EventDispatcherInterface ‪$eventDispatcher;
108  protected ‪UriBuilder ‪$uriBuilder;
109 
113  protected array ‪$settings;
114 
119 
120  protected ‪Arguments ‪$arguments;
121 
126 
131 
136 
141 
142  final public function ‪injectResponseFactory(ResponseFactoryInterface ‪$responseFactory): void
143  {
144  $this->responseFactory = ‪$responseFactory;
145  }
146 
147  final public function ‪injectStreamFactory(StreamFactoryInterface ‪$streamFactory): void
148  {
149  $this->streamFactory = ‪$streamFactory;
150  }
151 
156  {
157  $this->configurationManager = ‪$configurationManager;
158  $this->settings = $this->configurationManager->‪getConfiguration(‪ConfigurationManagerInterface::CONFIGURATION_TYPE_SETTINGS);
159  $this->arguments = GeneralUtility::makeInstance(Arguments::class);
160  }
161 
165  public function ‪injectValidatorResolver(ValidatorResolver ‪$validatorResolver): void
166  {
167  $this->validatorResolver = ‪$validatorResolver;
168  }
169 
173  public function ‪injectViewResolver(ViewResolverInterface ‪$viewResolver): void
174  {
175  $this->viewResolver = ‪$viewResolver;
176  }
177 
181  public function ‪injectReflectionService(ReflectionService ‪$reflectionService): void
182  {
183  $this->reflectionService = ‪$reflectionService;
184  }
185 
189  public function ‪injectHashService(HashService ‪$hashService): void
190  {
191  $this->hashService = ‪$hashService;
192  }
193 
195  {
196  $this->mvcPropertyMappingConfigurationService = ‪$mvcPropertyMappingConfigurationService;
197  }
198 
199  public function ‪injectEventDispatcher(EventDispatcherInterface ‪$eventDispatcher): void
200  {
201  $this->eventDispatcher = ‪$eventDispatcher;
202  }
203 
208  {
209  $this->propertyMapper = ‪$propertyMapper;
210  }
211 
215  final public function ‪injectInternalFlashMessageService(FlashMessageService $flashMessageService): void
216  {
217  $this->internalFlashMessageService = $flashMessageService;
218  }
219 
223  final public function ‪injectInternalExtensionService(ExtensionService $extensionService): void
224  {
225  $this->internalExtensionService = $extensionService;
226  }
227 
234  protected function ‪initializeAction(): void {}
235 
247  protected function ‪initializeActionMethodArguments(): void
248  {
249  $methodParameters = $this->reflectionService
250  ->getClassSchema(static::class)
251  ->getMethod($this->actionMethodName)->getParameters();
252 
253  foreach ($methodParameters as $parameterName => $parameter) {
254  $dataType = null;
255  if ($parameter->getType() !== null) {
256  $dataType = $parameter->getType();
257  } elseif ($parameter->isArray()) {
258  $dataType = 'array';
259  }
260  if ($dataType === null) {
261  throw new InvalidArgumentTypeException('The argument type for parameter $' . $parameterName . ' of method ' . static::class . '->' . $this->actionMethodName . '() could not be detected.', 1253175643);
262  }
263  $defaultValue = $parameter->hasDefaultValue() ? $parameter->getDefaultValue() : null;
264  $this->arguments->addNewArgument($parameterName, $dataType, !$parameter->isOptional(), $defaultValue);
265  }
266  }
267 
278  protected function ‪initializeActionMethodValidators(): void
279  {
280  if ($this->arguments->count() === 0) {
281  return;
282  }
283 
284  $classSchemaMethod = $this->reflectionService->getClassSchema(static::class)->getMethod($this->actionMethodName);
285 
287  foreach ($this->arguments as $argument) {
288  $classSchemaMethodParameter = $classSchemaMethod->getParameter($argument->getName());
289  // At this point validation is skipped if there is an IgnoreValidation annotation.
290  // @todo: IgnoreValidation annotations could be evaluated in the ClassSchema and result in
291  // no validators being applied to the method parameter.
292  if ($classSchemaMethodParameter->ignoreValidation()) {
293  continue;
294  }
296  ‪$validator = $this->validatorResolver->createValidator(ConjunctionValidator::class, []);
297  foreach ($classSchemaMethodParameter->getValidators() as $validatorDefinition) {
299  $validatorInstance = $this->validatorResolver->createValidator($validatorDefinition['className'], $validatorDefinition['options']);
300  ‪$validator->addValidator(
301  $validatorInstance
302  );
303  }
304  $baseValidatorConjunction = $this->validatorResolver->getBaseValidatorConjunction($argument->getDataType());
305  if ($baseValidatorConjunction->count() > 0) {
306  ‪$validator->addValidator($baseValidatorConjunction);
307  }
308  $argument->setValidator(‪$validator);
309  }
310  }
311 
318  public function ‪initializeControllerArgumentsBaseValidators(): void
319  {
321  foreach ($this->arguments as $argument) {
322  ‪$validator = $this->validatorResolver->getBaseValidatorConjunction($argument->getDataType());
323  if (‪$validator !== null) {
324  $argument->setValidator(‪$validator);
325  }
326  }
327  }
328 
334  public function ‪processRequest(RequestInterface ‪$request): ResponseInterface
335  {
337  $this->request = ‪$request;
338  $this->uriBuilder = GeneralUtility::makeInstance(UriBuilder::class);
339  $this->uriBuilder->setRequest(‪$request);
340  $this->actionMethodName = $this->‪resolveActionMethodName();
343  $this->mvcPropertyMappingConfigurationService->initializePropertyMappingConfigurationFromRequest(‪$request, $this->arguments);
344  $this->‪initializeAction();
345  $actionInitializationMethodName = 'initialize' . ucfirst($this->actionMethodName);
347  $callable = [$this, $actionInitializationMethodName];
348  if (is_callable($callable)) {
349  $callable();
350  }
352  $this->view = $this->‪resolveView();
353  if ($this->view !== null && method_exists($this, 'initializeView')) {
354  $this->initializeView($this->view);
355  }
356  $response = $this->‪callActionMethod($request);
357  $this->‪renderAssetsForRequest($request);
358 
359  return $response;
360  }
361 
377  protected function ‪renderAssetsForRequest(RequestInterface ‪$request): void
378  {
379  if (!$this->view instanceof AbstractTemplateView) {
380  // Only AbstractTemplateView (from Fluid engine, so this includes all TYPO3 Views based
381  // on TYPO3's AbstractTemplateView) supports renderSection(). The method is not
382  // declared on ViewInterface - so we must assert a specific class. We silently skip
383  // asset processing if the View doesn't match, so we don't risk breaking custom Views.
384  return;
385  }
386  $pageRenderer = GeneralUtility::makeInstance(PageRenderer::class);
387  $variables = ['request' => ‪$request, 'arguments' => ‪$this->arguments];
388  $headerAssets = $this->view->renderSection('HeaderAssets', $variables, true);
389  $footerAssets = $this->view->renderSection('FooterAssets', $variables, true);
390  if (!empty(trim($headerAssets))) {
391  $pageRenderer->addHeaderData($headerAssets);
392  }
393  if (!empty(trim($footerAssets))) {
394  $pageRenderer->addFooterData($footerAssets);
395  }
396  }
397 
405  protected function ‪resolveActionMethodName(): string
406  {
407  ‪$actionMethodName = $this->request->getControllerActionName() . 'Action';
408  if (!method_exists($this, ‪$actionMethodName)) {
409  throw new NoSuchActionException('An action "' . ‪$actionMethodName . '" does not exist in controller "' . static::class . '".', 1186669086);
410  }
411  return ‪$actionMethodName;
412  }
413 
423  protected function ‪callActionMethod(RequestInterface ‪$request): ResponseInterface
424  {
425  // incoming request is not needed yet but can be passed into the action in the future like in symfony
426  // todo: support this via method-reflection
427 
428  $preparedArguments = [];
430  foreach ($this->arguments as $argument) {
431  $preparedArguments[] = $argument->getValue();
432  }
433  $validationResult = $this->arguments->validate();
434  if (!$validationResult->hasErrors()) {
435  $this->eventDispatcher->dispatch(new BeforeActionCallEvent(static::class, $this->actionMethodName, $preparedArguments));
436  $actionResult = $this->{$this->actionMethodName}(...$preparedArguments);
437  } else {
438  $actionResult = $this->{$this->errorMethodName}();
439  }
440 
441  if ($actionResult instanceof ResponseInterface) {
442  return $actionResult;
443  }
444  throw new \RuntimeException(
445  sprintf(
446  'Controller action %s did not return an instance of %s.',
447  static::class . '::' . $this->actionMethodName,
448  ResponseInterface::class
449  ),
450  1638554283
451  );
452  }
453 
460  protected function ‪resolveView(): ViewInterface
461  {
462  if ($this->viewResolver instanceof GenericViewResolver) {
463  /*
464  * This setter is not part of the ViewResolverInterface as it's only necessary to set
465  * the default view class from this point when using the generic view resolver which
466  * must respect the possibly overridden property defaultViewObjectName.
467  */
468  $this->viewResolver->setDefaultViewClass($this->defaultViewObjectName);
469  }
470 
471  ‪$view = $this->viewResolver->resolve(
472  $this->request->getControllerObjectName(),
473  $this->request->getControllerActionName(),
474  $this->request->getFormat()
475  );
477  if (‪$view instanceof AbstractTemplateView) {
478  $renderingContext = ‪$view->getRenderingContext();
479  if ($renderingContext instanceof RenderingContext) {
480  $renderingContext->setRequest($this->request);
481  }
482  $templatePaths = ‪$view->getRenderingContext()->getTemplatePaths();
483  $templatePaths->fillDefaultsByPackageName($this->request->getControllerExtensionKey());
484  $templatePaths->setFormat($this->request->getFormat());
485  }
486  if (method_exists(‪$view, 'injectSettings')) {
487  ‪$view->injectSettings($this->settings);
488  }
489  ‪$view->assign('settings', $this->settings);
490  return ‪$view;
491  }
492 
496  protected function ‪setViewConfiguration(ViewInterface ‪$view): void
497  {
498  $configuration = $this->configurationManager->getConfiguration(
500  );
501  if (!empty($configuration['view']['templateRootPaths'])
502  && is_array($configuration['view']['templateRootPaths'])
503  && method_exists(‪$view, 'setTemplateRootPaths')
504  ) {
505  ‪$view->setTemplateRootPaths($configuration['view']['templateRootPaths']);
506  }
507  if (!empty($configuration['view']['layoutRootPaths'])
508  && is_array($configuration['view']['layoutRootPaths'])
509  && method_exists(‪$view, 'setLayoutRootPaths')
510  ) {
511  ‪$view->setLayoutRootPaths($configuration['view']['layoutRootPaths']);
512  }
513  if (!empty($configuration['view']['partialRootPaths'])
514  && is_array($configuration['view']['partialRootPaths'])
515  && method_exists(‪$view, 'setPartialRootPaths')
516  ) {
517  ‪$view->setPartialRootPaths($configuration['view']['partialRootPaths']);
518  }
519  }
520 
531  protected function ‪errorAction(): ResponseInterface
532  {
533  $this->‪addErrorFlashMessage();
534  if (($response = $this->‪forwardToReferringRequest()) !== null) {
535  return $response->withStatus(400);
536  }
537 
538  $response = $this->‪htmlResponse($this->‪getFlattenedValidationErrorMessage());
539  return $response->withStatus(400);
540  }
541 
548  protected function ‪addErrorFlashMessage(): void
549  {
550  $errorFlashMessage = $this->‪getErrorFlashMessage();
551  if ($errorFlashMessage !== false) {
552  $this->‪addFlashMessage($errorFlashMessage, '', ContextualFeedbackSeverity::ERROR);
553  }
554  }
555 
563  protected function ‪getErrorFlashMessage(): bool|string
564  {
565  return 'An error occurred while trying to call ' . static::class . '->' . $this->actionMethodName . '()';
566  }
567 
576  protected function ‪forwardToReferringRequest(): ?ResponseInterface
577  {
579  $extbaseRequestParameters = $this->request->getAttribute('extbase');
580  $referringRequestArguments = $extbaseRequestParameters->getInternalArgument('__referrer') ?? null;
581  if (is_string($referringRequestArguments['@request'] ?? null)) {
582  $referrerArray = json_decode(
583  $this->hashService->validateAndStripHmac($referringRequestArguments['@request'], HashScope::ReferringRequest->prefix()),
584  true
585  );
586  ‪$arguments = [];
587  if (is_string($referringRequestArguments['arguments'] ?? null)) {
588  ‪$arguments = unserialize(
589  base64_decode($this->hashService->validateAndStripHmac($referringRequestArguments['arguments'], HashScope::ReferringArguments->prefix()))
590  );
591  }
592  $replacedArguments = array_replace_recursive(‪$arguments, $referrerArray);
593  $nonExtbaseBaseArguments = [];
594  foreach ($replacedArguments as $argumentName => $argumentValue) {
595  if (!is_string($argumentName) || $argumentName === '') {
596  throw new InvalidArgumentNameException('Invalid argument name.', 1623940985);
597  }
598  if (str_starts_with($argumentName, '__')
599  || in_array($argumentName, ['@extension', '@subpackage', '@controller', '@action', '@format'], true)
600  ) {
601  // Don't handle internalArguments here, not needed for forwardResponse()
602  continue;
603  }
604  $nonExtbaseBaseArguments[$argumentName] = $argumentValue;
605  }
606  return (new ForwardResponse((string)($replacedArguments['@action'] ?? 'index')))
607  ->withControllerName((string)($replacedArguments['@controller'] ?? 'Standard'))
608  ->withExtensionName((string)($replacedArguments['@extension'] ?? ''))
609  ->withArguments($nonExtbaseBaseArguments)
610  ->withArgumentsValidationResult($this->arguments->validate());
611  }
612 
613  return null;
614  }
615 
623  protected function ‪getFlattenedValidationErrorMessage(): string
624  {
625  return 'Validation failed while trying to call ' . static::class . '->' . $this->actionMethodName . '().' . PHP_EOL;
626  }
627 
634  public function ‪addFlashMessage(
635  string $messageBody,
636  string $messageTitle = '',
637  ‪ContextualFeedbackSeverity $severity = ContextualFeedbackSeverity::OK,
638  bool $storeInSession = true
639  ): void {
640  /* @var FlashMessage $flashMessage */
641  $flashMessage = GeneralUtility::makeInstance(
642  FlashMessage::class,
643  $messageBody,
644  $messageTitle,
645  $severity,
646  $storeInSession
647  );
648 
649  $this->‪getFlashMessageQueue()->enqueue($flashMessage);
650  }
651 
659  protected function ‪getFlashMessageQueue(string ‪$identifier = null): FlashMessageQueue
660  {
661  if (‪$identifier === null) {
662  $pluginNamespace = $this->internalExtensionService->getPluginNamespace(
663  $this->request->getControllerExtensionName(),
664  $this->request->getPluginName()
665  );
666  ‪$identifier = 'extbase.flashmessages.' . $pluginNamespace;
667  }
668 
669  return $this->internalFlashMessageService->getMessageQueueByIdentifier(‪$identifier);
670  }
671 
685  protected function ‪redirect(
686  ?string $actionName,
687  ?string $controllerName = null,
688  ?string $extensionName = null,
689  ?array ‪$arguments = null,
690  ?int $pageUid = null,
691  $_ = null,
692  int ‪$statusCode = 303
693  ): ResponseInterface {
694  if ($controllerName === null) {
695  $controllerName = $this->request->getControllerName();
696  }
697  $this->uriBuilder->reset()->setCreateAbsoluteUri(true);
699  $this->uriBuilder->setTargetPageUid((int)$pageUid);
700  }
701  if (GeneralUtility::getIndpEnv('TYPO3_SSL')) {
702  $this->uriBuilder->setAbsoluteUriScheme('https');
703  }
704  $uri = $this->uriBuilder->uriFor($actionName, ‪$arguments, $controllerName, $extensionName);
705  return $this->‪redirectToUri($uri, null, ‪$statusCode);
706  }
707 
715  protected function ‪redirectToUri(string|UriInterface $uri, $_ = null, int ‪$statusCode = 303): ResponseInterface
716  {
717  $uri = $this->‪addBaseUriIfNecessary((string)$uri);
718  return new RedirectResponse($uri, ‪$statusCode);
719  }
720 
726  protected function ‪addBaseUriIfNecessary(string $uri): string
727  {
728  return GeneralUtility::locationHeaderUrl($uri);
729  }
730 
740  public function ‪throwStatus(int ‪$statusCode, string $statusMessage = '', ?string $content = null): never
741  {
742  if ($content === null) {
743  $content = ‪$statusCode . ' ' . $statusMessage;
744  }
745  $response = $this->responseFactory
746  ->createResponse(‪$statusCode, $statusMessage)
747  ->withBody($this->streamFactory->createStream((string)$content));
748  throw new PropagateResponseException($response, 1476045871);
749  }
750 
758  protected function ‪mapRequestArgumentsToControllerArguments(): void
759  {
761  foreach ($this->arguments as $argument) {
762  $argumentName = $argument->getName();
763  if ($this->request->hasArgument($argumentName)) {
764  $this->‪setArgumentValue($argument, $this->request->getArgument($argumentName));
765  } elseif ($argument->isRequired()) {
766  throw new RequiredArgumentMissingException('Required argument "' . $argumentName . '" is not set for ' . $this->request->getControllerObjectName() . '->' . $this->request->getControllerActionName() . '.', 1298012500);
767  }
768  }
769  }
770 
771  private function ‪setArgumentValue(‪Argument $argument, mixed $rawValue): void
772  {
773  if ($rawValue === null) {
774  $argument->‪setValue(null);
775  return;
776  }
777  $dataType = $argument->‪getDataType();
778  if ($rawValue instanceof $dataType) {
779  $argument->‪setValue($rawValue);
780  return;
781  }
782  $this->propertyMapper->resetMessages();
783  try {
784  $argument->‪setValue(
785  $this->propertyMapper->convert(
786  $rawValue,
787  $dataType,
789  )
790  );
791  } catch (‪TargetNotFoundException $e) {
792  // for optional arguments no exception is thrown.
793  if ($argument->‪isRequired()) {
794  throw $e;
795  }
796  }
797  $argument->‪getValidationResults()->merge($this->propertyMapper->getMessages());
798  }
799 
803  protected function ‪htmlResponse(string $html = null): ResponseInterface
804  {
805  return $this->responseFactory->createResponse()
806  ->withHeader('Content-Type', 'text/html; charset=utf-8')
807  ->withBody($this->streamFactory->createStream(($html ?? $this->view->render())));
808  }
809 
814  protected function ‪jsonResponse(string $json = null): ResponseInterface
815  {
816  return $this->responseFactory->createResponse()
817  ->withHeader('Content-Type', 'application/json; charset=utf-8')
818  ->withBody($this->streamFactory->createStream(($json ?? $this->view->render())));
819  }
820 }
‪TYPO3\CMS\Extbase\Validation\Validator\ConjunctionValidator
Definition: ConjunctionValidator.php:26
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\addFlashMessage
‪addFlashMessage(string $messageBody, string $messageTitle='', ContextualFeedbackSeverity $severity=ContextualFeedbackSeverity::OK, bool $storeInSession=true)
Definition: ActionController.php:633
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\injectViewResolver
‪injectViewResolver(ViewResolverInterface $viewResolver)
Definition: ActionController.php:172
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\throwStatus
‪throwStatus(int $statusCode, string $statusMessage='', ?string $content=null)
Definition: ActionController.php:739
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$request
‪RequestInterface $request
Definition: ActionController.php:106
‪TYPO3\CMS\Extbase\Mvc\Controller\Exception\RequiredArgumentMissingException
Definition: RequiredArgumentMissingException.php:25
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$configurationManager
‪ConfigurationManagerInterface $configurationManager
Definition: ActionController.php:124
‪TYPO3\CMS\Extbase\Mvc\Web\Routing\UriBuilder
Definition: UriBuilder.php:38
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$view
‪ViewInterface $view
Definition: ActionController.php:82
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\addErrorFlashMessage
‪addErrorFlashMessage()
Definition: ActionController.php:547
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\initializeAction
‪initializeAction()
Definition: ActionController.php:233
‪TYPO3\CMS\Extbase\Validation\ValidatorResolver
Definition: ValidatorResolver.php:38
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\resolveActionMethodName
‪resolveActionMethodName()
Definition: ActionController.php:404
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$viewResolver
‪ViewResolverInterface $viewResolver
Definition: ActionController.php:76
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\injectPropertyMapper
‪injectPropertyMapper(PropertyMapper $propertyMapper)
Definition: ActionController.php:206
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$defaultViewObjectName
‪string $defaultViewObjectName
Definition: ActionController.php:90
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$reflectionService
‪ReflectionService $reflectionService
Definition: ActionController.php:71
‪TYPO3\CMS\Extbase\Event\Mvc\BeforeActionCallEvent
Definition: BeforeActionCallEvent.php:25
‪TYPO3\CMS\Extbase\Mvc\Controller\Arguments
Definition: Arguments.php:29
‪TYPO3\CMS\Extbase\Mvc\Exception\InvalidArgumentTypeException
Definition: InvalidArgumentTypeException.php:25
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\mapRequestArgumentsToControllerArguments
‪mapRequestArgumentsToControllerArguments()
Definition: ActionController.php:757
‪TYPO3\CMS\Extbase\Mvc\Controller\Argument\getPropertyMappingConfiguration
‪MvcPropertyMappingConfiguration getPropertyMappingConfiguration()
Definition: Argument.php:249
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$responseFactory
‪ResponseFactoryInterface $responseFactory
Definition: ActionController.php:64
‪TYPO3\CMS\Extbase\Configuration\ConfigurationManagerInterface
Definition: ConfigurationManagerInterface.php:28
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$eventDispatcher
‪EventDispatcherInterface $eventDispatcher
Definition: ActionController.php:105
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\injectStreamFactory
‪injectStreamFactory(StreamFactoryInterface $streamFactory)
Definition: ActionController.php:146
‪TYPO3\CMS\Extbase\Http\ForwardResponse
Definition: ForwardResponse.php:24
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\processRequest
‪processRequest(RequestInterface $request)
Definition: ActionController.php:333
‪TYPO3\CMS\Extbase\Mvc\Controller
Definition: ActionController.php:16
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\injectInternalFlashMessageService
‪injectInternalFlashMessageService(FlashMessageService $flashMessageService)
Definition: ActionController.php:214
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\getErrorFlashMessage
‪getErrorFlashMessage()
Definition: ActionController.php:562
‪TYPO3\CMS\Fluid\View\TemplateView
Definition: TemplateView.php:22
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\forwardToReferringRequest
‪forwardToReferringRequest()
Definition: ActionController.php:575
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\initializeControllerArgumentsBaseValidators
‪initializeControllerArgumentsBaseValidators()
Definition: ActionController.php:317
‪TYPO3\CMS\Extbase\Configuration\ConfigurationManagerInterface\CONFIGURATION_TYPE_FRAMEWORK
‪const CONFIGURATION_TYPE_FRAMEWORK
Definition: ConfigurationManagerInterface.php:29
‪TYPO3\CMS\Extbase\Mvc\Controller\Argument\getValidationResults
‪getValidationResults()
Definition: Argument.php:290
‪TYPO3\CMS\Extbase\Reflection\ReflectionService
Definition: ReflectionService.php:28
‪TYPO3\CMS\Core\Type\ContextualFeedbackSeverity
‪ContextualFeedbackSeverity
Definition: ContextualFeedbackSeverity.php:25
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\setArgumentValue
‪setArgumentValue(Argument $argument, mixed $rawValue)
Definition: ActionController.php:770
‪TYPO3\CMS\Core\Utility\MathUtility\canBeInterpretedAsInteger
‪static bool canBeInterpretedAsInteger(mixed $var)
Definition: MathUtility.php:69
‪TYPO3\CMS\Core\Page\PageRenderer
Definition: PageRenderer.php:44
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\htmlResponse
‪htmlResponse(string $html=null)
Definition: ActionController.php:802
‪TYPO3\CMS\Redirects\Message\$statusCode
‪identifier readonly UriInterface readonly int $statusCode
Definition: RedirectWasHitMessage.php:34
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\jsonResponse
‪jsonResponse(string $json=null)
Definition: ActionController.php:813
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\callActionMethod
‪callActionMethod(RequestInterface $request)
Definition: ActionController.php:422
‪TYPO3\CMS\Extbase\Mvc\Controller\Argument\isRequired
‪bool isRequired()
Definition: Argument.php:169
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$settings
‪array $settings
Definition: ActionController.php:112
‪TYPO3\CMS\Extbase\Mvc\View\ViewResolverInterface
Definition: ViewResolverInterface.php:26
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\injectInternalExtensionService
‪injectInternalExtensionService(ExtensionService $extensionService)
Definition: ActionController.php:222
‪$validator
‪if(isset($args['d'])) $validator
Definition: validateRstFiles.php:262
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$mvcPropertyMappingConfigurationService
‪MvcPropertyMappingConfigurationService $mvcPropertyMappingConfigurationService
Definition: ActionController.php:104
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\injectConfigurationManager
‪injectConfigurationManager(ConfigurationManagerInterface $configurationManager)
Definition: ActionController.php:154
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\renderAssetsForRequest
‪renderAssetsForRequest(RequestInterface $request)
Definition: ActionController.php:376
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\initializeActionMethodValidators
‪initializeActionMethodValidators()
Definition: ActionController.php:277
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\addBaseUriIfNecessary
‪addBaseUriIfNecessary(string $uri)
Definition: ActionController.php:725
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$arguments
‪Arguments $arguments
Definition: ActionController.php:119
‪TYPO3\CMS\Extbase\Mvc\View\GenericViewResolver
Definition: GenericViewResolver.php:27
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$validatorResolver
‪ValidatorResolver $validatorResolver
Definition: ActionController.php:117
‪TYPO3\CMS\Extbase\Property\PropertyMapper
Definition: PropertyMapper.php:30
‪TYPO3\CMS\Extbase\Configuration\ConfigurationManagerInterface\getConfiguration
‪array getConfiguration(string $configurationType, ?string $extensionName=null, ?string $pluginName=null)
‪TYPO3\CMS\Extbase\Configuration\ConfigurationManagerInterface\CONFIGURATION_TYPE_SETTINGS
‪const CONFIGURATION_TYPE_SETTINGS
Definition: ConfigurationManagerInterface.php:30
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$hashService
‪HashService $hashService
Definition: ActionController.php:66
‪TYPO3\CMS\Core\Http\PropagateResponseException
Definition: PropagateResponseException.php:47
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\initializeActionMethodArguments
‪initializeActionMethodArguments()
Definition: ActionController.php:246
‪TYPO3\CMS\Core\Http\RedirectResponse
Definition: RedirectResponse.php:30
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\injectReflectionService
‪injectReflectionService(ReflectionService $reflectionService)
Definition: ActionController.php:180
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\setViewConfiguration
‪setViewConfiguration(ViewInterface $view)
Definition: ActionController.php:495
‪TYPO3\CMS\Extbase\Mvc\Exception\InvalidArgumentNameException
Definition: InvalidArgumentNameException.php:25
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\redirect
‪redirect(?string $actionName, ?string $controllerName=null, ?string $extensionName=null, ?array $arguments=null, ?int $pageUid=null, $_=null, int $statusCode=303)
Definition: ActionController.php:684
‪TYPO3\CMS\Extbase\Mvc\RequestInterface
Definition: RequestInterface.php:24
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$errorMethodName
‪string $errorMethodName
Definition: ActionController.php:102
‪TYPO3\CMS\Core\Messaging\FlashMessage
Definition: FlashMessage.php:27
‪TYPO3\CMS\Extbase\Service\ExtensionService
Definition: ExtensionService.php:34
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\errorAction
‪errorAction()
Definition: ActionController.php:530
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController
Definition: ActionController.php:63
‪TYPO3\CMS\Extbase\Security\HashScope
‪HashScope
Definition: HashScope.php:25
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\getFlashMessageQueue
‪getFlashMessageQueue(string $identifier=null)
Definition: ActionController.php:658
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\injectEventDispatcher
‪injectEventDispatcher(EventDispatcherInterface $eventDispatcher)
Definition: ActionController.php:198
‪TYPO3\CMS\Core\Utility\MathUtility
Definition: MathUtility.php:24
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\injectResponseFactory
‪injectResponseFactory(ResponseFactoryInterface $responseFactory)
Definition: ActionController.php:141
‪TYPO3\CMS\Extbase\Mvc\Controller\MvcPropertyMappingConfigurationService
Definition: MvcPropertyMappingConfigurationService.php:51
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\injectMvcPropertyMappingConfigurationService
‪injectMvcPropertyMappingConfigurationService(MvcPropertyMappingConfigurationService $mvcPropertyMappingConfigurationService)
Definition: ActionController.php:193
‪TYPO3\CMS\Extbase\Mvc\Controller\ControllerInterface
Definition: ControllerInterface.php:25
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$internalExtensionService
‪ExtensionService $internalExtensionService
Definition: ActionController.php:139
‪TYPO3\CMS\Extbase\Mvc\Exception\NoSuchActionException
Definition: NoSuchActionException.php:25
‪TYPO3\CMS\Extbase\Mvc\Controller\Argument\getDataType
‪string getDataType()
Definition: Argument.php:147
‪TYPO3\CMS\Extbase\Mvc\ExtbaseRequestParameters
Definition: ExtbaseRequestParameters.php:35
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$streamFactory
‪StreamFactoryInterface $streamFactory
Definition: ActionController.php:65
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\injectValidatorResolver
‪injectValidatorResolver(ValidatorResolver $validatorResolver)
Definition: ActionController.php:164
‪TYPO3\CMS\Core\Utility\GeneralUtility
Definition: GeneralUtility.php:52
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$internalFlashMessageService
‪FlashMessageService $internalFlashMessageService
Definition: ActionController.php:134
‪TYPO3\CMS\Fluid\Core\Rendering\RenderingContext
Definition: RenderingContext.php:35
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$uriBuilder
‪UriBuilder $uriBuilder
Definition: ActionController.php:107
‪TYPO3\CMS\Extbase\Property\Exception\TargetNotFoundException
Definition: TargetNotFoundException.php:25
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\resolveView
‪resolveView()
Definition: ActionController.php:459
‪TYPO3\CMS\Core\Messaging\FlashMessageQueue
Definition: FlashMessageQueue.php:29
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\getFlattenedValidationErrorMessage
‪getFlattenedValidationErrorMessage()
Definition: ActionController.php:622
‪TYPO3\CMS\Extbase\Validation\Validator\ValidatorInterface
Definition: ValidatorInterface.php:26
‪TYPO3\CMS\Core\Crypto\HashService
Definition: HashService.php:27
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$actionMethodName
‪string $actionMethodName
Definition: ActionController.php:97
‪TYPO3\CMS\Extbase\Mvc\Controller\Argument
Definition: Argument.php:27
‪TYPO3\CMS\Extbase\Mvc\Request
Definition: Request.php:35
‪TYPO3\CMS\Core\Messaging\FlashMessageService
Definition: FlashMessageService.php:27
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\redirectToUri
‪redirectToUri(string|UriInterface $uri, $_=null, int $statusCode=303)
Definition: ActionController.php:714
‪TYPO3\CMS\Webhooks\Message\$identifier
‪identifier readonly string $identifier
Definition: FileAddedMessage.php:37
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\injectHashService
‪injectHashService(HashService $hashService)
Definition: ActionController.php:188
‪TYPO3\CMS\Extbase\Mvc\Controller\Argument\setValue
‪Argument setValue($rawValue)
Definition: Argument.php:225
‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController\$propertyMapper
‪PropertyMapper $propertyMapper
Definition: ActionController.php:129