Chris@4: Chris@4: * @copyright 2006-2015 Squiz Pty Ltd (ABN 77 084 670 600) Chris@4: * @license https://github.com/squizlabs/PHP_CodeSniffer/blob/master/licence.txt BSD Licence Chris@4: */ Chris@4: Chris@4: namespace PHP_CodeSniffer\Reports; Chris@4: Chris@4: use PHP_CodeSniffer\Files\File; Chris@4: Chris@4: interface Report Chris@4: { Chris@4: Chris@4: Chris@4: /** Chris@4: * Generate a partial report for a single processed file. Chris@4: * Chris@4: * Function should return TRUE if it printed or stored data about the file Chris@4: * and FALSE if it ignored the file. Returning TRUE indicates that the file and Chris@4: * its data should be counted in the grand totals. Chris@4: * Chris@4: * @param array $report Prepared report data. Chris@4: * @param \PHP_CodeSniffer\File $phpcsFile The file being reported on. Chris@4: * @param bool $showSources Show sources? Chris@4: * @param int $width Maximum allowed line width. Chris@4: * Chris@4: * @return bool Chris@4: */ Chris@4: public function generateFileReport($report, File $phpcsFile, $showSources=false, $width=80); Chris@4: Chris@4: Chris@4: /** Chris@4: * Generate the actual report. Chris@4: * Chris@4: * @param string $cachedData Any partial report data that was returned from Chris@4: * generateFileReport during the run. Chris@4: * @param int $totalFiles Total number of files processed during the run. Chris@4: * @param int $totalErrors Total number of errors found during the run. Chris@4: * @param int $totalWarnings Total number of warnings found during the run. Chris@4: * @param int $totalFixable Total number of problems that can be fixed. Chris@4: * @param bool $showSources Show sources? Chris@4: * @param int $width Maximum allowed line width. Chris@4: * @param bool $interactive Are we running in interactive mode? Chris@4: * @param bool $toScreen Is the report being printed to screen? Chris@4: * Chris@4: * @return void Chris@4: */ Chris@4: public function generate( Chris@4: $cachedData, Chris@4: $totalFiles, Chris@4: $totalErrors, Chris@4: $totalWarnings, Chris@4: $totalFixable, Chris@4: $showSources=false, Chris@4: $width=80, Chris@4: $interactive=false, Chris@4: $toScreen=true Chris@4: ); Chris@4: Chris@4: Chris@4: }//end interface