我正在通过gradle使用doclet运行javadoc,并且当我运行javadoc/doclet任务时,我收到下一个错误:
I am running javadoc with my doclet through gradle, and when I am running my javadoc/doclet task, I am receiving the next error:
error - invalid flag: -doctitle然后是下一个用法表
usage: javadoc [options] [packagenames] [sourcefiles] [@files] -overview <file> Read overview documentation from HTML file -public Show only public classes and members -protected Show protected/public classes and members (default) -package Show package/protected/public classes and members -private Show all classes and members -help Display command line options and exit -doclet <class> Generate output via alternate doclet -docletpath <path> Specify where to find doclet class files -sourcepath <pathlist> Specify where to find source files -classpath <pathlist> Specify where to find user class files -exclude <pkglist> Specify a list of packages to exclude -subpackages <subpkglist> Specify subpackages to recursively load -breakiterator Compute 1st sentence with BreakIterator -bootclasspath <pathlist> Override location of class files loaded by the bootstrap class loader -source <release> Provide source compatibility with specified release -extdirs <dirlist> Override location of installed extensions -verbose Output messages about what Javadoc is doing -locale <name> Locale to be used, e.g. en_US or en_US_WIN -encoding <name> Source file encoding name -quiet Do not display status messages -J<flag> Pass <flag> directly to the runtime system有人对Javadoc为什么不接受该标志有任何想法吗?从理论上讲,我是从jdk1.6的tools.jar运行javadoc的.我认为javadoc总是会接受该doctitle选项.谢谢您的时间!
Does anyone have an idea from why Javadoc is not accepting that flag? In theory, I am running the javadoc from tools.jar from jdk1.6. I thought it was something that javadoc would always accept that doctitle option. Thank you for your time!
编辑:该doctitle选项是Standard Doclet的一部分,因此看来我无法访问Standard Doclet选项.
EDIT: That doctitle option is part of the Standard Doclet, so it looks like I am not being able to access the Standard Doclet options.
推荐答案已
知道了! 问题出在Doclet本身.我没有扩展标准Doclet(公共类MyDoclet扩展了标准{"),因此标准Doclet的标志不可用(文档标题是标准Doclet的标志的一部分).
Got it! The problem was in the Doclet itself. I was not extending the Standard Doclet ("public class MyDoclet extends Standard {"), so the flags from the Standard Doclet were not available (and doctitle is part of the flags of the Standard Doclet).
感谢Paulo让我重新考虑"我的回答:-)
Thanks to Paulo for making me "re-think" my answer :-)
更多推荐
Javadoc无法识别doctitle选项/标志
发布评论