recycleview异常报错

rcycleview异常报错

05-07 14:29:49.924: E/MessageQueue-JNI(16160): java.lang.NullPointerException
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.support.v7.widget.RecyclerView.computeVerticalScrollOffset(RecyclerView.java:1613)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.View.canScrollVertically(View.java:11380)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.support.v4.view.ViewCompatICS.canScrollVertically(ViewCompatICS.java:35)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.support.v4.view.ViewCompat$ICSViewCompatImpl.canScrollVertically(ViewCompat.java:1253)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.support.v4.view.ViewCompat.canScrollVertically(ViewCompat.java:1695)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.support.v4.widget.SwipeRefreshLayout.canChildScrollUp(SwipeRefreshLayout.java:646)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.support.v4.widget.SwipeRefreshLayout.onInterceptTouchEvent(SwipeRefreshLayout.java:660)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1827)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2241)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1904)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2241)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1904)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2241)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1904)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2241)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1904)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2241)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1904)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2241)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1904)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at com.android.internal.policy.impl.PhoneWindow$DecorView.superDispatchTouchEvent(PhoneWindow.java:1968)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at com.android.internal.policy.impl.PhoneWindow.superDispatchTouchEvent(PhoneWindow.java:1420)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.app.Activity.dispatchTouchEvent(Activity.java:2428)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.support.v7.view.WindowCallbackWrapper.dispatchTouchEvent(WindowCallbackWrapper.java:60)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.support.v7.view.WindowCallbackWrapper.dispatchTouchEvent(WindowCallbackWrapper.java:60)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at com.android.internal.policy.impl.PhoneWindow$DecorView.dispatchTouchEvent(PhoneWindow.java:1916)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.View.dispatchPointerEvent(View.java:7437)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewRootImpl.deliverPointerEvent(ViewRootImpl.java:3610)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewRootImpl.deliverInputEvent(ViewRootImpl.java:3538)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewRootImpl.doProcessInputEvents(ViewRootImpl.java:4790)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewRootImpl.enqueueInputEvent(ViewRootImpl.java:4750)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.ViewRootImpl$WindowInputEventReceiver.onInputEvent(ViewRootImpl.java:4902)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.view.InputEventReceiver.dispatchInputEvent(InputEventReceiver.java:179)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.os.MessageQueue.nativePollOnce(Native Method)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.os.MessageQueue.next(MessageQueue.java:125)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.os.Looper.loop(Looper.java:140)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at android.app.ActivityThread.main(ActivityThread.java:5297)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at java.lang.reflect.Method.invokeNative(Native Method)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at java.lang.reflect.Method.invoke(Method.java:511)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:833)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:600)
05-07 14:29:49.924: E/MessageQueue-JNI(16160):  at dalvik.system.NativeStart.main(Native Method)
05-07 14:29:49.930: E/AndroidRuntime(16160): FATAL EXCEPTION: main
05-07 14:29:49.930: E/AndroidRuntime(16160): java.lang.NullPointerException
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.support.v7.widget.RecyclerView.computeVerticalScrollOffset(RecyclerView.java:1613)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.View.canScrollVertically(View.java:11380)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.support.v4.view.ViewCompatICS.canScrollVertically(ViewCompatICS.java:35)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.support.v4.view.ViewCompat$ICSViewCompatImpl.canScrollVertically(ViewCompat.java:1253)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.support.v4.view.ViewCompat.canScrollVertically(ViewCompat.java:1695)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.support.v4.widget.SwipeRefreshLayout.canChildScrollUp(SwipeRefreshLayout.java:646)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.support.v4.widget.SwipeRefreshLayout.onInterceptTouchEvent(SwipeRefreshLayout.java:660)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1827)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2241)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1904)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2241)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1904)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2241)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1904)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2241)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1904)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2241)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1904)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2241)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:1904)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at com.android.internal.policy.impl.PhoneWindow$DecorView.superDispatchTouchEvent(PhoneWindow.java:1968)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at com.android.internal.policy.impl.PhoneWindow.superDispatchTouchEvent(PhoneWindow.java:1420)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.app.Activity.dispatchTouchEvent(Activity.java:2428)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.support.v7.view.WindowCallbackWrapper.dispatchTouchEvent(WindowCallbackWrapper.java:60)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.support.v7.view.WindowCallbackWrapper.dispatchTouchEvent(WindowCallbackWrapper.java:60)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at com.android.internal.policy.impl.PhoneWindow$DecorView.dispatchTouchEvent(PhoneWindow.java:1916)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.View.dispatchPointerEvent(View.java:7437)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewRootImpl.deliverPointerEvent(ViewRootImpl.java:3610)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewRootImpl.deliverInputEvent(ViewRootImpl.java:3538)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewRootImpl.doProcessInputEvents(ViewRootImpl.java:4790)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewRootImpl.enqueueInputEvent(ViewRootImpl.java:4750)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.ViewRootImpl$WindowInputEventReceiver.onInputEvent(ViewRootImpl.java:4902)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.view.InputEventReceiver.dispatchInputEvent(InputEventReceiver.java:179)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.os.MessageQueue.nativePollOnce(Native Method)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.os.MessageQueue.next(MessageQueue.java:125)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.os.Looper.loop(Looper.java:140)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at android.app.ActivityThread.main(ActivityThread.java:5297)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at java.lang.reflect.Method.invokeNative(Native Method)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at java.lang.reflect.Method.invoke(Method.java:511)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:833)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:600)
05-07 14:29:49.930: E/AndroidRuntime(16160):    at dalvik.system.NativeStart.main(Native Method)
05-07 14:29:50.048: E/AppErrorDialog(2309): Failed to get ILowStorageHandle instance
05-07 14:29:50.305: E/AEE/DUMPSTATE(16293): copy_process: execv /system/xbin/showmap failed(2), No such file or directory
05-07 14:29:50.867: E/AEE/DUMPSTATE(16291): copy_file: Copy /proc/gpulog to SYS_GPU_INFO failed(2), No such file or directory
05-07 14:29:52.425: E/AEE/DUMPSTATE(16303): copy_process: execv /system/xbin/procrank failed(2), No such file or directory
05-07 14:29:53.023: E/AEE/DUMPSTATE(16291): copy_file: Copy /proc/slabinfo to SYS_SLAB_INFO failed(2), No such file or directory
05-07 14:29:53.113: E/AEE/DUMPSTATE(16291): copy_file: Copy /sys/kernel/debug/wakeup_sources to SYS_KERNEL_WAKELOCKS failed(2), No such file or directory

