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.
我听说 Eclipse 不支持这样的变量参数化:
/** @var DBProxy */ $proxy;
/**
@var DBProxy
*/
$proxy;
或者
/** @var Uri */ $uri = Registry::get('uri'); $uri->...
@var Uri
$uri = Registry::get('uri');
$uri->...
但没有可用的完成
还有其他解决方案吗?
那这个呢 :
/* @var $uri Uri */ $uri = Registry::get('uri');
基本上,使用:
/* @var $variableName VariableType */
应该管用。