报错:
Attempt to invoke virtual method 'booleanjava.lang.String.equals(java.lang.Object)' on a null object reference
提示错误在:
@Override public RecyclerView.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) { return new XunshiViewHolder(mLayoutInflater.inflate(R.layout.item_ts_xunshi, parent, false), mContext); }
解决
<view android:layout_width="match_parent" android:layout_height="@dimen/default_parting_line" android:background="@color/gray_line"></view>
layout布局xml文件中的view标签名字中将小写view改成View