@property[<-read|-write>] [Type] [name] [<description>]
توصیف ویژگیهای مجازی در کلاس برای استفاده در میجک متد ها.
/**
* @property-read int $id The ID of the user
* @property string $name The name of the user
*/
class User {}
———
@return [Type] [<description>]
توصیف خروجی تابع.
/**
* @return float The calculated result
*/
function compute() {
// Implementation
}
———
@see [URI | FQSEN] [<description>]
ارجاع به دیگر عناصر مستند.
/**
* @see otherFunction() For basic functionality
*/
———
@since [<version>] [<description>]
نشان دهنده نسخهای که عنصر خاصی در آن اضافه یا تغییر کرده است.
/**
* @since 1.0
*/
———
@source [<start-line> [<number-of-lines>] ] [<description>]
نمایش قسمتی از کد منبع.
/**
* @source 2 1 Check that ensures lazy counting.
*/
function count()
{
if (null === $this->count) {
// ...
}
}
———
@subpackage [name]
زیرمجموعهای از بستهای که به آن تعلق دارد.
/**
* @package PSR
* @subpackage Documentation\API
*/
———
@throws [Type] [<description>]
استثناءهایی که ممکن است تابع بدهد.
/**
* @throws Exception If the file cannot be opened.
*/
function openFile($filename) {
// Implementation
}
———
@todo [description]
کارهایی که باید در آینده انجام شوند.
/**
* @todo Implement the rest of the method.
*/
———
@uses [FQSEN] [<description>]
نشان دهنده استفاده از یک عنصر توسط دیگری.
/**
* @uses functionB() Used by functionA for processing.
*/
———
@var ["Type"] [element_name] [<description>]
توصیف نوع یک متغیر، مفید در متغیرهای کلاس.
/**
* @var string $name The name of the person
*/
protected $name;
———
@version [<Semantic Version>] [<description>]
نسخه کد یا کلاس.
/**
* @version 1.0.0
*/
👤 AmirHossein
💎 Channel: @DevelopixPHP