* @return the updated config. It may be another instance entirely.
*/
public static void computeEndPositionChange(ITrajectoryEnergy trajectory, boolean deltaLock) {
ITrajectoryEnergy trajectoryImpl = (ITrajectoryEnergy) AutoCopier.toImpl(trajectory);
TrajectoryEnergyImpl result = (TrajectoryEnergyImpl) ConfigScanEnergyApi
.computeEndPositionChange(trajectoryImpl, deltaLock);
swapTrajectory(trajectoryImpl, trajectoryImpl);
}