【发布时间】:2016-09-18 23:43:39
【问题描述】:
是否可以在自动完成列表中显示受保护的成员? 例如:
class Foo
{
protected $bar;
public function __get($name) { return $this->$name; }
}
$foo = new Foo();
$foo-> // display autocomplete list with bar
我使用 PhpStorm 10
【问题讨论】:
是否可以在自动完成列表中显示受保护的成员? 例如:
class Foo
{
protected $bar;
public function __get($name) { return $this->$name; }
}
$foo = new Foo();
$foo-> // display autocomplete list with bar
我使用 PhpStorm 10
【问题讨论】:
在类级别的 PHPDoc 注释中使用 @property。
https://github.com/phpDocumentor/fig-standards/blob/master/proposed/phpdoc.md#714-property
/**
* @property ProperTypeHere $bar [Optional description]
*/
class Foo
{
protected $bar;
public function __get($name) { return $this->$name; }
}
【讨论】: