@SuppressLint("InlinedApi")的用途是什么 [英] what is the use of @SuppressLint("InlinedApi")

查看:131
本文介绍了@SuppressLint("InlinedApi")的用途是什么的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在经历的某些代码中遇到了 @SuppressLint("InlinedApi"),无法在线找到对其的任何描述.我了解 @SuppressLint("NewApi")在我们编写的代码高于清单中提到的minsdk时用于隐藏警告.但是我不知道什么时候应该使用"InlinedApi".有什么想法吗?

I encountered @SuppressLint("InlinedApi") in some code i was going through and could not find out any description of it online. I understand @SuppressLint("NewApi") is used to hide warnings when we write code that is higher than the minsdk mentioned in the manifest. But i am not able to figure out when "InlinedApi" should be used. Any ideas?

推荐答案

通过执行 lint --list (皮棉工具位于您的 sdk/tools 目录中)您可以看到有效问题ID的列表.您可以在此处找到 InlinedApi 的说明:

By executing lint --list (the lint tool is located in your sdk/tools directory) you can see a list of the valid issue id's. You can find the explanation of InlinedApi there :

"InlinedApi":查找在较旧版本上可能有效或无效的内联字段平台

"InlinedApi": Finds inlined fields that may or may not work on older platforms

这篇关于@SuppressLint("InlinedApi")的用途是什么的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