‪TYPO3CMS  ‪main
TYPO3\CMS\Extbase\Mvc\Request Class Reference
Inheritance diagram for TYPO3\CMS\Extbase\Mvc\Request:
TYPO3\CMS\Extbase\Mvc\RequestInterface

Public Member Functions

 __construct (ServerRequestInterface $request)
 
 getControllerObjectName ()
 
 withControllerObjectName (string $controllerObjectName)
 
 getPluginName ()
 
 withPluginName (string $pluginName)
 
 getControllerExtensionName ()
 
 withControllerExtensionName (string $controllerExtensionName)
 
 getControllerExtensionKey ()
 
 getControllerName ()
 
 withControllerName (string $controllerName)
 
 getControllerActionName ()
 
 withControllerActionName (string $actionName)
 
 getArguments ()
 
 withArguments (array $arguments)
 
 getArgument (string $argumentName)
 
 hasArgument (string $argumentName)
 
 withArgument (string $argumentName, mixed $value)
 
 getFormat ()
 
 withFormat (string $format)
 
 getServerParams ()
 
 getCookieParams ()
 
 withCookieParams (array $cookies)
 
 getQueryParams ()
 
 withQueryParams (array $query)
 
 getUploadedFiles ()
 
 withUploadedFiles (array $uploadedFiles)
 
 getParsedBody ()
 
 withParsedBody ($data)
 
 getAttributes ()
 
 getAttribute ($name, $default=null)
 
 withAttribute ($name, $value)
 
 withoutAttribute ($name)
 
 getRequestTarget ()
 
 withRequestTarget ($requestTarget)
 
 getMethod ()
 
 withMethod ($method)
 
 getUri ()
 
 withUri (UriInterface $uri, $preserveHost=false)
 
 getProtocolVersion ()
 
 withProtocolVersion ($version)
 
 getHeaders ()
 
 hasHeader ($name)
 
 getHeader ($name)
 
 getHeaderLine ($name)
 
 withHeader ($name, $value)
 
 withAddedHeader ($name, $value)
 
 withoutHeader ($name)
 
 getBody ()
 
 withBody (StreamInterface $body)
 

Protected Member Functions

 getExtbaseAttribute ()
 

Protected Attributes

ServerRequestInterface $request
 

Detailed Description

The extbase request.

This is a decorator: The core PSR-7 request is hand over as constructor argument, this class implements ServerRequestInterface, too. Additionally, the extbase request details are attached as 'extbase' attribute to the PSR-7 request and this class implements extbase RequestInterface. This class has no state except the PSR-7 request, all operations are hand down to the PSR-7 request.

Definition at line 34 of file Request.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Extbase\Mvc\Request::__construct ( ServerRequestInterface  $request)
final

Definition at line 38 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\$request.

Member Function Documentation

◆ getArgument()

TYPO3\CMS\Extbase\Mvc\Request::getArgument ( string  $argumentName)

Returns the value of the specified argument.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 171 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute().

◆ getArguments()

TYPO3\CMS\Extbase\Mvc\Request::getArguments ( )

Returns an array of extbase arguments and their values.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 155 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute().

◆ getAttribute()

TYPO3\CMS\Extbase\Mvc\Request::getAttribute (   $name,
  $default = null 
)

◆ getAttributes()

TYPO3\CMS\Extbase\Mvc\Request::getAttributes ( )

Definition at line 266 of file Request.php.

◆ getBody()

TYPO3\CMS\Extbase\Mvc\Request::getBody ( )

Definition at line 379 of file Request.php.

◆ getControllerActionName()

TYPO3\CMS\Extbase\Mvc\Request::getControllerActionName ( )

Returns the name of the action the controller is supposed to execute.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 139 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute().

◆ getControllerExtensionKey()

TYPO3\CMS\Extbase\Mvc\Request::getControllerExtensionKey ( )

Returns the extension key of the specified controller.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 112 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute().

