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

Breadcrumb

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

function DeprecatedScopeCheck::inDeprecatedScope

4 calls to DeprecatedScopeCheck::inDeprecatedScope()
AccessDeprecatedConstant::processNode in vendor/mglaman/phpstan-drupal/src/Rules/Deprecations/AccessDeprecatedConstant.php
RequestStackGetMainRequestRule::processNode in vendor/mglaman/phpstan-drupal/src/Rules/Drupal/RequestStackGetMainRequestRule.php
SymfonyCmfRouteObjectInterfaceConstantsRule::processNode in vendor/mglaman/phpstan-drupal/src/Rules/Deprecations/SymfonyCmfRouteObjectInterfaceConstantsRule.php
SymfonyCmfRoutingInClassMethodSignatureRule::processNode in vendor/mglaman/phpstan-drupal/src/Rules/Deprecations/SymfonyCmfRoutingInClassMethodSignatureRule.php

File

vendor/mglaman/phpstan-drupal/src/Internal/DeprecatedScopeCheck.php, line 9

Class

DeprecatedScopeCheck

Namespace

mglaman\PHPStanDrupal\Internal

Code

public static function inDeprecatedScope(Scope $scope) : bool {
    $class = $scope->getClassReflection();
    if ($class !== null && $class->isDeprecated()) {
        return true;
    }
    $trait = $scope->getTraitReflection();
    if ($trait !== null && $trait->isDeprecated()) {
        return true;
    }
    $function = $scope->getFunction();
    return $function !== null && $function->isDeprecated()
        ->yes();
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal