Eclipse下,javadoc路径无效,产生Note: This element neither has attached source nor attached Javadoc...

错误的完整信息为:

Note: This element neither has attached source nor attached Javadoc and hence no Javadoc could be found.

这是由于javadoc没有正确配置而产生的问题。

解决方法很简单:

以我当前的项目为例,我使用cloudsim的jar包。

(1)搜索“cloudsim api”,找到cloudsim的官方api网站:http://www.cloudbus.org/cloudsim/doc/api/index.html

api网站基本是长这样:

Eclipse下,javadoc路径无效,产生Note: This element neither has attached source nor attached Javadoc..._第1张图片

(2)在eclipse中,File->Properties->Java Build Path->Library

Eclipse下,javadoc路径无效,产生Note: This element neither has attached source nor attached Javadoc..._第2张图片

找到jar包所对应的javadoc location,然后edit,输入:http://www.cloudbus.org/cloudsim/doc/api/,然后点击validate

注意:不是http://www.cloudbus.org/cloudsim/doc/api/index.html,而是http://www.cloudbus.org/cloudsim/doc/api/,否则会eclipse找不到对应的package-list和index.html,会产生下面错误:

Eclipse下,javadoc路径无效,产生Note: This element neither has attached source nor attached Javadoc..._第3张图片

输入正确的地址后,点击validate,会提示:

Eclipse下,javadoc路径无效,产生Note: This element neither has attached source nor attached Javadoc..._第4张图片


(3)验证是否配置成功

Eclipse下,javadoc路径无效,产生Note: This element neither has attached source nor attached Javadoc..._第5张图片


另外,我这是利用online api配置的,也可以用offline api配置,请自行搜索解决方案。

有什么问题可以联系我,邮箱:Sheldon.X.Yigmail.com

你可能感兴趣的:(CloudSim,Eclipse,Java,javadoc,Eclipse)