[英]Only first constructor showing up in javadoc (run from eclipse)?
Why is only the first constructor showing up in the javadoc? 为什么只有第一个构造函数出现在javadoc中?
Code excerpt: 代码摘录:
/**
* Returns a <code>Config</code> object resulting from parsing a
* configuration file.
*
* @param p a <code>Path</code> object representing the configuration file.
*/
public Config(Path p) {
...code elided here...
}
/**
* Returns a <code>Config</code> object resulting from parsing a
* configuration file.
*
* @param filename a <code>String</code> naming the configuration file.
*/
public Config(String filename) {
this(Paths.get(filename));
}
Javadoc excerpt: Javadoc摘录:
(similarly only the one shows up in the "Constructor Detail" as well) (同样只有一个显示在“构造函数详细信息”中)
Details for posterity: OS X 10.8.5, Eclipse EE Juno SR2, Java 1.7.0_72( but see accepted answer ) 后代的详细信息:OS X 10.8.5,Eclipse EE Juno SR2,Java 1.7.0_72( 但请参阅接受的答案 )
I could reproduce the issue with 1.6.0_21 , using javadoc
command-line tool directly. 我可以直接使用javadoc
命令行工具重现1.6.0_21的问题。 It, understandably, complains that package java.nio.file does not exist
buts still manages to create the files (with only one of your constructors). 可以理解的是,抱怨package java.nio.file does not exist
但仍设法创建文件(只有一个构造函数)。
It looks like you're using a 1.6 (or older) javadoc
tool to generate docs for 1.7+ sources (this would also explain why your screenshot looks kinda ... 'old') 看起来你正在使用一个1.6(或更旧版本)的javadoc
工具为1.7+源生成文档(这也可以解释为什么你的截图看起来有点......'老')
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.