R - type of a rowM - type of the ui modelpublic abstract class AbstractTuttiTableUIHandler<R extends AbstractTuttiBeanUIModel,M extends AbstractTuttiTableUIModel<?,R,M>,UI extends TuttiUI<M,?>> extends AbstractTuttiUIHandler<M,UI>
| Modifier and Type | Field and Description |
|---|---|
protected PersistenceService |
persistenceService
Persistence service.
|
context, ui| Modifier | Constructor and Description |
|---|---|
protected |
AbstractTuttiTableUIHandler(TuttiUIContext context,
UI ui,
String... properties) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addBooleanColumnToModel(TableColumnModel model,
ColumnIdentifier<R> identifier,
JTable table) |
protected void |
addColumnToModel(TableColumnModel model,
ColumnIdentifier<R> identifier) |
protected void |
addColumnToModel(TableColumnModel model,
TableCellEditor editor,
TableCellRenderer renderer,
ColumnIdentifier<R> identifier) |
protected <B> void |
addComboDataColumnToModel(TableColumnModel model,
ColumnIdentifier<R> identifier,
org.nuiton.util.decorator.Decorator<B> decorator,
List<B> data) |
protected void |
addFloatColumnToModel(TableColumnModel model,
ColumnIdentifier<R> identifier,
String numberPattern) |
protected void |
addIntegerColumnToModel(TableColumnModel model,
ColumnIdentifier<R> identifier,
String numberPattern) |
void |
autoSelectRowInTable(MouseEvent e,
JPopupMenu popup) |
protected String[] |
getRowPropertiesToIgnore() |
abstract org.jdesktop.swingx.JXTable |
getTable() |
abstract AbstractTuttiTableModel<R> |
getTableModel() |
protected void |
initTable(org.jdesktop.swingx.JXTable table) |
protected void |
installTableKeyListener(TableColumnModel columnModel,
JTable table) |
protected void |
installTableSaveOnRowChangedSelectionListener() |
protected abstract boolean |
isRowValid(R row)
Validates the given row.
|
protected <O> TableCellRenderer |
newTableCellRender(Class<O> type) |
protected <O> TableCellRenderer |
newTableCellRender(Class<O> type,
String name) |
protected <O> TableCellRenderer |
newTableCellRender(org.nuiton.util.decorator.Decorator<O> decorator) |
protected void |
onAfterSelectedRowChanged(int oldRowIndex,
R oldRow,
int newRowIndex,
R newRow) |
protected void |
onModelRowsChanged(List<R> rows) |
protected void |
onRowModified(int rowIndex,
R row,
String propertyName,
Object oldValue,
Object newValue)
Invoke each time the
AbstractTuttiBeanUIModel.modify state on
the current selected row changed. |
protected void |
onRowModifyStateChanged(int rowIndex,
R row,
Boolean oldValue,
Boolean newValue) |
protected void |
onRowValidStateChanged(int rowIndex,
R row,
Boolean oldValue,
Boolean newValue) |
protected void |
recomputeRowValidState(R row) |
protected void |
saveSelectedRowIfNeeded() |
protected abstract void |
saveSelectedRowIfRequired(TuttiBeanMonitor<R> rowMonitor,
R row)
Given the row monitor and his monitored row, try to save it if required.
|
protected void |
uninstallTableKeyListener() |
protected void |
uninstallTableSaveOnRowChangedSelectionListener() |
afterInitUI, askCancelEditBeforeLeaving, askSaveBeforeLeaving, beforeInitUI, canCloseUI, changeValidatorContext, clearValidators, closeDialog, closeUI, createAction, decorate, doAction, getConfig, getContext, getDataContext, getDecorator, getModel, getPropertiesToIgnore, getUI, getValidator, initAction, initBeanComboBox, initBeanComboBox, initBeanList, initButtonAttachmentEditor, initDatePicker, initNumberEditor, initTimeEditor, initUI, listenValidatorValid, listModelIsModify, newComboActionModel, newComboModel, newListCellRender, newListCellRender, newListCellRender, onCloseUI, openDialog, registerValidators, selectFirstInCombo, selectListData, setBoolean, setDate, setText, showInformationMessageprotected final PersistenceService persistenceService
protected AbstractTuttiTableUIHandler(TuttiUIContext context, UI ui, String... properties)
public abstract AbstractTuttiTableModel<R> getTableModel()
public abstract org.jdesktop.swingx.JXTable getTable()
protected abstract boolean isRowValid(R row)
row - row to validatetrue if row is valid, false otherwise.protected void onRowModified(int rowIndex,
R row,
String propertyName,
Object oldValue,
Object newValue)
AbstractTuttiBeanUIModel.modify state on
the current selected row changed.rowIndex - row index of the modified rowrow - modified rowpropertyName - name of the modified property of the rowoldValue - old value of the modified propertynewValue - new value of the modified propertyprotected abstract void saveSelectedRowIfRequired(TuttiBeanMonitor<R> rowMonitor, R row)
rowMonitor - the row monitor (see rowMonitor)row - the row to save if necessaryprotected String[] getRowPropertiesToIgnore()
protected void onRowModifyStateChanged(int rowIndex,
R row,
Boolean oldValue,
Boolean newValue)
protected void onRowValidStateChanged(int rowIndex,
R row,
Boolean oldValue,
Boolean newValue)
protected void onAfterSelectedRowChanged(int oldRowIndex,
R oldRow,
int newRowIndex,
R newRow)
protected void initTable(org.jdesktop.swingx.JXTable table)
protected void addColumnToModel(TableColumnModel model, TableCellEditor editor, TableCellRenderer renderer, ColumnIdentifier<R> identifier)
protected void addColumnToModel(TableColumnModel model, ColumnIdentifier<R> identifier)
protected void addFloatColumnToModel(TableColumnModel model, ColumnIdentifier<R> identifier, String numberPattern)
protected void addIntegerColumnToModel(TableColumnModel model, ColumnIdentifier<R> identifier, String numberPattern)
protected void addBooleanColumnToModel(TableColumnModel model, ColumnIdentifier<R> identifier, JTable table)
protected <B> void addComboDataColumnToModel(TableColumnModel model, ColumnIdentifier<R> identifier, org.nuiton.util.decorator.Decorator<B> decorator, List<B> data)
protected <O> TableCellRenderer newTableCellRender(Class<O> type)
protected <O> TableCellRenderer newTableCellRender(Class<O> type, String name)
protected <O> TableCellRenderer newTableCellRender(org.nuiton.util.decorator.Decorator<O> decorator)
protected void installTableSaveOnRowChangedSelectionListener()
protected void uninstallTableSaveOnRowChangedSelectionListener()
protected void installTableKeyListener(TableColumnModel columnModel, JTable table)
protected void uninstallTableKeyListener()
protected final void saveSelectedRowIfNeeded()
protected final void recomputeRowValidState(R row)
public void autoSelectRowInTable(MouseEvent e, JPopupMenu popup)
Copyright © 2012-2013 Ifremer. All Rights Reserved.