Sniffs/PHP/NewFunctionParametersSniff.php 1 location
|
@@ 80-93 (lines=14) @@
|
| 77 |
|
* |
| 78 |
|
* @return array |
| 79 |
|
*/ |
| 80 |
|
public function register() |
| 81 |
|
{ |
| 82 |
|
// Everyone has had a chance to figure out what forbidden functions |
| 83 |
|
// they want to check for, so now we can cache out the list. |
| 84 |
|
$this->newFunctionParametersNames = array_keys($this->newFunctionParameters); |
| 85 |
|
|
| 86 |
|
if ($this->patternMatch === true) { |
| 87 |
|
foreach ($this->newFunctionParametersNames as $i => $name) { |
| 88 |
|
$this->newFunctionParametersNames[$i] = '/'.$name.'/i'; |
| 89 |
|
} |
| 90 |
|
} |
| 91 |
|
|
| 92 |
|
return array(T_STRING); |
| 93 |
|
}//end register() |
| 94 |
|
|
| 95 |
|
/** |
| 96 |
|
* Processes this test, when one of its tokens is encountered. |
Sniffs/PHP/NewFunctionsSniff.php 1 location
|
@@ 1190-1204 (lines=15) @@
|
| 1187 |
|
* |
| 1188 |
|
* @return array |
| 1189 |
|
*/ |
| 1190 |
|
public function register() |
| 1191 |
|
{ |
| 1192 |
|
// Everyone has had a chance to figure out what forbidden functions |
| 1193 |
|
// they want to check for, so now we can cache out the list. |
| 1194 |
|
$this->forbiddenFunctionNames = array_keys($this->forbiddenFunctions); |
| 1195 |
|
|
| 1196 |
|
if ($this->patternMatch === true) { |
| 1197 |
|
foreach ($this->forbiddenFunctionNames as $i => $name) { |
| 1198 |
|
$this->forbiddenFunctionNames[$i] = '/'.$name.'/i'; |
| 1199 |
|
} |
| 1200 |
|
} |
| 1201 |
|
|
| 1202 |
|
return array(T_STRING); |
| 1203 |
|
|
| 1204 |
|
}//end register() |
| 1205 |
|
|
| 1206 |
|
/** |
| 1207 |
|
* Processes this test, when one of its tokens is encountered. |
Sniffs/PHP/RemovedFunctionParametersSniff.php 1 location
|
@@ 65-78 (lines=14) @@
|
| 62 |
|
* |
| 63 |
|
* @return array |
| 64 |
|
*/ |
| 65 |
|
public function register() |
| 66 |
|
{ |
| 67 |
|
// Everyone has had a chance to figure out what forbidden functions |
| 68 |
|
// they want to check for, so now we can cache out the list. |
| 69 |
|
$this->removedFunctionParametersNames = array_keys($this->removedFunctionParameters); |
| 70 |
|
|
| 71 |
|
if ($this->patternMatch === true) { |
| 72 |
|
foreach ($this->removedFunctionParametersNames as $i => $name) { |
| 73 |
|
$this->removedFunctionParametersNames[$i] = '/'.$name.'/i'; |
| 74 |
|
} |
| 75 |
|
} |
| 76 |
|
|
| 77 |
|
return array(T_STRING); |
| 78 |
|
}//end register() |
| 79 |
|
|
| 80 |
|
/** |
| 81 |
|
* Processes this test, when one of its tokens is encountered. |
Sniffs/PHP/DeprecatedFunctionsSniff.php 1 location
|
@@ 636-650 (lines=15) @@
|
| 633 |
|
* |
| 634 |
|
* @return array |
| 635 |
|
*/ |
| 636 |
|
public function register() |
| 637 |
|
{ |
| 638 |
|
// Everyone has had a chance to figure out what forbidden functions |
| 639 |
|
// they want to check for, so now we can cache out the list. |
| 640 |
|
$this->forbiddenFunctionNames = array_keys($this->forbiddenFunctions); |
| 641 |
|
|
| 642 |
|
if ($this->patternMatch === true) { |
| 643 |
|
foreach ($this->forbiddenFunctionNames as $i => $name) { |
| 644 |
|
$this->forbiddenFunctionNames[$i] = '/'.$name.'/i'; |
| 645 |
|
} |
| 646 |
|
} |
| 647 |
|
|
| 648 |
|
return array(T_STRING); |
| 649 |
|
|
| 650 |
|
}//end register() |
| 651 |
|
|
| 652 |
|
|
| 653 |
|
/** |