摘要:
在一个数据持久化处理中定义了数据保存和读取的 泛型函数的,但是在运行时出现类型转换错误,类型不匹配,出错的位置不是load方法,而是在调用load方法之后,得到了列表数据,对列表数据进行使用时出现的。结果列表里面的元素实际是A类型,调用load方法传递的是B类型的class,但是仍然load成功。 阅读全文
posted @ 2017-05-26 12:19
虫子CCC
阅读(4484)
评论(0)
推荐(0)
摘要:
1)View的状态保存与恢复dispatchRestoreInstanceStateonRestoreInstanceStateonSaveInstanceState2)Service的前台服务使用startForeground(NOTIFICATION_ID, mNotification)stop 阅读全文
posted @ 2017-05-26 11:47
虫子CCC
阅读(228)
评论(0)
推荐(0)
摘要:
StackOverflow上摘抄的: some things have changed since I asked this question so I will answer it myself.With Support Library 23.4.0 the support for VectorD 阅读全文
posted @ 2017-05-26 11:44
虫子CCC
阅读(4196)
评论(0)
推荐(0)
摘要:
统一设置为UTF8编码在工程的根目录下的build.gradle文件中,添加定义。tasks. withType(JavaCompile) { options.encoding = "UTF-8"} 如图: 阅读全文
posted @ 2017-05-26 11:35
虫子CCC
阅读(373)
评论(0)
推荐(0)
摘要:
1)API接口 android.content.ContentProvider android.content.ContentResolver android.provider.CalendarContract 另外,在创建日历账号时(向系统的Calendars表插入一条数据)需要设置为适配器模式, 阅读全文
posted @ 2017-05-26 11:23
虫子CCC
阅读(1324)
评论(0)
推荐(0)
摘要:
如果不小心手动修改了.gradle文件夹中的内容,那么再打开之前编译成功的工程时,会出现类似下面的错误: Gradle app neame project refresh failed: Unexpected lock protocol found in lock file. Expected 3, 阅读全文
posted @ 2017-05-26 10:42
虫子CCC
阅读(9414)
评论(1)
推荐(1)