lang : en
navigation
Un script perl qui vérifie si les paramètres des méthodes et les propriétés des classes PHP ont été définis.
liste les méthodes et les propriétés des fichiers .php dans le dossier dummy
phpclasscheck.pl tests/dummy/
class ClassParameterNotDeclared (methods) protected function doThis($iterations) protected function doThat($duration) class ClassParameterNotDeclared (properties) this that class ClassPropertyNotDeclared (methods) public function doThis($param) public function doThat($param) public function doThisAndThat($param) class ClassPropertyNotDeclared (properties) this that thisandthat
liste les méthodes uniquement
phpclasscheck.pl -m tests/dummy/
class ClassParameterNotDeclared (methods) protected function doThis($iterations) protected function doThat($duration) class ClassPropertyNotDeclared (methods) public function doThis($param) public function doThat($param) public function doThisAndThat($param)
vérifir les propriétés uniquement
phpclasscheck.pl -cp ClassParamterNotDeclared.php
class ClassParameterNotDeclared (properties) \o/
vérifie les propriétés en mode bavard
phpclasscheck.pl -cpv ClassParamterNotDeclared.php
found property this declared as protected $this on line 6 found property that declared as protected $that on line 7
vérifie en mode bavard
phpclasscheck.pl -cv tests/dummy/
class ClassParameterNotDeclared (methods) parameter $iterations declared as iterations line 9 parameter $duration NOT DECLARED, used on line 15 found 1 error class ClassParameterNotDeclared (properties) property this declared as protected $this line 6 property that declared as protected $that line 7 class ClassPropertyNotDeclared (methods) parameter $param declared as param line 6 class ClassPropertyNotDeclared (properties) property this NOT DECLARED, used on line 12 property that declared as protected $that line 8 property thisandthat declared as protected $thisandthat line 9 found 1 error
version : 0.1
released : 3 mars 2014
language : Perl
License : GPL