Php Aptana 3 ScriptDoc-@返回不在代码辅助中工作
我发现这个问题已经得到了回答,但并没有解决我的问题: 使用与他们的示例相当的PHPPhp Aptana 3 ScriptDoc-@返回不在代码辅助中工作,php,aptana,Php,Aptana,我发现这个问题已经得到了回答,但并没有解决我的问题: 使用与他们的示例相当的PHP /** * Gets the current foo * @param {String} $fooId The unique identifier for the foo. * @return {Object} Returns the current foo. */ public function getFoo($fooId) { return $bar[$fooId]; } 但是,提供的文
/**
* Gets the current foo
* @param {String} $fooId The unique identifier for the foo.
* @return {Object} Returns the current foo.
*/
public function getFoo($fooId) {
return $bar[$fooId];
}
但是,提供的文档如下所示(包括额外的尾端大括号):
请让我知道我做错了什么
谢谢 @return类型不应该用花括号括起来 您的文档应如下所示:
/**
* Gets the current foo
* @param String $fooId The unique identifier for the foo.
* @return Object Returns the current foo.
*/
public function getFoo($fooId) {
return $bar[$fooId];
}
返回类型的解析遵循
这也意味着您可以使用混合返回类型,这将为您提供来自多个类型的代码辅助建议
例如:
/**
* @return MyClass|PDO doc doc doc
*/
干杯
/**
* @return MyClass|PDO doc doc doc
*/