Home
last modified time | relevance | path

Searched refs:stackPtr (Results 51 – 75 of 219) sorted by path

123456789

/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Generic/Sniffs/PHP/
H A DBacktickOperatorSniff.php50 * @param int $stackPtr The position of the current token
55 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
58 $phpcsFile->addError($error, $stackPtr, 'Found');
H A DCharacterBeforePHPOpeningTagSniff.php46 * @param int $stackPtr The position of the current token in
51 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
54 if ($stackPtr > 0) {
62 if ($stackPtr !== $expected) {
64 $phpcsFile->addError($error, $stackPtr, 'Found');
H A DClosingPHPTagSniff.php46 * @param int $stackPtr The position of the current token in
51 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
53 $closeTag = $phpcsFile->findNext(T_CLOSE_TAG, $stackPtr);
56 $phpcsFile->addError($error, $stackPtr, 'NotFound');
H A DDeprecatedFunctionsSniff.php73 * @param int $stackPtr The position of the forbidden function
80 protected function addError($phpcsFile, $stackPtr, $function, $pattern=null) argument
87 $phpcsFile->addError($error, $stackPtr, $type, $data);
89 $phpcsFile->addWarning($error, $stackPtr, $type, $data);
H A DDisallowAlternativePHPTagsSniff.php82 * @param int $stackPtr The position of the current token
87 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
90 $openTag = $tokens[$stackPtr];
112 $phpcsFile->addError($error, $stackPtr, $errorCode, $data);
116 $this->addChangeset($phpcsFile, $tokens, $stackPtr, $closer);
126 $nextVar = $phpcsFile->findNext(T_WHITESPACE, ($stackPtr + 1), null, true);
134 $closer = $this->findClosingTag($phpcsFile, $tokens, $stackPtr, '%>');
137 $phpcsFile->addError($error, $stackPtr, 'ASPShortOpenTagFound', $data);
157 $phpcsFile->addError($error, $stackPtr, 'ScriptOpenTagFound', $data);
215 * @param int $stackPtr The position of the current token
[all …]
H A DDisallowShortOpenTagSniff.php60 * @param int $stackPtr The position of the current token
65 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
68 $token = $tokens[$stackPtr];
76 …if (isset($tokens[($stackPtr + 1)]) === true && $tokens[($stackPtr + 1)]['code'] !== T_WHITESPACE)…
81 $phpcsFile->fixer->replaceToken($stackPtr, $correctOpening);
99 if ($tokens[($stackPtr + 1)]['code'] !== T_WHITESPACE) {
100 $phpcsFile->fixer->replaceToken($stackPtr, '<?php echo ');
102 $phpcsFile->fixer->replaceToken($stackPtr, '<?php echo');
118 for ($i = $stackPtr; $i < $phpcsFile->numTokens; $i++) {
125 if ($i !== $stackPtr) {
[all …]
H A DForbiddenFunctionsSniff.php117 * @param int $stackPtr The position of the current token in
122 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
141 $prevToken = $phpcsFile->findPrevious(T_WHITESPACE, ($stackPtr - 1), null, true);
158 $nextToken = $phpcsFile->findNext(T_WHITESPACE, ($stackPtr + 1), null, true);
164 …if ($tokens[$stackPtr]['code'] === T_STRING && $tokens[$nextToken]['code'] !== T_OPEN_PARENTHESIS)…
169 $function = strtolower($tokens[$stackPtr]['content']);
194 $this->addError($phpcsFile, $stackPtr, $tokens[$stackPtr]['content'], $pattern);
203 * @param int $stackPtr The position of the forbidden function
210 protected function addError($phpcsFile, $stackPtr, $function, $pattern=null) argument
235 $phpcsFile->addError($error, $stackPtr, $type, $data);
[all …]
H A DLowerCaseConstantSniff.php64 * @param int $stackPtr The position of the current token in the
69 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
72 $keyword = $tokens[$stackPtr]['content'];
76 $phpcsFile->recordMetric($stackPtr, 'PHP constant case', 'upper');
78 $phpcsFile->recordMetric($stackPtr, 'PHP constant case', 'mixed');
87 $fix = $phpcsFile->addFixableError($error, $stackPtr, 'Found', $data);
89 $phpcsFile->fixer->replaceToken($stackPtr, $expected);
92 $phpcsFile->recordMetric($stackPtr, 'PHP constant case', 'lower');
H A DLowerCaseKeywordSniff.php115 * @param int $stackPtr The position of the current token in the
120 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
123 $keyword = $tokens[$stackPtr]['content'];
126 $phpcsFile->recordMetric($stackPtr, 'PHP keyword case', 'upper');
128 $phpcsFile->recordMetric($stackPtr, 'PHP keyword case', 'mixed');
137 $fix = $phpcsFile->addFixableError($error, $stackPtr, 'Found', $data);
139 $phpcsFile->fixer->replaceToken($stackPtr, strtolower($keyword));
142 $phpcsFile->recordMetric($stackPtr, 'PHP keyword case', 'lower');
H A DNoSilencedErrorsSniff.php60 * @param int $stackPtr The position of the current token
65 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
70 $phpcsFile->addError($error, $stackPtr, 'Forbidden');
73 $phpcsFile->addWarning($error, $stackPtr, 'Discouraged');
H A DSAPIUsageSniff.php48 * @param int $stackPtr The position of the current token in
53 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
64 $prevToken = $phpcsFile->findPrevious(T_WHITESPACE, ($stackPtr - 1), null, true);
70 $function = strtolower($tokens[$stackPtr]['content']);
73 $phpcsFile->addError($error, $stackPtr, 'FunctionFound');
H A DSyntaxSniff.php57 * @param int $stackPtr The position of the current token in
62 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
H A DUpperCaseConstantSniff.php54 * @param int $stackPtr The position of the current token in the
59 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
62 $keyword = $tokens[$stackPtr]['content'];
66 $phpcsFile->recordMetric($stackPtr, 'PHP constant case', 'lower');
68 $phpcsFile->recordMetric($stackPtr, 'PHP constant case', 'mixed');
77 $fix = $phpcsFile->addFixableError($error, $stackPtr, 'Found', $data);
79 $phpcsFile->fixer->replaceToken($stackPtr, $expected);
82 $phpcsFile->recordMetric($stackPtr, 'PHP constant case', 'upper');
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Generic/Sniffs/Strings/
H A DUnnecessaryStringConcatSniff.php79 * @param int $stackPtr The position of the current token
84 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
88 if ($tokens[$stackPtr]['code'] === T_STRING_CONCAT) {
98 $prev = $phpcsFile->findPrevious(T_WHITESPACE, ($stackPtr - 1), null, true);
99 $next = $phpcsFile->findNext(T_WHITESPACE, ($stackPtr + 1), null, true);
128 $phpcsFile->addError($error, $stackPtr, 'Found');
130 $phpcsFile->addWarning($error, $stackPtr, 'Found');
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Generic/Sniffs/VersionControl/
H A DSubversionPropertiesSniff.php62 * @param int $stackPtr The position of the current token
67 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
73 $prevOpenTag = $phpcsFile->findPrevious(T_OPEN_TAG, ($stackPtr - 1));
95 $phpcsFile->addError($error, $stackPtr, 'Unexpected', $data);
107 $phpcsFile->addError($error, $stackPtr, 'Missing', $data);
120 $phpcsFile->addError($error, $stackPtr, 'NoMatch', $data);
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Generic/Sniffs/WhiteSpace/
H A DDisallowSpaceIndentSniff.php66 * @param int $stackPtr The position of the current token in
71 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
92 for ($i = ($stackPtr + 1); $i < $phpcsFile->numTokens; $i++) {
H A DDisallowTabIndentSniff.php61 * @param int $stackPtr The position of the current token in
66 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
79 for ($i = ($stackPtr + 1); $i < $phpcsFile->numTokens; $i++) {
H A DScopeIndentSniff.php137 * @param int $stackPtr The position of the current token
142 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
162 $lastOpenTag = $stackPtr;
169 $first = $phpcsFile->findFirstOnLine(T_INLINE_HTML, $stackPtr);
172 $currentIndent = ($tokens[$stackPtr]['column'] - 1);
178 $line = $tokens[$stackPtr]['line'];
179 echo "Start with token $stackPtr on line $line with indent $currentIndent".PHP_EOL;
200 for ($i = ($stackPtr + 1); $i < $phpcsFile->numTokens; $i++) {
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/MySource/Sniffs/CSS/
H A DBrowserSpecificStylesSniff.php72 * @param int $stackPtr The position in the stack where
77 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
90 $content = $tokens[$stackPtr]['content'];
94 $phpcsFile->addError($error, $stackPtr, 'ForbiddenStyle');
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/MySource/Sniffs/Channels/
H A DDisallowSelfActionsSniff.php46 * @param int $stackPtr The position of the current token in
51 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
56 $prev = $phpcsFile->findPrevious(T_WHITESPACE, ($stackPtr - 1), null, true);
62 $classNameToken = $phpcsFile->findNext(T_WHITESPACE, ($stackPtr + 1), null, true);
72 $classEnd = $tokens[$stackPtr]['scope_closer'];
H A DIncludeOwnSystemSniff.php46 * @param int $stackPtr The position of the current token in
51 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
63 … $typeName = $phpcsFile->findNext(T_CONSTANT_ENCAPSED_STRING, ($stackPtr + 2), null, false, true);
65 switch (strtolower($tokens[($stackPtr + 1)]['content'])) {
82 $phpcsFile->addError($error, $stackPtr, 'NotRequired', $data);
93 * @param int $stackPtr The position in the tokens array of the
101 $stackPtr argument
H A DIncludeSystemSniff.php80 $stackPtr, argument
89 ($stackPtr - 1),
115 $class = $phpcsFile->getCondition($stackPtr, T_CLASS);
129 for ($i = ($currScope + 1); $i < $stackPtr; $i++) {
145 if ($phpcsFile->hasCondition($stackPtr, T_CLASS) === true) {
169 if ($phpcsFile->hasCondition($stackPtr, T_CLASS) === true) {
226 if ($tokens[$stackPtr]['code'] === T_EXTENDS) {
260 for ($i = 0; $i < $stackPtr; $i++) {
285 if ($tokens[$stackPtr]['code'] === T_EXTENDS) {
312 $stackPtr argument
[all …]
H A DUnusedSystemSniff.php46 * @param int $stackPtr The position of the current token in
51 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
56 $methodName = strtolower($tokens[($stackPtr + 1)]['content']);
61 $systemName = $phpcsFile->findNext(T_WHITESPACE, ($stackPtr + 3), null, true);
82 $level = $tokens[$stackPtr]['level'];
83 for ($i = ($stackPtr + 1); $i < $phpcsFile->numTokens; $i++) {
89 if ($tokens[$stackPtr]['level'] === $level) {
92 $conditions = array_keys($tokens[$stackPtr]['conditions']);
147 $phpcsFile->addError($error, $stackPtr, 'Found', $data);
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/MySource/Sniffs/Commenting/
H A DFunctionCommentSniff.php42 * @param int $stackPtr The position of the current token
47 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
49 parent::process($phpcsFile, $stackPtr);
55 $commentEnd = $phpcsFile->findPrevious($find, ($stackPtr - 1), null, true);
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/MySource/Sniffs/Debug/
H A DDebugCodeSniff.php46 * @param int $stackPtr The position of the current token in
51 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
55 $className = $phpcsFile->findPrevious(T_WHITESPACE, ($stackPtr - 1), null, true);
57 $method = $phpcsFile->findNext(T_WHITESPACE, ($stackPtr + 1), null, true);
60 $phpcsFile->addError($error, $stackPtr, 'Found', $data);

123456789