public class CheckBoxListSelectionModel extends DefaultListSelectionModel implements ListDataListener
leadAnchorNotificationEnabled, listenerList
MULTIPLE_INTERVAL_SELECTION, SINGLE_INTERVAL_SELECTION, SINGLE_SELECTION
Constructor and Description |
---|
CheckBoxListSelectionModel() |
CheckBoxListSelectionModel(ListModel model) |
Modifier and Type | Method and Description |
---|---|
void |
addSelectionInterval(int index0,
int index1) |
void |
contentsChanged(ListDataEvent e) |
int |
getAllEntryIndex()
Gets the index of the "all" entry in the CheckBoxList.
|
int |
getMinSelectionIndex() |
ListModel |
getModel() |
void |
insertIndexInterval(int index,
int length,
boolean before)
Overrides so that inserting a row will not be selected automatically if the row after it is selected.
|
void |
intervalAdded(ListDataEvent e) |
void |
intervalRemoved(ListDataEvent e) |
boolean |
isAllEntryConsidered()
Gets the flag indicating if this CheckBoxListSelectionModel should consider the CheckBoxList.ALL item if there is one.
|
boolean |
isSelectedIndex(int index) |
void |
removeSelectionInterval(int index0,
int index1) |
void |
setAllEntryConsidered(boolean allEntryConsidered)
Sets the flag indicating if this CheckBoxListSelectionModel should consider the CheckBoxList.ALL item if there is one.
|
void |
setAllEntryIndex(int allEntryIndex)
Sets the index of the "all" entry in the CheckBoxList.
|
void |
setModel(ListModel model) |
void |
setSelectionInterval(int index0,
int index1) |
addListSelectionListener, clearSelection, clone, fireValueChanged, fireValueChanged, fireValueChanged, getAnchorSelectionIndex, getLeadSelectionIndex, getListeners, getListSelectionListeners, getMaxSelectionIndex, getSelectionMode, getValueIsAdjusting, isLeadAnchorNotificationEnabled, isSelectionEmpty, moveLeadSelectionIndex, removeIndexInterval, removeListSelectionListener, setAnchorSelectionIndex, setLeadAnchorNotificationEnabled, setLeadSelectionIndex, setSelectionMode, setValueIsAdjusting, toString
public CheckBoxListSelectionModel()
public CheckBoxListSelectionModel(ListModel model)
public int getAllEntryIndex()
setAllEntryIndex(int)
public void setAllEntryIndex(int allEntryIndex)
allEntryIndex
- the index of the "all" entry.public ListModel getModel()
public void setModel(ListModel model)
public void intervalAdded(ListDataEvent e)
intervalAdded
in interface ListDataListener
public void intervalRemoved(ListDataEvent e)
intervalRemoved
in interface ListDataListener
public void contentsChanged(ListDataEvent e)
contentsChanged
in interface ListDataListener
public void insertIndexInterval(int index, int length, boolean before)
insertIndexInterval
in interface ListSelectionModel
insertIndexInterval
in class DefaultListSelectionModel
index
- the index where the rows will be inserted.length
- the number of the rows that will be inserted.before
- it's before or after the index.public boolean isAllEntryConsidered()
setAllEntryConsidered(boolean)
public void setAllEntryConsidered(boolean allEntryConsidered)
allEntryConsidered
- the flagpublic boolean isSelectedIndex(int index)
isSelectedIndex
in interface ListSelectionModel
isSelectedIndex
in class DefaultListSelectionModel
public void setSelectionInterval(int index0, int index1)
setSelectionInterval
in interface ListSelectionModel
setSelectionInterval
in class DefaultListSelectionModel
public int getMinSelectionIndex()
getMinSelectionIndex
in interface ListSelectionModel
getMinSelectionIndex
in class DefaultListSelectionModel
public void addSelectionInterval(int index0, int index1)
addSelectionInterval
in interface ListSelectionModel
addSelectionInterval
in class DefaultListSelectionModel
public void removeSelectionInterval(int index0, int index1)
removeSelectionInterval
in interface ListSelectionModel
removeSelectionInterval
in class DefaultListSelectionModel