private void deselect(int position,Iterator<Integer> entries){
  Item item=getItem(position);
  if (item != null) {
    item.withSetSelected(false);
  }
  if (entries == null) {
    if (mPositionBasedStateManagement) {
      if (mSelections.contains(position)) {
        mSelections.remove(position);
      }
    }
  }
 else {
    entries.remove();
  }
  notifyItemChanged(position);
  if (mSelectionListener != null)   mSelectionListener.onSelectionChanged(item,false);
}

private void deselect ( int position , Iterator < Integer > entries ) { Item item = getItem ( position ) ; if ( item != null ) { item . withSetSelected ( false ) ; } if ( entries == null ) { if ( mPositionBasedStateManagement ) { if ( mSelections . contains ( position ) ) { mSelections . remove ( position ) ; } } } else { entries . remove ( ) ; } notifyItemChanged ( position ) ; if ( mSelectionListener != null ) mSelectionListener . onSelectionChanged ( item , false ) ; }
deselects an item and removes it ' s position in the selections list also takes an iterator to remove items from the map
