|
![]() |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.swing.table.AbstractTableModel
org.openpermis.editor.policy.gui.checklist.CheckListModel<T>
T
- type of the items in the check list model.public class CheckListModel<T>
Creates a model that manages a pool of items and a selection list from the pool.
Nested Class Summary | |
---|---|
(package private) static class |
CheckListModel.ColumnType
Describes the type of a column, including getters and setters. |
private class |
CheckListModel.PoolListener
Synchronizes the check list model if a change in the pool list occurs. |
private class |
CheckListModel.SelectionListener
Synchronizes the check list model if a change in the selection list occurs. |
Field Summary | |
---|---|
private org.jdesktop.observablecollections.ObservableList<T> |
pool
The pool of available items that can be chosen. |
private CheckListModel.PoolListener |
poolListener
Listener that synchronizes the state of the table model and the pool list. |
private org.jdesktop.observablecollections.ObservableList<T> |
selection
The currently selected items from the pool. |
private CheckListModel.SelectionListener |
selectionListener
Listener that refreshes the check list whenever a change occurs. |
private static long |
serialVersionUID
|
Fields inherited from class javax.swing.table.AbstractTableModel |
---|
listenerList |
Constructor Summary | |
---|---|
CheckListModel(org.jdesktop.observablecollections.ObservableList<T> pool,
org.jdesktop.observablecollections.ObservableList<T> selection)
Creates a new check list model. |
Method Summary | |
---|---|
void |
configureListeners()
Adds listeners to synchronize the list with the table model. |
Class<?> |
getColumnClass(int columnIndex)
|
int |
getColumnCount()
|
String |
getColumnName(int columnIndex)
|
private CheckListModel.ColumnType |
getColumnType(int columnIndex)
Returns the type of the column at the specified index. |
int |
getRowCount()
|
Object |
getValueAt(int rowIndex,
int columnIndex)
|
boolean |
isCellEditable(int rowIndex,
int columnIndex)
|
void |
setValueAt(Object value,
int rowIndex,
int columnIndex)
|
void |
unconfigureListeners()
Removes the listeners to synchronize the list with the table model added in configureListeners() . |
Methods inherited from class javax.swing.table.AbstractTableModel |
---|
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, removeTableModelListener |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final long serialVersionUID
4791486544723792077L
private final org.jdesktop.observablecollections.ObservableList<T> pool
private final CheckListModel.PoolListener poolListener
private final org.jdesktop.observablecollections.ObservableList<T> selection
private final CheckListModel.SelectionListener selectionListener
Constructor Detail |
---|
public CheckListModel(org.jdesktop.observablecollections.ObservableList<T> pool, org.jdesktop.observablecollections.ObservableList<T> selection)
pool
- the poolof available items that can be chosen.selection
- the currently selected items from the pool.Method Detail |
---|
public void configureListeners()
public void unconfigureListeners()
configureListeners()
.
private CheckListModel.ColumnType getColumnType(int columnIndex)
columnIndex
- the index for which to retrieve the column type.
public boolean isCellEditable(int rowIndex, int columnIndex)
isCellEditable
in interface TableModel
isCellEditable
in class AbstractTableModel
public Class<?> getColumnClass(int columnIndex)
getColumnClass
in interface TableModel
getColumnClass
in class AbstractTableModel
public String getColumnName(int columnIndex)
getColumnName
in interface TableModel
getColumnName
in class AbstractTableModel
public int getColumnCount()
public int getRowCount()
public Object getValueAt(int rowIndex, int columnIndex)
public void setValueAt(Object value, int rowIndex, int columnIndex)
setValueAt
in interface TableModel
setValueAt
in class AbstractTableModel
|
![]() |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
PERMIS Role Based Access Control 0.3.0 (Build 14)
2009/05/08 09:06:48
Copyright (c) 2002-2007 Ergon Informatik AG