Lines Matching refs:phpcsFile
53 * @param PHP_CodeSniffer_File $phpcsFile The file being scanned.
59 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
61 $tokens = $phpcsFile->getTokens();
64 $methodProps = $phpcsFile->getMethodProperties($stackPtr);
78 if ($phpcsFile->hasCondition($stackPtr, T_INTERFACE) === true) {
84 $phpcsFile->addWarning($error, $stackPtr, 'Abstract');
88 $decName = $phpcsFile->getDeclarationName($stackPtr);
99 $phpcsFile->addWarning($error, $stackPtr, 'MissingBrace', $data);
112 $next = $phpcsFile->findNext(T_WHITESPACE, ($closingBracket + 1), null, true);
115 …$fix = $phpcsFile->addFixableError('Expected %s directly after closing brace', $closingBracket, 'M…
117 $phpcsFile->fixer->beginChangeset();
119 $phpcsFile->fixer->replaceToken($i, '');
124 $phpcsFile->fixer->replaceToken($next, $comment.$phpcsFile->eolChar);
125 $phpcsFile->fixer->endChangeset();
128 … $fix = $phpcsFile->addFixableError('Expected %s', $closingBracket, 'Missing', $data);
130 … $phpcsFile->fixer->replaceToken($closingBracket, '}'.$comment.$phpcsFile->eolChar);
138 $fix = $phpcsFile->addFixableError('Expected %s', $closingBracket, 'Incorrect', $data);
140 … $phpcsFile->fixer->replaceToken(($closingBracket + 1), $comment.$phpcsFile->eolChar);