Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. ParserChain.php

function ParserChain::forMethod

@psalm-param class-string $className @psalm-param non-empty-string $methodName

Overrides Parser::forMethod

1 call to ParserChain::forMethod()
ParserChain::forClassAndMethod in vendor/phpunit/phpunit/src/Metadata/Parser/ParserChain.php
@psalm-param class-string $className @psalm-param non-empty-string $methodName

File

vendor/phpunit/phpunit/src/Metadata/Parser/ParserChain.php, line 53

Class

ParserChain
@no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit

Namespace

PHPUnit\Metadata\Parser

Code

public function forMethod(string $className, string $methodName) : MetadataCollection {
    assert(class_exists($className));
    assert(method_exists($className, $methodName));
    $metadata = $this->attributeReader
        ->forMethod($className, $methodName);
    if (!$metadata->isEmpty()) {
        return $metadata;
    }
    return $this->annotationReader
        ->forMethod($className, $methodName);
}
RSS feed
Powered by Drupal