Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有没有办法将@method签名中的参数标记为phpDoc中的可选?
像这样的东西:
/* * @method bool alloc() alloc(int $filesize [, string &$result]) Allocates space for a file to be uploaded */
通常,phpDocumentor 通过查看方法签名中 arg 的默认值来识别可选参数。因此,使用您的示例:
@method bool alloc() alloc(int $filesize, string &$result = '') Allocates space for ...