解决办法是

一切处理逻辑一定要放在

recyclerView.setLayoutManager(new LinearLayoutManager(this));

后面

时间: 2024-10-07 22:16:40

recycleview异常报错的相关文章

Python基础中所出现的异常报错总结

今天我们来探索python中大部分的异常报错 首先异常是什么,异常白话解释就是不正常,程序里面一般是指程序员输入的格式不规范,或者需求的参数类型不对应,不全等等. 打个比方很多公司年终送苹果笔记本,你程序话思维以为是(MAC)电脑笔记本,结果给你个苹果+笔记本...首先类型不对,数量也不对. 先来看几个常见的报错如下: NameError 命名错误 原因是: name 'a' is not defined  命名a还未定义 简单来说就是程序不知道a带表谁 如果a=1 那程序就懂了 a代表1 所以

【Hadoop】9、hadoop1.2.1完全分布式安装过程异常报错

异常报错 1.ssh配置出错,ssh登录 The authenticity of host 192.168.0.xxx can't be established. 用ssh登录一个机器(换过ip地址),提示输入yes后,屏幕不断出现y,只有按ctrl + c结束 错误是:The authenticity of host 192.168.0.xxx can't be established. 以前和同事碰到过这个问题,解决了,没有记录,这次又碰到了不知道怎么处理,还好有QQ聊天记录,查找到一下,找

python_异常报错

一.报错类型 AttributeError 试图访问一个对象没有的树形,比如foo.x,但是foo没有属性x IOError 输入/输出异常:基本上是无法打开文件 ImportError 无法引入模块或包:基本上是路径问题或名称错误 IndentationError 语法错误(的子类) :代码没有正确对齐 IndexError 下标索引超出序列边界,比如当x只有三个元素,却试图访问x[5] KeyError 试图访问字典里不存在的键 KeyboardInterrupt Ctrl+C被按下 Nam

【Objective-C编程】 Must explicitly describe intended ownership of an object array parameter异常报错解决方案

在做Oc的一个OOP的画多种图形例子的时候.Xcode无端报Must explicitly describe intended ownership of an object array parameter"异常信息,检查了几遍代码还是编译器报错,找了很久才知道原因,现在将这个错误分享出来给大家. 报错的关键代码: 错误的翻译:必须显式地描述目标对象的所有权.个人理解大概就是分配 空间的问题.不符合内存管理的规则 处理办法:处理办法就是将设置项目 Automatic Reference Count

优化异常报错

异常和错误 1.错误分类: 错误基本分为两种:1.语法错误 2.逻辑错误 2.什么是异常 在python中运行发生错误的信号时 3.python中的异常种类 触发IndexError 触发KeyError 触发ValueError AttributeError 试图访问一个对象没有的树形,比如foo.x,但是foo没有属性x IOError 输入/输出异常:基本上是无法打开文件 ImportError 无法引入模块或包:基本上是路径问题或名称错误 IndentationError 语法错误(的子

CentOS7安装Docker时的异常报错与解决方法

确认环境 [[email protected] ~]# cat /etc/redhat-release CentOS Linux release 7.0.1406 (Core) docker安装 -> 报错 [[email protected] ~]# yum install docker Loaded plugins: fastestmirror, langpacks Repodata is over 2 weeks old. Install yum-cron? Or run: yum mak

开启/关闭浮点数异常报错

ZC: Delphi7 中的报错信息为(主要信息):"Invalid floating point operation" 1.http://bbs.csdn.net/topics/391070674 (LongWord($133f)这句是什么意思-CSDN论坛.html) 2楼: 这个应该用_control87或者_controlfp#include <float.h>_control87(0x133f, 0xffff);至于LongWord($133f)这是没有什么意义的

【转】java异常报错大全

算术异常类:ArithmeticExecption 空指针异常类:NullPointerException 类型强制转换异常:ClassCastException 数组负下标异常:NegativeArrayException 数组下标越界异常:ArrayIndexOutOfBoundsException 违背安全原则异常:SecturityException 文件已结束异常:EOFException 文件未找到异常:FileNotFoundException 字符串转换为数字异常:NumberF

最常见的Python异常报错Error

内置异常 官网链接:https://docs.python.org/zh-cn/3/library/exceptions.html 在 Python 中,所有异常必须为一个派生自 BaseException 的类的实例. 在带有提及一个特定类的 except 子句的 try 语句中,该子句也会处理任何派生自该类的异常类(但不处理 它 所派生出的异常类). 通过子类化创建的两个不相关异常类永远是不等效的,既使它们具有相同的名称. 下面列出的内置异常可通过解释器或内置函数来生成.除非另有说明,它们都