Analysis @ Deprecated: The style is crossed out when the method is called, and @ deprecated is crossed out.

Source: Internet
Author: User

Analysis @ Deprecated: The style is crossed out when the method is called, and @ deprecated is crossed out.

Deprecated

This annotation is a tag annotation. The so-called Mark annotation means that adding this mark to the source program does not affect program compilation, but sometimes the compiler displays some warning information.

So what does Deprecated comment mean? If you frequently use eclipse or other IDE To Write java programs, you may often see this word in the attribute or method prompt. If a word appears in the prompt of a class member, it indicates that this class member is not recommended. This class member may be deleted in future JDK versions. The reason for retention is that a buffer period is provided for programs that have used these class members. If so, these programs cannot be compiled in the new compiler.

Speaking of this, you may have guessed it. The Deprecated annotation must be related to these class members. That's right! After you use Deprecated to label a class member, the class member changes in display. It is very obvious in eclipse.

Annotations for this method:

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.