◆ getControllerExtensionName()

TYPO3\CMS\Extbase\Mvc\Request::getControllerExtensionName ( )

Returns the extension name of the specified controller.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 94 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute().

◆ getControllerName()

TYPO3\CMS\Extbase\Mvc\Request::getControllerName ( )

Returns the controller name supposed to handle this request, if one was set already (if not, the name of the default controller is returned)

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 121 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute().

◆ getControllerObjectName()

TYPO3\CMS\Extbase\Mvc\Request::getControllerObjectName ( )

Returns the object name of the controller defined by the package key and controller name.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 58 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute().

◆ getCookieParams()

TYPO3\CMS\Extbase\Mvc\Request::getCookieParams ( )

Definition at line 221 of file Request.php.

◆ getExtbaseAttribute()

◆ getFormat()

TYPO3\CMS\Extbase\Mvc\Request::getFormat ( )

Returns the requested representation format, something like "html", "xml", "png", "json" or the like.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 195 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute().

◆ getHeader()

TYPO3\CMS\Extbase\Mvc\Request::getHeader (   $name)

Definition at line 351 of file Request.php.

◆ getHeaderLine()

TYPO3\CMS\Extbase\Mvc\Request::getHeaderLine (   $name)

Definition at line 356 of file Request.php.

◆ getHeaders()

TYPO3\CMS\Extbase\Mvc\Request::getHeaders ( )

Definition at line 341 of file Request.php.

◆ getMethod()

TYPO3\CMS\Extbase\Mvc\Request::getMethod ( )

Definition at line 305 of file Request.php.

◆ getParsedBody()

TYPO3\CMS\Extbase\Mvc\Request::getParsedBody ( )

Definition at line 255 of file Request.php.

◆ getPluginName()

TYPO3\CMS\Extbase\Mvc\Request::getPluginName ( )

Returns the plugin key.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 76 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute().

◆ getProtocolVersion()

TYPO3\CMS\Extbase\Mvc\Request::getProtocolVersion ( )

Methods implementing MessageInterface

Definition at line 330 of file Request.php.

◆ getQueryParams()

TYPO3\CMS\Extbase\Mvc\Request::getQueryParams ( )

Definition at line 232 of file Request.php.

◆ getRequestTarget()

TYPO3\CMS\Extbase\Mvc\Request::getRequestTarget ( )

Methods implementing RequestInterface

Definition at line 294 of file Request.php.

◆ getServerParams()

TYPO3\CMS\Extbase\Mvc\Request::getServerParams ( )

Methods implementing ServerRequestInterface

Definition at line 216 of file Request.php.

◆ getUploadedFiles()

TYPO3\CMS\Extbase\Mvc\Request::getUploadedFiles ( )

Definition at line 243 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute().

◆ getUri()

TYPO3\CMS\Extbase\Mvc\Request::getUri ( )

Definition at line 316 of file Request.php.

◆ hasArgument()

TYPO3\CMS\Extbase\Mvc\Request::hasArgument ( string  $argumentName)

Checks if an argument of the given name exists (is set).

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 176 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute().

◆ hasHeader()

TYPO3\CMS\Extbase\Mvc\Request::hasHeader (   $name)

Definition at line 346 of file Request.php.

◆ withAddedHeader()

TYPO3\CMS\Extbase\Mvc\Request::withAddedHeader (   $name,
  $value 
)

Definition at line 367 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\$request.

◆ withArgument()

TYPO3\CMS\Extbase\Mvc\Request::withArgument ( string  $argumentName,
mixed  $value 
)

Return an instance with the specified argument set.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 184 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute(), and TYPO3\CMS\Extbase\Mvc\Request\withAttribute().

◆ withArguments()

TYPO3\CMS\Extbase\Mvc\Request::withArguments ( array  $arguments)

Return an instance with the specified extbase arguments, replacing any arguments which existed before.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 164 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute(), and TYPO3\CMS\Extbase\Mvc\Request\withAttribute().

◆ withAttribute()

◆ withBody()

TYPO3\CMS\Extbase\Mvc\Request::withBody ( StreamInterface  $body)

Definition at line 384 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\$request.

◆ withControllerActionName()

TYPO3\CMS\Extbase\Mvc\Request::withControllerActionName ( string  $actionName)

Return an instance with the specified controller action name set. Note that the action name must start with a lower case letter and is case-sensitive.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 148 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute(), and TYPO3\CMS\Extbase\Mvc\Request\withAttribute().

◆ withControllerExtensionName()

TYPO3\CMS\Extbase\Mvc\Request::withControllerExtensionName ( string  $controllerExtensionName)

Return an instance with the specified controller extension name set.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 102 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute(), and TYPO3\CMS\Extbase\Mvc\Request\withAttribute().

◆ withControllerName()

TYPO3\CMS\Extbase\Mvc\Request::withControllerName ( string  $controllerName)

Return an instance with the specified controller name set.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 129 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute(), and TYPO3\CMS\Extbase\Mvc\Request\withAttribute().

◆ withControllerObjectName()

TYPO3\CMS\Extbase\Mvc\Request::withControllerObjectName ( string  $controllerObjectName)

Return an instance with the specified controller object name set.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 66 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute(), and TYPO3\CMS\Extbase\Mvc\Request\withAttribute().

◆ withCookieParams()

TYPO3\CMS\Extbase\Mvc\Request::withCookieParams ( array  $cookies)

Definition at line 226 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\$request.

◆ withFormat()

TYPO3\CMS\Extbase\Mvc\Request::withFormat ( string  $format)

Return an instance with the specified derived request attribute.

This method allows setting a single derived request attribute as described in getFormat().

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 206 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute(), and TYPO3\CMS\Extbase\Mvc\Request\withAttribute().

◆ withHeader()

TYPO3\CMS\Extbase\Mvc\Request::withHeader (   $name,
  $value 
)

Definition at line 361 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\$request.

◆ withMethod()

TYPO3\CMS\Extbase\Mvc\Request::withMethod (   $method)

Definition at line 310 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\$request.

◆ withoutAttribute()

TYPO3\CMS\Extbase\Mvc\Request::withoutAttribute (   $name)

Definition at line 282 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\$request.

◆ withoutHeader()

TYPO3\CMS\Extbase\Mvc\Request::withoutHeader (   $name)

Definition at line 373 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\$request.

◆ withParsedBody()

TYPO3\CMS\Extbase\Mvc\Request::withParsedBody (   $data)

Definition at line 260 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\$request.

◆ withPluginName()

TYPO3\CMS\Extbase\Mvc\Request::withPluginName ( string  $pluginName)

Return an instance with the specified plugin name set.

Implements TYPO3\CMS\Extbase\Mvc\RequestInterface.

Definition at line 84 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\getExtbaseAttribute(), and TYPO3\CMS\Extbase\Mvc\Request\withAttribute().

◆ withProtocolVersion()

TYPO3\CMS\Extbase\Mvc\Request::withProtocolVersion (   $version)

Definition at line 335 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\$request.

◆ withQueryParams()

TYPO3\CMS\Extbase\Mvc\Request::withQueryParams ( array  $query)

Definition at line 237 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\$request.

◆ withRequestTarget()

TYPO3\CMS\Extbase\Mvc\Request::withRequestTarget (   $requestTarget)

Definition at line 299 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\$request.

◆ withUploadedFiles()

TYPO3\CMS\Extbase\Mvc\Request::withUploadedFiles ( array  $uploadedFiles)

◆ withUri()

TYPO3\CMS\Extbase\Mvc\Request::withUri ( UriInterface  $uri,
  $preserveHost = false 
)

Definition at line 321 of file Request.php.

References TYPO3\CMS\Extbase\Mvc\Request\$request.

Member Data Documentation

◆ $request