public void remove(@NonNull T item){
  int removeIndex;
synchronized (lock) {
    if (items == null) {
      return;
    }
    removeIndex=items.indexOf(item);
    if (removeIndex != -1) {
      items.remove(removeIndex);
    }
  }
  if (notifyOnChange && removeIndex != -1) {
    notifyItemRemoved(removeIndex);
  }
}

public void remove ( @ NonNull T item ) { int removeIndex ; synchronized ( lock ) { if ( items == null ) { return ; } removeIndex = items . indexOf ( item ) ; if ( removeIndex != - 1 ) { items . remove ( removeIndex ) ; } } if ( notifyOnChange && removeIndex != - 1 ) { notifyItemRemoved ( removeIndex ) ; } }
removes the specified item from the list
