Eclipse Add package annotation file Package-info.java

Source: Internet
Author: User


adding comments to the package gives us a clear idea of how the package works, and that it's more clear what the core issues are in the package, so it's important to add a package annotation.


when you add a Java file in Eclipse, you are not allowed to add a Java file with name Package-info. But we can create an ordinary file file with the wizard, and then name the file name Package-info.java.

==================================

http://esyscn.com/thread-62884-1-1.html

===============================
set up Eclipse code templates

Eclipse Menu: Window->preferences, expand Java->editor->templates, create a new Javadoc type template: Name set to: Package Context selection: Javadoc pattern Input:

XXX realizes <a href= "#" target= "_blank" >a name</a>.  * <p>  * 
use in development

Under the package you want to create the package Note: Package-info.java file:

/**  * * * * * *  package org.skzr.logging;
In the second line of input: "Packa" press atl+/to pull up the previous set of templates, and then enter their interests, the final effect is as follows:
/**  * slf4j localization log extension implementation <a href= "http://code.google.com/p/slf4j-local" target= "_blank" >

Related Article

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.