出这个异常的原因是在项目中添加了新lication类(public class Application extends lication)之后,没有在AndroidManifest.xml中添加该类的声明,所以编译器抛出异常: java.lang.ClassCastException: android.app.Application cannot be cast to 类名
<application android:icon="@drawable/icon" android:label="@string/app_name"
android:name=".你所新建的lication类名">
相关文章
- 新建Application 报错android.app.Application cannot be cast
- java.lang.ClassCastException: android.app.Application cannot be cast to
- 42-字符串到json 的错误 com.alibaba.fastjson.JSONObject cannot be cast to java.lang.String
- json学习系列(5)-json错误解析net.sf.ezmorph.bean.MorphDynaBean cannot be cast to
- spark中处理dataframe往往遇到”...cannot be cast to ...”这种数据不匹配的问题
- Spring boot 2.0 版本报错 ResourceHttpRequestHandler cannot be cast to HandlerMethod
- Weblogic报错:com.octetstring.vde.backend.BackendRoot cannot be cast to com.octetstring.vde.backend
- GraphQL: com.alibaba.fastjson.JSONObject cannot be cast to java.lang.String
- 大数据篇 --错题集 java.lang.ClassCastException: cannot be cast to org.apache.hadoop.io.ByteWritable
- hive orc压缩数据异常java.lang.ClassCastException: org.apache.hadoop.io.Text cannot be cast to org.apache.h...