Class AbstractBoundedTableModelWithSelection
java.lang.Object
javax.swing.table.AbstractTableModel
com.michaelbaranov.microba.common.AbstractBoundedTableModel
com.michaelbaranov.microba.common.AbstractBoundedTableModelWithSelection
- All Implemented Interfaces:
BoundedTableModel
,Serializable
,ListSelectionModel
,TableModel
- Direct Known Subclasses:
DefaultGradientEditorModel
,DefaultMarkerModel
public abstract class AbstractBoundedTableModelWithSelection
extends AbstractBoundedTableModel
implements ListSelectionModel
A simple abstract implementation of
BoundedTableModel
with
implemented ListSelectionModel
functionality. A convenience
class.- Author:
- Michael Baranov
- See Also:
-
Field Summary
Fields inherited from interface com.michaelbaranov.microba.common.BoundedTableModel
PROPERTY_LOWER_BOUND, PROPERTY_UPPER_BOUND
Fields inherited from interface javax.swing.ListSelectionModel
MULTIPLE_INTERVAL_SELECTION, SINGLE_INTERVAL_SELECTION, SINGLE_SELECTION
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
void
addSelectionInterval
(int index0, int index1) void
int
int
getListeners
(Class listenerType) int
int
int
boolean
void
insertIndexInterval
(int index, int length, boolean before) boolean
boolean
isSelectedIndex
(int index) boolean
void
removeIndexInterval
(int index0, int index1) void
void
removeSelectionInterval
(int index0, int index1) void
setAnchorSelectionIndex
(int anchorIndex) void
setLeadAnchorNotificationEnabled
(boolean flag) void
setLeadSelectionIndex
(int leadIndex) void
setSelectionInterval
(int index0, int index1) void
setSelectionMode
(int selectionMode) void
setValueIsAdjusting
(boolean isAdjusting) Methods inherited from class com.michaelbaranov.microba.common.AbstractBoundedTableModel
addPropertyChangeListener, addPropertyChangeListener, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getPropertyChangeListeners, getPropertyChangeListeners, hasListeners, removePropertyChangeListener, removePropertyChangeListener
Methods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getColumnName, getTableModelListeners, isCellEditable, removeTableModelListener, setValueAt
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.michaelbaranov.microba.common.BoundedTableModel
getLowerBound, getUpperBound
Methods inherited from interface javax.swing.ListSelectionModel
getSelectedIndices, getSelectedItemsCount
Methods inherited from interface javax.swing.table.TableModel
addTableModelListener, getColumnClass, getColumnCount, getColumnName, getRowCount, getValueAt, isCellEditable, removeTableModelListener, setValueAt
-
Constructor Details
-
AbstractBoundedTableModelWithSelection
public AbstractBoundedTableModelWithSelection()
-
-
Method Details
-
addListSelectionListener
- Specified by:
addListSelectionListener
in interfaceListSelectionModel
-
addSelectionInterval
public void addSelectionInterval(int index0, int index1) - Specified by:
addSelectionInterval
in interfaceListSelectionModel
-
clearSelection
public void clearSelection()- Specified by:
clearSelection
in interfaceListSelectionModel
-
getAnchorSelectionIndex
public int getAnchorSelectionIndex()- Specified by:
getAnchorSelectionIndex
in interfaceListSelectionModel
-
getLeadSelectionIndex
public int getLeadSelectionIndex()- Specified by:
getLeadSelectionIndex
in interfaceListSelectionModel
-
getListeners
- Overrides:
getListeners
in classAbstractTableModel
-
getListSelectionListeners
-
getMaxSelectionIndex
public int getMaxSelectionIndex()- Specified by:
getMaxSelectionIndex
in interfaceListSelectionModel
-
getMinSelectionIndex
public int getMinSelectionIndex()- Specified by:
getMinSelectionIndex
in interfaceListSelectionModel
-
getSelectionMode
public int getSelectionMode()- Specified by:
getSelectionMode
in interfaceListSelectionModel
-
getValueIsAdjusting
public boolean getValueIsAdjusting()- Specified by:
getValueIsAdjusting
in interfaceListSelectionModel
-
insertIndexInterval
public void insertIndexInterval(int index, int length, boolean before) - Specified by:
insertIndexInterval
in interfaceListSelectionModel
-
isLeadAnchorNotificationEnabled
public boolean isLeadAnchorNotificationEnabled() -
isSelectedIndex
public boolean isSelectedIndex(int index) - Specified by:
isSelectedIndex
in interfaceListSelectionModel
-
isSelectionEmpty
public boolean isSelectionEmpty()- Specified by:
isSelectionEmpty
in interfaceListSelectionModel
-
removeIndexInterval
public void removeIndexInterval(int index0, int index1) - Specified by:
removeIndexInterval
in interfaceListSelectionModel
-
removeListSelectionListener
- Specified by:
removeListSelectionListener
in interfaceListSelectionModel
-
removeSelectionInterval
public void removeSelectionInterval(int index0, int index1) - Specified by:
removeSelectionInterval
in interfaceListSelectionModel
-
setAnchorSelectionIndex
public void setAnchorSelectionIndex(int anchorIndex) - Specified by:
setAnchorSelectionIndex
in interfaceListSelectionModel
-
setLeadAnchorNotificationEnabled
public void setLeadAnchorNotificationEnabled(boolean flag) -
setLeadSelectionIndex
public void setLeadSelectionIndex(int leadIndex) - Specified by:
setLeadSelectionIndex
in interfaceListSelectionModel
-
setSelectionInterval
public void setSelectionInterval(int index0, int index1) - Specified by:
setSelectionInterval
in interfaceListSelectionModel
-
setSelectionMode
public void setSelectionMode(int selectionMode) - Specified by:
setSelectionMode
in interfaceListSelectionModel
-
setValueIsAdjusting
public void setValueIsAdjusting(boolean isAdjusting) - Specified by:
setValueIsAdjusting
in interfaceListSelectionModel
-