PHP Class PHP_CodeSniffer_Reports_VersionControl, PHP_CodeSniffer

PHP version 5
Inheritance: implements PHP_CodeSniffer_Report
Afficher le fichier Open project: squizlabs/php_codesniffer

Protected Properties

Свойство Type Description
$reportName string The name of the report we want in the output.

Méthodes publiques

Méthode Description
generate ( string $cachedData, integer $totalFiles, integer $totalErrors, integer $totalWarnings, integer $totalFixable, boolean $showSources = false, integer $width = 80, boolean $toScreen = true ) : void Prints the author of all errors and warnings, as given by "version control blame".
generateFileReport ( array $report, PHP_CodeSniffer_File $phpcsFile, boolean $showSources = false, integer $width = 80 ) : boolean Generate a partial report for a single processed file.

Méthodes protégées

Méthode Description
getAuthor ( string $line ) : mixed Extract the author from a blame line.
getBlameContent ( string $filename ) : array Gets the blame output.

Method Details

generate() public méthode

Prints the author of all errors and warnings, as given by "version control blame".
public generate ( string $cachedData, integer $totalFiles, integer $totalErrors, integer $totalWarnings, integer $totalFixable, boolean $showSources = false, integer $width = 80, boolean $toScreen = true ) : void
$cachedData string Any partial report data that was returned from generateFileReport during the run.
$totalFiles integer Total number of files processed during the run.
$totalErrors integer Total number of errors found during the run.
$totalWarnings integer Total number of warnings found during the run.
$totalFixable integer Total number of problems that can be fixed.
$showSources boolean Show sources?
$width integer Maximum allowed line width.
$toScreen boolean Is the report being printed to screen?
Résultat void

generateFileReport() public méthode

Function should return TRUE if it printed or stored data about the file and FALSE if it ignored the file. Returning TRUE indicates that the file and its data should be counted in the grand totals.
public generateFileReport ( array $report, PHP_CodeSniffer_File $phpcsFile, boolean $showSources = false, integer $width = 80 ) : boolean
$report array Prepared report data.
$phpcsFile PHP_CodeSniffer_File The file being reported on.
$showSources boolean Show sources?
$width integer Maximum allowed line width.
Résultat boolean

getAuthor() abstract protected méthode

Extract the author from a blame line.
abstract protected getAuthor ( string $line ) : mixed
$line string Line to parse.
Résultat mixed string or false if impossible to recover.

getBlameContent() abstract protected méthode

Gets the blame output.
abstract protected getBlameContent ( string $filename ) : array
$filename string File to blame.
Résultat array

Property Details

$reportName protected_oe property

The name of the report we want in the output.
protected string $reportName
Résultat string