Export Javadoc from MyEclipse to make your own API file __java

Source: Internet
Author: User

When the project is completed, in order to facilitate maintenance later, know the functions of each interface or class, want to export the entire project annotation, make API file.

First, note:

Annotate all required classes and methods and attributes.

General Specification:

(1) Annotation of class:

/**

*xxx

* @author XXX

* @version XXX

**/

(2) Comments on the method:

/*

*xxxxx

*/

(3) The annotation of the attribute:

Xxxxx


Second, the use of MyEclipse features derived from the

1, right click to select item

2, select Export

3, select Javadoc under Java

4,configure: Typically, you can find Javadoc.exe in the JDK's Bin directory, select the items you want to export, and select the exported path




5, click Next, and then configure the jar package that you want to introduce, by default it is not selected, and then next

6, and then enter the following interface, in this interface can configure some of their own tag and export the encoding

@author, @version These tags are all Java-brought labels, you can also define their own tags, syntax:-tag <name>:<locations>:

Where the name attribute is your custom tag, the locations official has the following options:

Placement of Tags-the XAOPTCMF part of the argument determines where in the source code the "tag is" allowed to be placed, and whether the tag can be disabled (using X). Can supply either a, to allow the tag in all places, or any combination of the other letters:
X (Disable tag) a (All) O (Overview) p (packages) t (types, which is classes and interfaces) C (constructors) m (methods) F (Fields)

Example:-tag date:a: "Date", after defining this, the @date tag Javadoc.exe in the Java class is able to parse the tag and will not throw an error when exporting.


Also, if you use UTF-8 encoding in your project, be sure to set the encoding when you export Javadoc because the default is to use the GBK encoding format. If not set, there will be garbled, and then export failed.

-encoding UTF-8-charset UTF-8




7, then finish it.






Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.