list.clear(); int listSize = getSize(); fireIntervalAdded(this, 0, listSize);
selectedItem = null; int size = getSize(); if (size > 0) { list.clear(); fireIntervalRemoved(this, 0, size - 1); }
  public void removeAllElements()  {    list.clear();    int listSize = getSize();    fireIntervalAdded(this, 0, listSize);  }