JavaDoc的不工作在Android项目 [英] JavaDoc not working in Android project

查看:133
本文介绍了JavaDoc的不工作在Android项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用的Eclipse 3.5.2在Ubuntu 10.04 Android开发。我安装了:

I'm using Eclipse 3.5.2 for Android development on Ubuntu 10.04. I installed:

  • 在Sun的JDK从Ubuntu的仓库;
  • 从eclipse.org的Eclipse 3.5.2(经典),解压到的/ opt /月食
  • Android的SDK从android.com,解压到的/ opt / Android的SDK
  • Sun's JDK from Ubuntu's repositories;
  • Eclipse 3.5.2 (Classic) from eclipse.org, unpacked to /opt/eclipse
  • The Android SDK from android.com, unpacked to /opt/android-sdk

我的问题是,当我在一个Android项目,Javadoc将无法正常工作(既不是为Android班也没有为Java类)。举例来说,如果我在日期格式悬停我的鼠标,我得到:

My problem is that when I'm in an Android project, JavaDoc will not work (neither for Android classes nor for Java classes). For example, if I hover my mouse over DateFormat, I get:

java.text.DateFormat中

注:的Javadoc这个元素既不能连接的源,也没有附加的Javadoc中找到

不过,如果我在日期格式悬停我的鼠标,而我在编辑一个正常的,Java项目,我得到了正确的JavaDoc:

However, if I hover my mouse over DateFormat while I'm editing a normal, Java project, I do get the correct JavaDoc:

java.text.DateFormat中

日期格式是一个抽象类,日期/时间格式化子其格式和解析日期或时间的语言无关的方式。 ......

DateFormat is an abstract class for date/time formatting subclasses which formats and parses dates or time in a language-independent manner. ...

所以JavaDoc中的,它只是没有从里面的Andr​​oid项目的访问,一些奇怪的原因。

So the JavaDoc is there, it's just not accessible from inside Android projects, for some strange reason.

任何想法是什么原因可能是?

Any ideas what that reason might be?

推荐答案

刚刚解决了这个我自己,这是我做的事(在Eclipse):

Just resolved this myself, here's what I did (from inside Eclipse):

  • 转到菜单​​窗口 - >Android SDK和AVD管理器
  • 单击,在出现的
  • 窗口可用的软件包
  • 选中文档......包。请注意,我只有一个文件包可供选择,这是为SDK比我用的是较新版本,但它是不够好。
  • 点击安装选定。
  • Go to menu "Window" -> "Android SDK and AVD manager"
  • Click "Available Packages" in the window that appears
  • Check the "Documentation ..." package. Note that I had only one documentation package to choose from, and it was for a newer version of the SDK than what I was using, but it was good enough.
  • Click "Install Selected".

现在,只需等待安装完成,你应该有悬停的Javadoc对于大多数API调用。

Now, just wait for the install to finish and you should have Javadoc hovers for most API calls.

祺/ J

这篇关于JavaDoc的不工作在Android项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