public void removeItem(int project_id) { for (Projects projects : listProjects) { if (projects.getProject_id() == project_id) { listProjects.remove(projects); notifyDataSetChanged(); } } }
@Override public void onBindViewHolder(ViewHolder viewHolder, int i) { final Projects projects = listProjects.get(i); viewHolder.projectName.setText(projects.getName()); viewHolder.projectStatus.setText(projects.getStatus()); viewHolder.projectId.setText("" + projects.getProject_id()); viewHolder.projectOfflineId.setText("" + projects.getId()); }