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

Breadcrumb

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

interface DeprecatedSniff

Hierarchy

  • interface \PHP_CodeSniffer\Sniffs\DeprecatedSniff

Expanded class hierarchy of DeprecatedSniff

All classes that implement DeprecatedSniff

1 file declares its use of DeprecatedSniff
Ruleset.php in vendor/squizlabs/php_codesniffer/src/Ruleset.php

File

vendor/squizlabs/php_codesniffer/src/Sniffs/DeprecatedSniff.php, line 18

Namespace

PHP_CodeSniffer\Sniffs
View source
interface DeprecatedSniff {
    
    /**
     * Provide the version number in which the sniff was deprecated.
     *
     * Recommended format for PHPCS native sniffs: "v3.3.0".
     * Recommended format for external sniffs: "StandardName v3.3.0".
     *
     * @return string
     */
    public function getDeprecationVersion();
    
    /**
     * Provide the version number in which the sniff will be removed.
     *
     * Recommended format for PHPCS native sniffs: "v3.3.0".
     * Recommended format for external sniffs: "StandardName v3.3.0".
     *
     * If the removal version is not yet known, it is recommended to set
     * this to: "a future version".
     *
     * @return string
     */
    public function getRemovalVersion();
    
    /**
     * Optionally provide an arbitrary custom message to display with the deprecation.
     *
     * Typically intended to allow for displaying information about what to
     * replace the deprecated sniff with.
     * Example: "Use the Stnd.Cat.SniffName sniff instead."
     * Multi-line messages (containing new line characters) are supported.
     *
     * An empty string can be returned if there is no replacement/no need
     * for a custom message.
     *
     * @return string
     */
    public function getDeprecationMessage();

}

Members

Title Sort descending Modifiers Object type Summary
DeprecatedSniff::getDeprecationMessage public function Optionally provide an arbitrary custom message to display with the deprecation.
DeprecatedSniff::getDeprecationVersion public function Provide the version number in which the sniff was deprecated.
DeprecatedSniff::getRemovalVersion public function Provide the version number in which the sniff will be removed.
RSS feed
Powered by Drupal