2016-04-13 17:20:24 5946次浏览 1条回答 0 悬赏 10 金钱
/**
 * This is the model class for table "user".
 *
 * @property integer $id
 * @property string $username
 * @property string $mobile
 * @property string $auth_key
 * @property string $password_hash
 * @property string $password_reset_token
 * @property string $email
 * @property integer $status
 * @property integer $role
 * @property string $created_at
 * @property string $updated_at
 * @property string $sex
 */
class User extends \yii\db\ActiveRecord implements IdentityInterface
{

最佳答案

  • javalzbin 发布于 2016-04-13 18:04 举报

    这是符合phpdoc的注释格式,有很多工具可以解析这类注释并且直接生成文档,例如phpDocumentor, doxygen等等。IDE例如eclipse的PDT,InteliJ的IDEA和PHPStorm也能解析这种注释格式,并且根据注释来辅助生成代码提示
    如果你使用gii生成代码,比如你用gii生成model,它默认就有这个注释

    2 条回复
    回复于 2016-04-13 18:07 回复

    谢谢赐教(抱拳)

    回复于 2017-02-02 15:26 回复

    如何快速注释@这种格式,方法是什么,/**后面呢?

    , , 觉得很赞
    没有找到数据。
您需要登录后才可以回答。登录 | 立即注册
zavier
董事长

zavier

注册时间:2016-04-01
最后登录:2022-09-22
在线时长:5344小时52分
  • 粉丝19
  • 金钱10890
  • 威望30
  • 积分64630

热门问题