Package com.iizix.prop.vs
Class VSTableAdapter
- java.lang.Object
- com.iizix.prop.vs.VSTableAdapter
- All Implemented Interfaces:
IVSComponentListener
,IVSComponentState
,IVSTableListener
public class VSTableAdapter extends java.lang.Object implements IVSTableListener
Adapter for interface used to listen to VS table events.- Author:
- Christopher Mindus
Nested Class Summary
Nested classes/interfaces inherited from interface com.iizix.prop.vs.IVSComponentState
IVSComponentState.State
Constructor Summary
Constructors Constructor Description VSTableAdapter()
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
onBroken(VSRelativeReference<?> reference, VSTable table)
Called when the property reference has been broken, i.e.void
onCellStateChanged(VSField cell, IVSComponentState.State state, boolean on)
Called when the cell changes state.void
onCellValueChanged(VSField cell, Value value, GProp<?> trigger, IPostEventProcessing postProcessing)
Called when the cell value is set.void
onParentStateChanged(IVSComponent parent, IVSComponentState.State state, boolean on)
Called when the column changes state.void
onResolved(VSRelativeReference<?> reference, VSTable table)
Called when the property reference has been resolved.void
onRowAdded(VSRow row, int index)
Called when a row is added.void
onRowRemoved(VSRow row, int index)
Called when a row is removed.void
onRowStateChanged(VSRow row, IVSComponentState.State state, boolean on)
Called when a row selection state changed.void
onSingleSelectionChanged(VSTable table, int index)
Called when the single selection changes.void
onStateChanged(VSTable table, IVSComponentState.State state, boolean on)
Called when the table changes state.
Method Detail
onResolved
public void onResolved(VSRelativeReference<?> reference, VSTable table)
Called when the property reference has been resolved. UI components use this method to set its state according to the field.- Specified by:
onResolved
in interfaceIVSTableListener
- Parameters:
reference
- The VSRelativeReference instance holding the reference.table
- The target reference.
onBroken
public void onBroken(VSRelativeReference<?> reference, VSTable table)
Called when the property reference has been broken, i.e. unresolved.- Specified by:
onBroken
in interfaceIVSTableListener
- Parameters:
reference
- The VSRelativeReference instance holding the reference.table
- The target reference.
onStateChanged
public void onStateChanged(VSTable table, IVSComponentState.State state, boolean on)
Called when the table changes state.- Specified by:
onStateChanged
in interfaceIVSTableListener
- Parameters:
table
- The VS table.state
- The state change.on
- New state.
onParentStateChanged
public void onParentStateChanged(IVSComponent parent, IVSComponentState.State state, boolean on)
Called when the column changes state.- Specified by:
onParentStateChanged
in interfaceIVSComponentListener
- Parameters:
parent
- The parent who's state was changed.state
- The state change, possible values PARENT_ENABLED, PARENT_READONLY, PARENT_VISIBLE.on
- New state.
onSingleSelectionChanged
public void onSingleSelectionChanged(VSTable table, int index)
Called when the single selection changes.- Specified by:
onSingleSelectionChanged
in interfaceIVSTableListener
- Parameters:
table
- The table.index
- The row index, -1 if table is unselected.
onRowAdded
public void onRowAdded(VSRow row, int index)
Called when a row is added.- Specified by:
onRowAdded
in interfaceIVSTableListener
- Parameters:
row
- The row.index
- The index.
onRowRemoved
public void onRowRemoved(VSRow row, int index)
Called when a row is removed.- Specified by:
onRowRemoved
in interfaceIVSTableListener
- Parameters:
row
- The row.index
- The index.
onRowStateChanged
public void onRowStateChanged(VSRow row, IVSComponentState.State state, boolean on)
Called when a row selection state changed.- Specified by:
onRowStateChanged
in interfaceIVSTableListener
- Parameters:
row
- The row.state
- The state change.on
- New state.
onCellStateChanged
public void onCellStateChanged(VSField cell, IVSComponentState.State state, boolean on)
Called when the cell changes state.- Specified by:
onCellStateChanged
in interfaceIVSTableListener
- Parameters:
cell
- The VS cell.state
- The state change.on
- New state.
onCellValueChanged
public void onCellValueChanged(VSField cell, Value value, GProp<?> trigger, IPostEventProcessing postProcessing)
Called when the cell value is set.- Specified by:
onCellValueChanged
in interfaceIVSTableListener
- Parameters:
cell
- The VS field.value
- The value, never null, butvalue.isNull()
could be true.trigger
- The trigger property that may be null.postProcessing
- Post-processing instance.