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

Breadcrumb

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

function Util::triggerClassDeprecationNotice

@psalm-suppress ArgumentTypeCoercion

File

vendor/open-telemetry/sdk/Common/Dev/Compatibility/Util.php, line 36

Class

Util

Namespace

OpenTelemetry\SDK\Common\Dev\Compatibility

Code

public static function triggerClassDeprecationNotice(string $className, ?string $alternativeClassName = null) : void {
    if (self::getErrorLevel() === self::E_NONE) {
        return;
    }
    $notice = sprintf('Class "%s" is deprecated and will be removed in a future release. ', $className);
    if ($alternativeClassName !== null) {
        $notice .= sprintf('Please, use "%s" instead.', $alternativeClassName);
    }
    trigger_error($notice, self::$errorLevel);
}

API Navigation

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