答案 0 :(得分:0)
要为列表项创建一行分隔符,您可以使用此
RecyclerView recyclerView = (RecyclerView) findViewById(R.id.recycler);
DividerItemDecoration dividerItemDecoration = new DividerItemDecoration(getContext(), DividerItemDecoration.VERTICAL);
recyclerView.addItemDecoration(dividerItemDecoration);