Module org.autogui
Package org.autogui.swing.table
Class GuiSwingTableColumnCollection.ObjectTableColumnCollectionWrapper
java.lang.Object
org.autogui.swing.table.ObjectTableColumn
org.autogui.swing.table.GuiSwingTableColumnCollection.ObjectTableColumnCollectionWrapper
- All Implemented Interfaces:
GuiSwingView.SettingsWindowClient,GuiSwingPrefsSupports.PreferencesUpdateSupport,GuiSwingTableColumn.ObjectTableColumnWithContext
- Enclosing class:
GuiSwingTableColumnCollection
public static class GuiSwingTableColumnCollection.ObjectTableColumnCollectionWrapper
extends ObjectTableColumn
implements GuiSwingTableColumn.ObjectTableColumnWithContext
a dynamic version of column
-
Nested Class Summary
Nested classes/interfaces inherited from class org.autogui.swing.table.ObjectTableColumn
ObjectTableColumn.NumberRenderer, ObjectTableColumn.ObjectTableColumnLabel<ObjType,PropType>, ObjectTableColumn.ObjectTableColumnRowIndex, ObjectTableColumn.PopupMenuBuilderSource, ObjectTableColumn.PopupMenuBuilderSourceForHeader, ObjectTableColumn.TableMenuComposite, ObjectTableColumn.TableMenuCompositeShared, ObjectTableColumn.TableTargetColumnForObjectColumn -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected ObjectTableColumnprotected Map<GuiSwingTableColumn.SpecifierManagerIndex, Integer> protected int[]suppose {(parentIndices, ...,) elementIndex, propertyIndex}Fields inherited from class org.autogui.swing.table.ObjectTableColumn
comparator, rowHeight, tableColumn, valueType -
Constructor Summary
ConstructorsConstructorDescriptionObjectTableColumnCollectionWrapper(String headerName, GuiSwingTableColumn.ObjectTableColumnWithContext column, Map<GuiSwingTableColumn.SpecifierManagerIndex, Integer> indexInjection, GuiSwingTableColumn.SpecifierManagerIndex rowSpecifier, int[] indices) -
Method Summary
Modifier and TypeMethodDescriptionint[]columnIndexToValueIndex(int columnIndex) booleancontainsIndexInjections(List<GuiSwingTableColumn.SpecifierManagerIndex> requiredSpecs) getCellValue(Object rowObject, int rowIndex, int columnIndex, GuiReprValue.ObjectSpecifier specifier) getCellValueFromContext(int rowIndex, int columnIndex, GuiReprValue.ObjectSpecifier specifier) Comparator<?> getIndexInjection(int rowIndex, List<GuiSwingTableColumn.SpecifierManagerIndex> requiredSpecs) getIndexInjectionForRowAndColumnIndices(int rowIndex, List<GuiSwingTableColumn.SpecifierManagerIndex> requiredSpecs) intgetSpecifier(int rowIndex, int columnIndex) voidloadSwingPreferences(GuiPreferences prefs, GuiSwingPrefsApplyOptions options) voidFuture<?> setCellValue(Object rowObject, int rowIndex, int columnIndex, Object newColumnValue, GuiReprValue.ObjectSpecifier specifier) Future<?> setCellValueFromContext(int rowIndex, int columnIndex, Object newColumnValue, GuiReprValue.ObjectSpecifier specifier) voidsetColumnViewUpdater(Consumer<ObjectTableColumn> updater) voidsetComparator(Comparator<?> comparator) voidvoidsetRowHeight(int rowHeight) voidsetSettingsWindow(SettingsWindow settingWindow) at initialization of the root-pane, the method will be called for existing sub-panes.voidsetTableColumn(TableColumn tableColumn) voidshutdown()voidviewUpdateAsDynamic(ObjectTableColumn source) Methods inherited from class org.autogui.swing.table.ObjectTableColumn
createLabel, createLabel, fromActionValue, getHeaderMenuItems, getMenuBuilderSource, getValueType, isTaskRunnerUsedFor, setCellBorder, setValueType, toActionValue, withCellEditor, withCellRenderer, withComparator, withHeaderRenderer, withHeaderValue, withIdentifier, withMaxWidth, withMinWidth, withPreferredWidth, withResizable, withRowHeight, withTableColumn, withValueTypeMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.autogui.swing.table.GuiSwingTableColumn.ObjectTableColumnWithContext
asColumn, getInits, loadSwingPreferences
-
Field Details
-
column
-
rowSpecifier
-
indexInjection
-
indices
protected int[] indicessuppose {(parentIndices, ...,) elementIndex, propertyIndex}
-
-
Constructor Details
-
ObjectTableColumnCollectionWrapper
public ObjectTableColumnCollectionWrapper(String headerName, GuiSwingTableColumn.ObjectTableColumnWithContext column, Map<GuiSwingTableColumn.SpecifierManagerIndex, Integer> indexInjection, GuiSwingTableColumn.SpecifierManagerIndex rowSpecifier, int[] indices)
-
-
Method Details
-
getContext
- Specified by:
getContextin interfaceGuiSwingTableColumn.ObjectTableColumnWithContext
-
getSpecifierManager
- Specified by:
getSpecifierManagerin interfaceGuiSwingTableColumn.ObjectTableColumnWithContext
-
setColumnViewUpdater
- Overrides:
setColumnViewUpdaterin classObjectTableColumn
-
setSettingsWindow
Description copied from interface:GuiSwingView.SettingsWindowClientat initialization of the root-pane, the method will be called for existing sub-panes. a dynamically created view needs to be manually set by those panes.- Specified by:
setSettingsWindowin interfaceGuiSwingView.SettingsWindowClient- Parameters:
settingWindow- a settings-window from the root-pane, which will be disposed at closing of the main window
-
getSettingsWindow
- Specified by:
getSettingsWindowin interfaceGuiSwingView.SettingsWindowClient
-
setPreferencesUpdater
- Specified by:
setPreferencesUpdaterin interfaceGuiSwingPrefsSupports.PreferencesUpdateSupport
-
saveSwingPreferences
- Specified by:
saveSwingPreferencesin interfaceGuiSwingTableColumn.ObjectTableColumnWithContext
-
loadSwingPreferences
- Specified by:
loadSwingPreferencesin interfaceGuiSwingTableColumn.ObjectTableColumnWithContext- Parameters:
prefs- the source preferencesoptions- processor
-
getSpecifier
- Overrides:
getSpecifierin classObjectTableColumn- Parameters:
rowIndex- the row indexcolumnIndex- the column index. ignored- Returns:
- a created specifier with setting the row index and indexInjection. the row index can be variable, and the column index (sub-indices except for the row index) is fixed as a dynamically created column.
-
getCellValue
public Object getCellValue(Object rowObject, int rowIndex, int columnIndex, GuiReprValue.ObjectSpecifier specifier) - Overrides:
getCellValuein classObjectTableColumn- Parameters:
rowObject- the row object at rowIndexrowIndex- the row indexcolumnIndex- the column indexspecifier- specifier fromObjectTableColumn.getSpecifier(int, int)- Returns:
- the value at columnIndex of rowObject.
it might be
Future, and then the value will be specially treated as getting the value of the future as the cell value.
-
setCellValue
public Future<?> setCellValue(Object rowObject, int rowIndex, int columnIndex, Object newColumnValue, GuiReprValue.ObjectSpecifier specifier) - Overrides:
setCellValuein classObjectTableColumn- Parameters:
rowObject- the row object at rowIndexrowIndex- the row indexcolumnIndex- the column indexnewColumnValue- the new value to be setspecifier- specifier fromObjectTableColumn.getSpecifier(int, int)- Returns:
- a future object for checking completion of the updating or null
-
getCellValueFromContext
public Object getCellValueFromContext(int rowIndex, int columnIndex, GuiReprValue.ObjectSpecifier specifier) - Overrides:
getCellValueFromContextin classObjectTableColumn
-
setCellValueFromContext
public Future<?> setCellValueFromContext(int rowIndex, int columnIndex, Object newColumnValue, GuiReprValue.ObjectSpecifier specifier) - Overrides:
setCellValueFromContextin classObjectTableColumn
-
columnIndexToValueIndex
public int[] columnIndexToValueIndex(int columnIndex) - Overrides:
columnIndexToValueIndexin classObjectTableColumn
-
setTableColumn
- Overrides:
setTableColumnin classObjectTableColumn
-
getRowHeight
public int getRowHeight()- Overrides:
getRowHeightin classObjectTableColumn
-
setRowHeight
public void setRowHeight(int rowHeight) - Overrides:
setRowHeightin classObjectTableColumn
-
getComparator
- Overrides:
getComparatorin classObjectTableColumn
-
setComparator
- Overrides:
setComparatorin classObjectTableColumn
-
shutdown
public void shutdown()- Overrides:
shutdownin classObjectTableColumn
-
getTableColumn
- Overrides:
getTableColumnin classObjectTableColumn
-
getCompositesForRows
- Overrides:
getCompositesForRowsin classObjectTableColumn
-
getCompositesForCells
- Overrides:
getCompositesForCellsin classObjectTableColumn
-
viewUpdateAsDynamic
- Overrides:
viewUpdateAsDynamicin classObjectTableColumn
-
containsIndexInjections
public boolean containsIndexInjections(List<GuiSwingTableColumn.SpecifierManagerIndex> requiredSpecs) -
getIndexInjection
public Map<GuiSwingTableColumn.SpecifierManagerIndex,Integer> getIndexInjection(int rowIndex, List<GuiSwingTableColumn.SpecifierManagerIndex> requiredSpecs) -
getIndexInjectionForRowAndColumnIndices
public Map<GuiSwingTableColumn.SpecifierManagerIndex,Integer> getIndexInjectionForRowAndColumnIndices(int rowIndex, List<GuiSwingTableColumn.SpecifierManagerIndex> requiredSpecs) -
getHeaderMenuItemsInfo
- Overrides:
getHeaderMenuItemsInfoin classObjectTableColumn- Returns:
- the label info string: the default value is string of
TableColumn.getHeaderValue()
-