Zend Studio offers a preset means for adding phpDoc comments to files by providing an input line when including statements, classes, class variables, and constants to the code. Developers are prompted to immediately add a description ensuring that the added elements are documented in their context and in real-time.
phpDoc blocks are descriptive comments that are part of the application code. They are used to describe the PHP element in the exact location in the code where the element appears. The block consists of a short description, long description, and phpDoc tags.
|
Example: When creating a phpDoc Block comment for the following function: function add ($a, $b) { return $a + $b; } the following comment will be created: /** * Enter description here... * * @param unknown_type $a * @param unknown_type $b * @return unknown */ |
The comments should now be edited with the relevant description and parameters. |
Descriptions that are added for a code element are also automatically added to the Content Assist bank so that the next time the code element is used it is readily available from the Content Assist list. The element's descriptions will also appear in the Outline view.
Note:
Zend Studio offers Content Assist support for magic members declared in code comments. See the Content Assist concept for more information.
phpDoc blocks also serve as the input for creating a PHPDoc.
|
|
|
Related Links: |
|
|
©1999-2013 Zend Technologies LTD. All rights reserved.