public class DefaultChangeValueCommand extends AbstractCommand
DefaultTreeTableModel and the node implements ITreeTableNode.INodeEditPolicy.isValueEditable(Object,
com.dlsc.flexgantt.model.treetable.ITreeTableModel, int),
INodeEditPolicy.getChangeValueCommand(Object,
com.dlsc.flexgantt.model.treetable.ITreeTableModel, Object, int),
Serialized Form| Constructor and Description |
|---|
DefaultChangeValueCommand(DefaultMutableTreeTableNode node,
DefaultTreeTableModel model,
Object value,
int index)
Constructs a new command.
|
| Modifier and Type | Method and Description |
|---|---|
void |
executeCommand(IProgressMonitor monitor)
Executes the command.
|
DefaultTreeTableModel |
getModel()
Returns the tree table model to which the node belongs.
|
Object |
getNewValue()
Returns the new column value.
|
ITreeTableNode |
getNode()
Returns the node that was modified.
|
Object |
getOldValue()
Returns the old column value.
|
int |
getValueIndex()
Returns the model index under which the new value gets stored.
|
void |
undoCommand(IProgressMonitor monitor)
Undos the command.
|
getName, isRedoable, isRelevant, isUndoable, redoCommand, setNamepublic DefaultChangeValueCommand(DefaultMutableTreeTableNode node, DefaultTreeTableModel model, Object value, int index)
node - the node that will be modifiedmodel - the model to which the node belongsvalue - the new column valueindex - the model index where the column value will be setITreeTableNode.setColumnValue(Object, int)public void executeCommand(IProgressMonitor monitor) throws CommandException
ICommandmonitor - a progress monitorCommandException - if anything during the execution of the command has gone
wrongpublic void undoCommand(IProgressMonitor monitor) throws CommandException
ICommandmonitor - a progress monitorCommandException - if anything during the execution of the command has gone
wrongpublic DefaultTreeTableModel getModel()
public ITreeTableNode getNode()
public Object getNewValue()
public Object getOldValue()
public int getValueIndex()
Copyright © 2006–2020 Dirk Lemmermann Software & Consulting. All rights reserved.