Home
last modified time | relevance | path

Searched refs:stackPtr (Results 101 – 125 of 219) sorted by relevance

123456789

/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Generic/Sniffs/Arrays/
H A DDisallowShortArraySyntaxSniff.php46 * @param int $stackPtr The position of the current token
51 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
53 $phpcsFile->recordMetric($stackPtr, 'Short array syntax used', 'yes');
56 $fix = $phpcsFile->addFixableError($error, $stackPtr, 'Found');
60 $opener = $tokens[$stackPtr]['bracket_opener'];
61 $closer = $tokens[$stackPtr]['bracket_closer'];
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Squiz/Sniffs/PHP/
H A DInnerFunctionsSniff.php50 * @param int $stackPtr The position of the current token in the
55 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
59 $function = $phpcsFile->getCondition($stackPtr, T_FUNCTION);
65 $class = $phpcsFile->getCondition($stackPtr, T_ANON_CLASS);
71 $prev = $phpcsFile->findPrevious(T_WHITESPACE, ($stackPtr - 1), null, true);
78 $phpcsFile->addError($error, $stackPtr, 'NotAllowed');
H A DLowercasePHPFunctionsSniff.php69 * @param int $stackPtr The position of the current token in
74 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
79 $next = $phpcsFile->findNext(T_WHITESPACE, ($stackPtr + 1), null, true);
90 … $prev = $phpcsFile->findPrevious(array(T_WHITESPACE, T_BITWISE_AND), ($stackPtr - 1), null, true);
119 $content = $tokens[$stackPtr]['content'];
131 $fix = $phpcsFile->addFixableError($error, $stackPtr, 'CallUppercase', $data);
133 $phpcsFile->fixer->replaceToken($stackPtr, strtolower($content));
H A DCommentedOutCodeSniff.php67 * @param int $stackPtr The position of the current token
72 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
77 if ($stackPtr > 0 && $tokens[$stackPtr]['code'] === $tokens[($stackPtr - 1)]['code']) {
82 if (substr($tokens[$stackPtr]['content'], 0, 6) === '//end ') {
91 for ($i = $stackPtr; $i < $phpcsFile->numTokens; $i++) {
92 if ($tokens[$stackPtr]['code'] !== $tokens[$i]['code']) {
231 $phpcsFile->addWarning($error, $stackPtr, 'Found', $data);
H A DDisallowBooleanStatementSniff.php48 * @param int $stackPtr The position of the current token
53 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
56 if (isset($tokens[$stackPtr]['nested_parenthesis']) === true) {
58 foreach ($tokens[$stackPtr]['nested_parenthesis'] as $open => $close) {
67 $phpcsFile->addError($error, $stackPtr, 'Found');
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Squiz/Sniffs/Classes/
H A DClassFileNameSniff.php54 * @param int $stackPtr The position of the current token in
59 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
69 $decName = $phpcsFile->findNext(T_STRING, $stackPtr);
74 ucfirst($tokens[$stackPtr]['content']),
75 $tokens[$stackPtr]['content'],
78 $phpcsFile->addError($error, $stackPtr, 'NoMatch', $data);
H A DDuplicatePropertySniff.php55 * @param int $stackPtr The position of the current token in the
60 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
70 …$next = $phpcsFile->findNext($wantedTokens, ($stackPtr + 1), $tokens[$stackPtr]['bracket_closer']);
71 while ($next !== false && $next < $tokens[$stackPtr]['bracket_closer']) {
89 … $next = $phpcsFile->findNext($wantedTokens, ($next + 1), $tokens[$stackPtr]['bracket_closer']);
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Generic/Sniffs/Commenting/
H A DDocCommentSniff.php61 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
64 $commentStart = $stackPtr;
65 $commentEnd = $tokens[$stackPtr]['comment_closer'];
76 $phpcsFile->addError($error, $stackPtr, 'Empty');
81 if ($tokens[$short]['line'] === $tokens[$stackPtr]['line']) {
86 $phpcsFile->fixer->addNewline($stackPtr);
123 $phpcsFile->addError($error, $stackPtr, 'MissingShort');
128 if ($tokens[$short]['line'] !== ($tokens[$stackPtr]['line'] + 1)) {
133 for ($i = $stackPtr; $i < $short; $i++) {
214 $indent = str_repeat(' ', $tokens[$stackPtr]['column']);
[all …]
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Generic/Sniffs/Metrics/
H A DCyclomaticComplexitySniff.php66 * @param int $stackPtr The position of the current token
71 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
78 if (isset($tokens[$stackPtr]['scope_opener']) === false) {
83 $start = $tokens[$stackPtr]['scope_opener'];
84 $end = $tokens[$stackPtr]['scope_closer'];
114 $phpcsFile->addError($error, $stackPtr, 'MaxExceeded', $data);
121 $phpcsFile->addWarning($warning, $stackPtr, 'TooHigh', $data);
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Squiz/Sniffs/CSS/
H A DSemicolonSpacingSniff.php55 * @param int $stackPtr The position in the stack where
60 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
64 $semicolon = $phpcsFile->findNext(T_SEMICOLON, ($stackPtr + 1));
65 if ($semicolon === false || $tokens[$semicolon]['line'] !== $tokens[$stackPtr]['line']) {
67 $phpcsFile->addError($error, $stackPtr, 'NotAtEnd');
75 $fix = $phpcsFile->addFixableError($error, $stackPtr, 'SpaceFound', $data);
H A DMissingColonSniff.php55 * @param int $stackPtr The position in the stack where
60 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
63 $lastLine = $tokens[$stackPtr]['line'];
64 $end = $tokens[$stackPtr]['bracket_closer'];
68 $nested = $phpcsFile->findNext(T_OPEN_CURLY_BRACKET, ($stackPtr + 1), $end);
75 for ($i = ($stackPtr + 1); $i <= $end; $i++) {
H A DEmptyStyleDefinitionSniff.php55 * @param int $stackPtr The position in the stack where
60 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
63 $next = $phpcsFile->findNext(array(T_WHITESPACE, T_COLON), ($stackPtr + 1), null, true);
65 … $tokens[$next]['code'] === T_SEMICOLON || $tokens[$next]['line'] !== $tokens[$stackPtr]['line']) {
67 $phpcsFile->addError($error, $stackPtr, 'Found');
/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/PEAR/Sniffs/NamingConventions/
H A DValidClassNameSniff.php55 * @param int $stackPtr The position of the current token
60 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
64 $className = $phpcsFile->findNext(T_STRING, $stackPtr);
66 $errorData = array(ucfirst($tokens[$stackPtr]['content']));
71 $phpcsFile->addError($error, $stackPtr, 'StartWithCapital', $errorData);
93 $phpcsFile->addError($error, $stackPtr, 'Invalid', $errorData);
106 $phpcsFile->addError($error, $stackPtr, 'Invalid', $data);
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/PEAR/Sniffs/Commenting/
H A DFunctionCommentSniff.php48 * @param int $stackPtr The position of the current token
53 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
59 $commentEnd = $phpcsFile->findPrevious($find, ($stackPtr - 1), null, true);
75 $phpcsFile->recordMetric($stackPtr, 'Function has doc comment', 'no');
78 $phpcsFile->recordMetric($stackPtr, 'Function has doc comment', 'yes');
86 if ($tokens[$commentEnd]['line'] !== ($tokens[$stackPtr]['line'] - 1)) {
103 $this->processReturn($phpcsFile, $stackPtr, $commentStart);
104 $this->processThrows($phpcsFile, $stackPtr, $commentStart);
105 $this->processParams($phpcsFile, $stackPtr, $commentStart);
125 $methodName = $phpcsFile->getDeclarationName($stackPtr);
[all …]
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Squiz/Sniffs/Commenting/
H A DVariableCommentSniff.php41 * @param int $stackPtr The position of the current token
46 public function processMemberVar(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
58 $commentEnd = $phpcsFile->findPrevious($ignore, ($stackPtr - 1), null, true);
63 $phpcsFile->addError('Missing member variable doc comment', $stackPtr, 'Missing');
68 …dError('You must use "/**" style comments for a member variable comment', $stackPtr, 'WrongStyle');
142 * @param int $stackPtr The position where the double quoted
147 protected function processVariable(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
159 * @param int $stackPtr The position where the double quoted
164 protected function processVariableInString(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
H A DFileCommentSniff.php59 * @param int $stackPtr The position of the current token
64 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
69 $commentStart = $phpcsFile->findNext(T_WHITESPACE, ($stackPtr + 1), null, true);
73 $phpcsFile->recordMetric($stackPtr, 'File has doc comment', 'yes');
76 $phpcsFile->addError('Missing file doc comment', $stackPtr, 'Missing');
77 $phpcsFile->recordMetric($stackPtr, 'File has doc comment', 'no');
111 $phpcsFile->addError('Missing file doc comment', $stackPtr, 'Missing');
112 $phpcsFile->recordMetric($stackPtr, 'File has doc comment', 'no');
116 $phpcsFile->recordMetric($stackPtr, 'File has doc comment', 'yes');
119 if ($tokens[$commentStart]['line'] > ($tokens[$stackPtr]['line'] + 1)) {
[all …]
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/MySource/Sniffs/PHP/
H A DAjaxNullComparisonSniff.php49 * @param int $stackPtr The position of the current token in
54 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
59 $commentEnd = $phpcsFile->findPrevious(T_DOC_COMMENT_CLOSE_TAG, $stackPtr);
69 $open = $tokens[$stackPtr]['parenthesis_opener'];
70 $close = $tokens[$stackPtr]['parenthesis_closer'];
81 $start = $tokens[$stackPtr]['scope_opener'];
82 $end = $tokens[$stackPtr]['scope_closer'];
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Generic/Sniffs/PHP/
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');
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/PSR2/Sniffs/ControlStructures/
H A DControlStructureSpacingSniff.php74 * @param int $stackPtr The position of the current token
79 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
85 if (isset($tokens[$stackPtr]['parenthesis_opener']) === false
86 || isset($tokens[$stackPtr]['parenthesis_closer']) === false
91 $parenOpener = $tokens[$stackPtr]['parenthesis_opener'];
92 $parenCloser = $tokens[$stackPtr]['parenthesis_closer'];
102 …$phpcsFile->recordMetric($stackPtr, 'Spaces after control structure open parenthesis', $spaceAfter…
129 …$phpcsFile->recordMetric($stackPtr, 'Spaces before control structure close parenthesis', $spaceBef…
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/PEAR/Sniffs/WhiteSpace/
H A DScopeClosingBraceSniff.php57 * @param int $stackPtr The position of the current token
62 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
68 if (isset($tokens[$stackPtr]['scope_closer']) === false) {
72 $scopeStart = $tokens[$stackPtr]['scope_opener'];
73 $scopeEnd = $tokens[$stackPtr]['scope_closer'];
79 || $tokens[$scopeEnd]['scope_condition'] !== $stackPtr
88 $lineStart = ($stackPtr - 1);
154 if ($tokens[$stackPtr]['code'] === T_CASE
155 || $tokens[$stackPtr]['code'] === T_DEFAULT
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Generic/Sniffs/Formatting/
H A DNoSpaceAfterCastSniff.php50 * @param int $stackPtr The position of the current token in
55 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
59 if ($tokens[($stackPtr + 1)]['code'] !== T_WHITESPACE) {
64 $fix = $phpcsFile->addFixableError($error, $stackPtr, 'SpaceFound');
66 $phpcsFile->fixer->replaceToken(($stackPtr + 1), '');
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Squiz/Sniffs/WhiteSpace/
H A DFunctionSpacingSniff.php57 * @param int $stackPtr The position of the current token
62 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
72 if (isset($tokens[$stackPtr]['scope_closer']) === false) {
74 $closer = $phpcsFile->findNext(T_SEMICOLON, $stackPtr);
76 $closer = $tokens[$stackPtr]['scope_closer'];
138 for ($i = $stackPtr; $i > 0; $i--) {
153 $currentLine = $tokens[$stackPtr]['line'];
173 $i = ($stackPtr - 1);
215 $fix = $phpcsFile->addFixableError($error, $stackPtr, 'Before', $data);
220 $nextSpace = $phpcsFile->findNext(T_WHITESPACE, ($prevContent + 1), $stackPtr);
[all …]
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Squiz/Sniffs/Functions/
H A DGlobalFunctionSniff.php50 * @param int $stackPtr The position of the current token in the
55 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
59 if (empty($tokens[$stackPtr]['conditions']) === true) {
60 $functionName = $phpcsFile->getDeclarationName($stackPtr);
69 $phpcsFile->addWarning($error, $stackPtr, 'Found', $data);
/plugin/icalevents/vendor/squizlabs/php_codesniffer/CodeSniffer/Standards/Generic/Sniffs/Files/
H A DLowercasedFilenameSniff.php46 * @param int $stackPtr The position of the current token in
51 public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) argument
66 $phpcsFile->addError($error, $stackPtr, 'NotFound', $data);
67 $phpcsFile->recordMetric($stackPtr, 'Lowercase filename', 'no');
69 $phpcsFile->recordMetric($stackPtr, 'Lowercase filename', 'yes');

123456789