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

Breadcrumb

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

function Text::printTitle

Prints the title area for a single sniff.

Parameters

\DOMNode $doc The DOMNode object for the sniff.: It represents the "documentation" tag in the XML standard file.

Return value

void

1 call to Text::printTitle()
Text::processSniff in vendor/squizlabs/php_codesniffer/src/Generators/Text.php
Process the documentation for a single sniff.

File

vendor/squizlabs/php_codesniffer/src/Generators/Text.php, line 53

Class

Text

Namespace

PHP_CodeSniffer\Generators

Code

protected function printTitle(DOMNode $doc) {
    $title = $this->getTitle($doc);
    $standard = $this->ruleset->name;
    echo PHP_EOL;
    echo str_repeat('-', strlen("{$standard} CODING STANDARD: {$title}") + 4);
    echo strtoupper(PHP_EOL . "| {$standard} CODING STANDARD: {$title} |" . PHP_EOL);
    echo str_repeat('-', strlen("{$standard} CODING STANDARD: {$title}") + 4);
    echo PHP_EOL . PHP_EOL;
}

API Navigation

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