PHPDoc"未找到此文件的摘要"错误

时间:2016-08-01 15:03:39

标签: php documentation phpdoc

我正在尝试为我编写的代码生成PHPDocs,但我不断收到错误告诉我"没有找到此文件的摘要"。我尝试使用具有类似主题的this页面,但它对此特定问题没有帮助。

据我所知,下面的示例格式正确,但它仍然会给我错误。

<?php
namespace App\Example;

/**
 * This is the summary section for the file itself.
 *
 * This Goes into more depth about the whole file.
 *`enter code here`
 * @author Some Author
 *
 */

/**
 * Some standard first function (function_1). This is a long description of the file just so that it
 * looks good in the example doc page. Don't worry about what all of this says, it is meaningless. This
 * is all part of the first paragraph, and is the main summary. the next part is the more detailed stuff
 * people can read if they want.
 *
 * Lorem ipsum dolor sit amet, at falli maluisset nec, paulo deterruisset no vix. Prompta ancillae
 * cu mea, insolens recteque te pri, vulputate disputando persequeris id quo. Ei iracundia
 * efficiendi eos. Eam ut illum euismod erroribus, praesent assueverit at vix. Wisi nostrum ad vel,
 * pro an eros repudiare, ei mea fierent appareat deseruisse.
 *
 * @param ParameterType1 $param1 Param1 description.
 * @param string $param2 Param2 description.
 * @param string $param3 Param3 description.
 * @param $param4 - Param4 description.
 *
 * @return void
 */

function function_1(ParameterType1 $param1, $param2, $param3, &$param4)
{
    //This is the code.
}


/**
 * Some standard second function (function_2) This is a long description of the file just so that it
 * looks good in the example doc page. Don't worry about what all of this says, it is meaningless. This
 * is all part of the first paragraph, and is the main summary. the next part is the more detailed stuff
 * people can read if they want.
 *
 * Lorem ipsum dolor sit amet, at falli maluisset nec, paulo deterruisset no vix. Prompta ancillae
 * cu mea, insolens recteque te pri, vulputate disputando persequeris id quo. Ei iracundia
 * efficiendi eos. Eam ut illum euismod erroribus, praesent assueverit at vix. Wisi nostrum ad vel,
 * pro an eros repudiare, ei mea fierent appareat deseruisse.
 *
 * @param ParamType2 $param1 Param1 description.
 * @param $param2 - Param2 description.
 *
 * @return string $returnStatement
 */

function function_2(ParamType2 $param1, &$param2) {
    //This is the code.
    return $returnStatement;
}

?>

我确信这是对代码进行正确生成DOC的简单修复,但是试图找出导致错误的原因一直很令人沮丧。

0 个答案:

没有答案