public class SwingTableModelFillState extends AbstractSwingState implements State, TableModelListener
mSilentmIsEnabled, mIsInitialized, mListenerList, mName, mReason| Constructor and Description | 
|---|
SwingTableModelFillState(JTable pTable)
Creates a new state, using the model of the handed table as its state source. 
 | 
SwingTableModelFillState(JTable pTable,
                        int pThreshold)
Creates a new state, using the model of the handed list as its state source. 
 | 
SwingTableModelFillState(TableModel pModel,
                        int pThreshold)
Creates a new state, using the handed model as its state source. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
protected boolean | 
getInternalState()
Check if our table model contains at least our threshold number of rows. 
 | 
void | 
setCompareContent(int pThreshold)
Sets the threshold we compare again. 
 | 
protected void | 
setReason()
Set the source of the state as the reason for a change. 
 | 
void | 
tableChanged(TableModelEvent pEvent)
Callback method for our table model. 
 | 
checkStateChange, isSilent, setSilentaddChangeListener, checkDisposed, dispose, fireStateChanged, getChangeReason, getDependents, getName, isDisposed, isEnabled, isInitialized, removeChangeListener, setName, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitaddChangeListener, dispose, getChangeReason, getDependents, getName, isDisposed, isEnabled, isInitialized, removeChangeListener, setNamepublic SwingTableModelFillState(JTable pTable)
pTable - table we take the model from, must not be nullpublic SwingTableModelFillState(JTable pTable, int pThreshold)
pTable - table we take the model from, must not be nullpThreshold - threshold of rows in the tablepublic SwingTableModelFillState(TableModel pModel, int pThreshold)
pThreshold - threshold of rows in the tablepModel - the model we monitor, must not be nullpublic void setCompareContent(int pThreshold)
pThreshold - threshold of rows in the tablepublic void tableChanged(TableModelEvent pEvent)
tableChanged in interface TableModelListenerpEvent - not usedprotected boolean getInternalState()
getInternalState in class AbstractSwingStateprotected void setReason()
setReason in class AbstractSwingStateCopyright © 2017 Jürgen Zeller (privat). All rights reserved.