Skip to content

Commit d7f96ec

Browse files
committed
comments
Signed-off-by: sBouzols <[email protected]>
1 parent 72cdf4a commit d7f96ec

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# VSCode
22
/.vscode
33
/.settings
4+
/**/.settings
45
.classpath
56
.factorypath
67
.project

src/main/java/org/gridsuite/geodata/server/GeoDataService.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ private void prepareGeoDataForComputation(Network network, Map<String, Substatio
179179
if (geoDataForComputation.get(neighbourId) == null && !substationsToCalculate.contains(neighbourId)) {
180180
substationsToCalculate.add(neighbourId);
181181
Substation sub = network.getSubstation(neighbourId);
182-
if (sub != null) { // comes from a Request param string, could not exists in the network
182+
if (sub != null) { // neighbours comes from a Request param string, could not exists in the network
183183
substations.add(sub);
184184
} else {
185185
LOGGER.debug("{} substation doesn't exist in the newtwork, will be ignored.", neighbourId);
@@ -288,7 +288,7 @@ private void step(Step step, Network network, Map<String, Set<String>> sortedNei
288288
for (Iterator<String> it = substationsToCalculate.iterator(); it.hasNext();) {
289289
String substationId = it.next();
290290
Set<String> neighbours = sortedNeighbours.get(substationId);
291-
if (neighbours != null) {
291+
if (neighbours != null) { // substationsToCalculate comes from a Request param string, could not exists in the network
292292
double neighborhoodOffset = calculatedSubstationsOffset.get(neighbours) != null ? nextNeighborhoodOffset(calculatedSubstationsOffset.get(neighbours)) : 0;
293293

294294
// centroid calculation
@@ -545,7 +545,7 @@ public List<LineGeoData> getLinesByIds(Network network, Set<String> linesIds) {
545545

546546
linesIds.forEach(id -> {
547547
Line line = network.getLine(id);
548-
if (line != null) { // comes from a Request param string, could not exists in the network
548+
if (line != null) { // linesIds comes from a Request param string, could not exists in the network
549549
lines.add(line);
550550
} else {
551551
LOGGER.debug("{} line doesn't exist in the newtwork, will be ignored.", id);

0 commit comments

Comments
 (0)