You are here

public function Psr7RequestValueResolver::supports in Drupal 10

Same name and namespace in other branches
  1. 8 core/lib/Drupal/Core/Controller/ArgumentResolver/Psr7RequestValueResolver.php \Drupal\Core\Controller\ArgumentResolver\Psr7RequestValueResolver::supports()
  2. 9 core/lib/Drupal/Core/Controller/ArgumentResolver/Psr7RequestValueResolver.php \Drupal\Core\Controller\ArgumentResolver\Psr7RequestValueResolver::supports()

File

core/lib/Drupal/Core/Controller/ArgumentResolver/Psr7RequestValueResolver.php, line 36

Class

Psr7RequestValueResolver
Yields a PSR7 request object based on the request object passed along.

Namespace

Drupal\Core\Controller\ArgumentResolver

Code

public function supports(Request $request, ArgumentMetadata $argument) : bool {
  return $argument
    ->getType() == ServerRequestInterface::class;
}