| 1 | <?php |
||
| 26 | class CodingStandard_Sniffs_NamingConventions_ValidTraitNameSniff implements PHP_CodeSniffer_Sniff |
||
|
1 ignored issue
–
show
|
|||
| 27 | { |
||
| 28 | |||
| 29 | /** |
||
| 30 | * A list of tokenizers this sniff supports. |
||
| 31 | * |
||
| 32 | * @var array |
||
| 33 | */ |
||
| 34 | public $supportedTokenizers = array('PHP'); |
||
| 35 | |||
| 36 | |||
| 37 | /** |
||
| 38 | * Returns an array of tokens this test wants to listen for. |
||
| 39 | * |
||
| 40 | * @return integer[] |
||
| 41 | */ |
||
| 42 | public function register() |
||
| 47 | |||
| 48 | |||
| 49 | /** |
||
| 50 | * Processes this test, when one of its tokens is encountered. |
||
| 51 | * |
||
| 52 | * @param PHP_CodeSniffer_File $phpcsFile All the tokens found in the document. |
||
| 53 | * @param int $stackPtr The position of the current token in |
||
| 54 | * the stack passed in $tokens. |
||
| 55 | * |
||
| 56 | * @return void |
||
| 57 | */ |
||
| 58 | public function process(PHP_CodeSniffer_File $phpcsFile, $stackPtr) |
||
| 72 | |||
| 73 | |||
| 74 | }//end class |
||
| 75 |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.