Is there any way to access Javadoc information via reflection, the way annotations can be retained at runtime?
If not, how does Eclipse access the javadoc for .jar files?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Comments used for Javadoc are never retained in compiled classes (see http://java.sun.com/docs/books/jvms/second_edition/ClassFileFormat-Java5.pdf for instance). Eclipse is able to associate Javadoc to the referenced jar files either by extracting it from the jar (if present), by direct association with the jar file (set by yourself or a plugin like m2eclipse), or by finding it inside the JRE javadoc (set directly in “Installed JREs”).