Get rid of the unpleasant "yellow warning" in Android engineering

Source: Internet
Author: User

One: The problem

  Two: Solution
    • (1) Select Android Project, right-click android tools-> Clear Lint Markers

      This way can erase all the warning messages in Android, but unfortunately, the next time you open eclipse will continue to prompt, very uncomfortable!

      (2) Ignore the specified warning with @suppresslint callout

      To use this callout, you need to introduce Annotations.jar, which will be available when the new project is created by default. Use as follows:

      in the class, method, variable and so on preceded by labeling @SuppressLint ("Newapi"), this newapi is generally a specific class, do not remember, the message will be automatically added. Plus annotations can resolve no longer warnings, but the code seems to become redundant. In short, there is no Qimei method, my practice is to let him continue to warn, the program can run normally just fine!

Three: RELATED LINKS

Http://www.it165.net/pro/html/201307/6563.html

  

Get rid of the unpleasant "yellow warning" in Android engineering

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.