T - list element typepublic class DefaultCheckListModel<T> extends AbstractListModel implements CheckListModel<T>
| Modifier and Type | Field and Description |
|---|---|
protected Set<T> |
checks |
protected List<T> |
data |
listenerList| Constructor and Description |
|---|
DefaultCheckListModel(Collection<? extends T> data) |
DefaultCheckListModel(T... data) |
| Modifier and Type | Method and Description |
|---|---|
protected List<T> |
data() |
Collection<T> |
getCheckedItems()
Returns a collections of checked items
|
Object |
getElementAt(int index) |
int |
getOriginalSize()
Returns the number of items before the filter was applied
|
int |
getSize() |
boolean |
isCheckedIndex(int index)
Returns the check state of the element at specified position
|
void |
setCheckedIndex(int index,
boolean value)
Sets the check state of the element at specified position
|
void |
setCheckedItems(Collection<T> items)
Sets checked items
|
addListDataListener, fireContentsChanged, fireIntervalAdded, fireIntervalRemoved, getListDataListeners, getListeners, removeListDataListenerclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddListDataListener, removeListDataListenerpublic DefaultCheckListModel(Collection<? extends T> data)
public DefaultCheckListModel(T... data)
public int getOriginalSize()
CheckListModelgetOriginalSize in interface CheckListModel<T>public Object getElementAt(int index)
getElementAt in interface ListModelpublic boolean isCheckedIndex(int index)
CheckListModelisCheckedIndex in interface CheckListModel<T>index - element indexpublic void setCheckedIndex(int index,
boolean value)
CheckListModelsetCheckedIndex in interface CheckListModel<T>index - element indexpublic Collection<T> getCheckedItems()
CheckListModelgetCheckedItems in interface CheckListModel<T>public void setCheckedItems(Collection<T> items)
CheckListModelsetCheckedItems in interface CheckListModel<T>Copyright © 2004–2017 Ultreia.io. All rights reserved.