if (config != null) {
IDimensionEnergy dimensionEnergy = config.getDimensionX();
List<IActuator> actuatorsList = dimensionEnergy.getActuatorsList();
if (actuatorsList.size() != 0) {
IActuator actuator = actuatorsList.get(0);
IRangeEnergy rangeEnergy = createRange(dimensionEnergy);
ITrajectoryEnergy trajectoryEnergy = createTrajectory(rangeEnergy, actuator);
List<ITrajectory> trajectoriesList = rangeEnergy.getTrajectoriesList();
if (trajectoriesList == null) {
trajectoriesList = new ArrayList<ITrajectory>();
rangeEnergy.setTrajectoriesList(trajectoriesList);
}
rangeEnergy.getTrajectoriesList().add(trajectoryEnergy);
dimensionEnergy.getRangesEnergyList().add(rangeEnergy);
}
}
refresh();
}