在程序中导入jar包后,每次更新程序都会出现好几行
:warning: Ignoring InnerClasses attribute for an anonymous inner class that doesn't come with an associated EnclosingMethod attribute. (This class was probably produced by a broken compiler.)
这是在直接在jar包上右键单击选择build path 生成的;本来还以为是哪个内部类没关闭,后来在网上搜到了答案:
右键工程
Build path,
java build path,选择libraries
在右边的按钮中点击“Add Library”
选择“User library”,点击“下一步”
点击“User librarys”按钮
在出现的界面中点击“New..”按钮
在弹出的界面中随便起一个名字,点击“确定”
点击“Add jars”按钮选择第三方jar包,点击“确定”完成操作。
这样的话该jar包会被一起打包到apk中,问题也就解决了!
本文介绍了解决在导入jar包后出现特定警告的方法。通过将jar包添加到项目的用户库中,可以有效避免警告并顺利完成程序打包。
466

被折叠的 条评论
为什么被折叠?



