int column = tme.getColumn();
if (tme.getType() == TableModelEvent.UPDATE) {
ModelTableList tmpTableModel = (ModelTableList) tme.getSource();
EnergyTrajectoryLine energyTrajectoryLine = energyTrajectoryLines.get(row);
switch(column) {
case 1: // start energy
Double startEnergy = (Double) tmpTableModel.getValueAt(row, column);
energyTrajectoryLine.setBeginPosition(startEnergy);
controller.notifyBeginPositionAfterChanged(startEnergy, row);
break;
case 2: // end energy
Double endEnergy = (Double) tmpTableModel.getValueAt(row, column);
energyTrajectoryLine.setEndPosition(endEnergy);
controller.notifyEndPositionAfterChanged(endEnergy, row);
break;
case 3: // energy step
Double energyStep = (Double) tmpTableModel.getValueAt(row, column);
energyTrajectoryLine.setDelta(energyStep);
controller.notifyDeltaAfterChanged(energyStep, row);
break;
case 4: // step number
Integer stepNumber = (Integer) tmpTableModel.getValueAt(row, column);
energyTrajectoryLine.setStepNumber(stepNumber);
controller.notifyStepNumberAfterChanged(stepNumber, row);
break;
case 5: // integration time
Double integrationTime = (Double) tmpTableModel.getValueAt(row, column);
energyTrajectoryLine.setIntegrationTime(integrationTime);
controller.notifyIntegrationTimeAfterChanged(integrationTime, row);
break;
}
}
}