REDROOM
PHP 8.2.31
Path:
Logout
Edit File
Size: 1.90 KB
Close
//opt/cpanel/ea-wappspector/vendor/squizlabs/php_codesniffer/src/Standards/PSR2/Docs/Classes/PropertyDeclarationStandard.xml
Text
Base64
<documentation title="Property Declarations"> <standard> <![CDATA[ Property names should not be prefixed with an underscore to indicate visibility. Visibility should be used to declare properties rather than the var keyword. Only one property should be declared within a statement. The static declaration must come after the visibility declaration. ]]> </standard> <code_comparison> <code title="Valid: Correct property naming."> <![CDATA[ class Foo { private $<em>bar</em>; } ]]> </code> <code title="Invalid: An underscore prefix used to indicate visibility."> <![CDATA[ class Foo { private $<em>_bar</em>; } ]]> </code> </code_comparison> <code_comparison> <code title="Valid: Visibility of property declared."> <![CDATA[ class Foo { <em>private</em> $bar; } ]]> </code> <code title="Invalid: Var keyword used to declare property."> <![CDATA[ class Foo { <em>var</em> $bar; } ]]> </code> </code_comparison> <code_comparison> <code title="Valid: One property declared per statement."> <![CDATA[ class Foo { private $bar; private $baz; } ]]> </code> <code title="Invalid: Multiple properties declared in one statement."> <![CDATA[ class Foo { private <em>$bar, $baz</em>; } ]]> </code> </code_comparison> <code_comparison> <code title="Valid: If declared as static, the static declaration must come after the visibility declaration."> <![CDATA[ class Foo { public <em>static</em> $bar; private $baz; } ]]> </code> <code title="Invalid: Static declaration before the visibility declaration."> <![CDATA[ class Foo { <em>static<em> protected $bar; } ]]> </code> </code_comparison> </documentation>
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 0 × Files: 2
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
ClassDeclarationStandard.xml
966 B
lrw-r--r--
2025-11-04 16:30:35
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
PropertyDeclarationStandard.xml
1.90 KB
lrw-r--r--
2025-11-04 16:30:35
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).