Class InputOverlayTableModel
java.lang.Object
javax.swing.table.AbstractTableModel
com.illumon.iris.gui.table.IrisTableModel
com.illumon.iris.gui.table.GuiTableMap
com.illumon.iris.console.utils.input.InputOverlayTableModel
- All Implemented Interfaces:
DBTableFetcher,DBViewportFetcher,InputOverlayLayer,ExtendableTableInterface,FilteredModel,MultiModelTable,SortableModel,ToolTipGeneratingTableModel,UpdateListener,Workspace,Serializable,EventListener,TableModelListener,TableModel
public class InputOverlayTableModel
extends GuiTableMap
implements TableModelListener, InputOverlayLayer, DBTableFetcher, DBViewportFetcher, ToolTipGeneratingTableModel, SortableModel, FilteredModel
This is the table model for the spreadsheet like input table editor widget
LiveInputTableEditor.- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.illumon.iris.gui.table.ExtendableTableInterface
ExtendableTableInterface.Entry, ExtendableTableInterface.PartialResultNested classes/interfaces inherited from interface com.illumon.iris.gui.table.SortableModel
SortableModel.SortingDirectiveNested classes/interfaces inherited from interface com.illumon.iris.gui.table.ToolTipGeneratingTableModel
ToolTipGeneratingTableModel.GeneratedToolTip -
Field Summary
Fields inherited from class com.illumon.iris.gui.table.GuiTableMap
model_, originalTableModel_Fields inherited from class com.illumon.iris.gui.table.IrisTableModel
columnSet_, nonViewColumnSet_Fields inherited from class javax.swing.table.AbstractTableModel
listenerList -
Constructor Summary
ConstructorsConstructorDescriptionInputOverlayTableModel(InputTableEditorPanel panel, IrisTableModel model, Table table, MutableInputTable inputTable, InputTableSelectionHandler handler, boolean enabledAddRow, boolean keysEditable, com.fishlib.io.logger.Logger log, InputTableStatusListener statusListener) -
Method Summary
Modifier and TypeMethodDescriptionvoidClear sorting on all columns.voidclear(boolean isUndo) voidNotify the implementation that the set of underlying filters have changed.generateToolTip(int col, GuiColumn column) Class<?>getColumnClass(int column) getColumnName(int column) Get theFilterStrategyImplin use.getHeaderRendererIcon(int modelColumn, int size) Get the sort icon for the specified column and size.getInputLayerObjectAtInputLayerOnly(int row, int col) intgetMappedRowIndex(int index) intgetOriginalRowIndex(int index) int[]getOriginalRowIndices(int[] index, boolean sorted) intorg.jdom2.Element[]Get all of the saved strategy workspaceElementsGet the set of sortable columns.getSortingDirective(int column) Get the sorting status of a single column.getTable()getValueAt(int rowIndex, int columnIndex) getValueAtInputLayerOnly(int row, int col) booleanvoidCalled when sorting should be changed based on a header click.booleanisCellEditable(int rowIndex, int columnIndex) booleanisFilterable(String column) Check if the specified column is filterable.booleanCheck if the model is currently being filtered.booleandetermine whether there are any sorting directives - similar to empty()booleanisStale(int row, int col) voidremoveStrategy(String name) Remove the globally saved filter of the specified name.voidvoidsaveStrategy(String result) Save the current set of filters to the global set of filters by name.voidsetSortingStatus(int column, int status, boolean isAbsolute, boolean clearSorting) Set the sorting status of a single column.voidsetToolTipDialog(int col, GuiColumn column, JDialog dialog, JLabel label) voidsetValueAt(Object value, int rowIndex, int columnIndex) voidshowStatistics(JTable table, int col, GuiColumn column) voidMethods inherited from class com.illumon.iris.gui.table.GuiTableMap
beginAddColumns, finishAddColumns, getColumnCount, getExtendedColumns, getModel, getModel, getOriginalModel, getOriginalRowIndices, getWorkspaceInfo, popFinishedCallback, setColumnSet, setFinishedCallback, setWorkspaceInfo, supportsColumnChangeMethods inherited from class com.illumon.iris.gui.table.IrisTableModel
dispose, getColumnIndex, getColumnSet, getNonViewColumnSet, getTableModelName, processUpdate, registerAsUpdateListenerMethods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, removeTableModelListenerMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.illumon.iris.gui.table.FilteredModel
getColumnSetMethods inherited from interface com.illumon.iris.console.utils.input.InputOverlayLayer
getInputLayerObjectAtInputLayerOnly, getValueAtInputLayerOnlyMethods inherited from interface javax.swing.table.TableModel
addTableModelListener, getColumnCount, removeTableModelListenerMethods inherited from interface com.illumon.iris.gui.workspace.Workspace
isGlobalSetting
-
Constructor Details
-
InputOverlayTableModel
public InputOverlayTableModel(InputTableEditorPanel panel, IrisTableModel model, Table table, MutableInputTable inputTable, InputTableSelectionHandler handler, boolean enabledAddRow, boolean keysEditable, com.fishlib.io.logger.Logger log, InputTableStatusListener statusListener)
-
-
Method Details
-
getValueAtInputLayerOnly
- Specified by:
getValueAtInputLayerOnlyin interfaceInputOverlayLayer
-
getInputLayerObjectAtInputLayerOnly
- Specified by:
getInputLayerObjectAtInputLayerOnlyin interfaceInputOverlayLayer
-
isCellEditable
public boolean isCellEditable(int rowIndex, int columnIndex) - Specified by:
isCellEditablein interfaceTableModel- Overrides:
isCellEditablein classGuiTableMap
-
setValueAt
- Specified by:
setValueAtin interfaceTableModel- Overrides:
setValueAtin classGuiTableMap
-
saveChanges
public void saveChanges()- Specified by:
saveChangesin interfaceInputOverlayLayer
-
clear
public void clear(boolean isUndo) - Specified by:
clearin interfaceInputOverlayLayer
-
getMappedRowIndex
public int getMappedRowIndex(int index) - Specified by:
getMappedRowIndexin classGuiTableMap
-
isStale
public boolean isStale(int row, int col) - Overrides:
isStalein classGuiTableMap
-
getValueAt
- Specified by:
getValueAtin interfaceTableModel- Overrides:
getValueAtin classGuiTableMap
-
getRowCount
public int getRowCount()- Specified by:
getRowCountin interfaceTableModel- Overrides:
getRowCountin classGuiTableMap
-
tableChanged
- Specified by:
tableChangedin interfaceTableModelListener
-
getOriginalRowIndex
public int getOriginalRowIndex(int index) - Overrides:
getOriginalRowIndexin classGuiTableMap
-
getTable
- Specified by:
getTablein interfaceDBTableFetcher
-
getDbViewportTable
- Specified by:
getDbViewportTablein interfaceDBViewportFetcher
-
getColumnClass
- Specified by:
getColumnClassin interfaceTableModel- Overrides:
getColumnClassin classGuiTableMap
-
getColumnName
- Specified by:
getColumnNamein interfaceTableModel- Overrides:
getColumnNamein classGuiTableMap
-
getOriginalRowIndices
public int[] getOriginalRowIndices(int[] index, boolean sorted) - Specified by:
getOriginalRowIndicesin interfaceMultiModelTable- Overrides:
getOriginalRowIndicesin classGuiTableMap
-
generateToolTip
- Specified by:
generateToolTipin interfaceToolTipGeneratingTableModel
-
hasShowStatistics
public boolean hasShowStatistics()- Specified by:
hasShowStatisticsin interfaceToolTipGeneratingTableModel
-
showStatistics
- Specified by:
showStatisticsin interfaceToolTipGeneratingTableModel
-
setToolTipDialog
- Specified by:
setToolTipDialogin interfaceToolTipGeneratingTableModel
-
filterChanged
public void filterChanged()Description copied from interface:FilteredModelNotify the implementation that the set of underlying filters have changed.- Specified by:
filterChangedin interfaceFilteredModel
-
getFilterStrategy
Description copied from interface:FilteredModelGet theFilterStrategyImplin use.- Specified by:
getFilterStrategyin interfaceFilteredModel- Returns:
- the FilterStrategy
-
saveStrategy
Description copied from interface:FilteredModelSave the current set of filters to the global set of filters by name.- Specified by:
saveStrategyin interfaceFilteredModel- Parameters:
result- the name of the filter
-
getSavedStrategies
@NotNull public org.jdom2.Element[] getSavedStrategies()Description copied from interface:FilteredModelGet all of the saved strategy workspaceElements- Specified by:
getSavedStrategiesin interfaceFilteredModel- Returns:
- an array of saved filter strategy elements.
-
removeStrategy
Description copied from interface:FilteredModelRemove the globally saved filter of the specified name.- Specified by:
removeStrategyin interfaceFilteredModel- Parameters:
name- the name of the filter to remove
-
isFilteringOn
public boolean isFilteringOn()Description copied from interface:FilteredModelCheck if the model is currently being filtered.- Specified by:
isFilteringOnin interfaceFilteredModel- Returns:
- true if filters are currently applied
-
isFilterable
Description copied from interface:FilteredModelCheck if the specified column is filterable.- Specified by:
isFilterablein interfaceFilteredModel- Parameters:
column- the column name.- Returns:
- true if the column is filterable.
-
headerClicked
Description copied from interface:SortableModelCalled when sorting should be changed based on a header click.- Specified by:
headerClickedin interfaceSortableModel- Parameters:
e- the drivingMouseEvent
-
getHeaderRendererIcon
Description copied from interface:SortableModelGet the sort icon for the specified column and size. May return null, for no icon.- Specified by:
getHeaderRendererIconin interfaceSortableModel- Parameters:
modelColumn- the columnsize- the icon size- Returns:
- an icon to render for sorting.
-
cancelSorting
public void cancelSorting()Description copied from interface:SortableModelClear sorting on all columns.- Specified by:
cancelSortingin interfaceSortableModel
-
setSortingStatus
public void setSortingStatus(int column, int status, boolean isAbsolute, boolean clearSorting) Description copied from interface:SortableModelSet the sorting status of a single column. Adds to existing sort definition.- Specified by:
setSortingStatusin interfaceSortableModel
-
getSortingDirective
Description copied from interface:SortableModelGet the sorting status of a single column.- Specified by:
getSortingDirectivein interfaceSortableModel
-
isSorting
public boolean isSorting()Description copied from interface:SortableModeldetermine whether there are any sorting directives - similar to empty()- Specified by:
isSortingin interfaceSortableModel
-
getSortableColumns
Description copied from interface:SortableModelGet the set of sortable columns.- Specified by:
getSortableColumnsin interfaceSortableModel- Overrides:
getSortableColumnsin classGuiTableMap- Returns:
- the set of sortable columns
-