Skip to content
Snippets Groups Projects
Commit a9f13dbc authored by FrankR's avatar FrankR
Browse files

small changes

parent ee07d272
No related branches found
No related tags found
No related merge requests found
...@@ -79,17 +79,16 @@ public class Administration { ...@@ -79,17 +79,16 @@ public class Administration {
* Function recursively transforms a placing into a ROOT-placing. In each step the placing * Function recursively transforms a placing into a ROOT-placing. In each step the placing
* is transformed in a placing of the SRS that the origin of its current SRS has been defined * is transformed in a placing of the SRS that the origin of its current SRS has been defined
* in. Recursion is stopped after obtaining a ROOT-placing. * in. Recursion is stopped after obtaining a ROOT-placing.
* @param placing * @param placingToBeTransformed
*/ */
public static void transformToRootCoordinates(Placing placing) { public static void transformToRootCoordinates(Placing placingToBeTransformed) {
if (isNotRootPosition(placing.getPosition())) { if (isNotRootPosition(placingToBeTransformed.getPosition())) {
Position positionToBeTransformed = placing.getPosition(); ReferenceSystem nextTransformationGoal_SRS = placingToBeTransformed.getPosition().getReferenceSystem().getOrigin().getPosition().getReferenceSystem();
ReferenceSystem nextTransformationGoal_SRS = positionToBeTransformed.getReferenceSystem().getOrigin().getPosition().getReferenceSystem(); LOG.info("INDFRO-DEBUG: (before) ReferenceSystem: " + placingToBeTransformed.getPosition().getReferenceSystem().getId() + "; Position: " + PositionMonitoring.logPosition(placingToBeTransformed));
LOG.info("INDFRO-DEBUG: (before) ReferenceSystem: " + positionToBeTransformed.getReferenceSystem().getId() + "; Position: " + PositionMonitoring.logPosition(placing)); SRSConversion.switchSRS(placingToBeTransformed, nextTransformationGoal_SRS); // assumption: not only position is changed but also ReferenceSystem-object is updated
SRSConversion.switchSRS(positionToBeTransformed, nextTransformationGoal_SRS); // assumption: not only position is changed but also ReferenceSystem-object is updated LOG.info("INDFRO-DEBUG: (after) ReferenceSystem: " + placingToBeTransformed.getPosition().getReferenceSystem().getId() + "; Position: " + PositionMonitoring.logPosition(placingToBeTransformed));
LOG.info("INDFRO-DEBUG: (after) ReferenceSystem: " + positionToBeTransformed.getReferenceSystem().getId() + "; Position: " + PositionMonitoring.logPosition(placing));
LOG.info("INDFRO-DEBUG:"); LOG.info("INDFRO-DEBUG:");
transformToRootCoordinates(placing); // recursion stops when placing.getPosition() has been transformed in a ROOT-position transformToRootCoordinates(placingToBeTransformed); // recursion stops when placing.getPosition() has been transformed in a ROOT-position
} }
} }
...@@ -175,9 +174,9 @@ public class Administration { ...@@ -175,9 +174,9 @@ public class Administration {
private static void transformPlacingSuccessively(Placing placingToBeTransformed, List<ReferenceSystem> transformationTargets) { private static void transformPlacingSuccessively(Placing placingToBeTransformed, List<ReferenceSystem> transformationTargets) {
for (ReferenceSystem transTarget : transformationTargets){ for (ReferenceSystem transTarget : transformationTargets){
LOG.info("INDFRO-DEBUG: (before) ReferenceSystem: " + positionToBeTransformed.getReferenceSystem().getId() + "; Position: " + PositionMonitoring.logPosition(placing)); LOG.info("INDFRO-DEBUG: (before) ReferenceSystem: " + placingToBeTransformed.getPosition().getReferenceSystem().getId() + "; Position: " + PositionMonitoring.logPosition(placingToBeTransformed));
SRSConversion.switchSRS(placingToBeTransformed, transTarget); SRSConversion.switchSRS(placingToBeTransformed, transTarget);
LOG.info("INDFRO-DEBUG: (after) ReferenceSystem: " + positionToBeTransformed.getReferenceSystem().getId() + "; Position: " + PositionMonitoring.logPosition(placing)); LOG.info("INDFRO-DEBUG: (after) ReferenceSystem: " + placingToBeTransformed.getPosition().getReferenceSystem().getId() + "; Position: " + PositionMonitoring.logPosition(placingToBeTransformed));
} }
} }
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment