diff --git a/src/main/java/org/gridsuite/network/map/dto/definition/extension/ConnectablePositionInfos.java b/src/main/java/org/gridsuite/network/map/dto/definition/extension/ConnectablePositionInfos.java index d40f37a6..29af5a6b 100644 --- a/src/main/java/org/gridsuite/network/map/dto/definition/extension/ConnectablePositionInfos.java +++ b/src/main/java/org/gridsuite/network/map/dto/definition/extension/ConnectablePositionInfos.java @@ -1,3 +1,9 @@ +/** + * Copyright (c) 2024, RTE (http://www.rte-france.com) + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + */ package org.gridsuite.network.map.dto.definition.extension; import com.fasterxml.jackson.annotation.JsonInclude; diff --git a/src/main/java/org/gridsuite/network/map/dto/definition/voltagelevel/FeederBayInfos.java b/src/main/java/org/gridsuite/network/map/dto/definition/voltagelevel/FeederBayInfos.java new file mode 100644 index 00000000..c14dbcb5 --- /dev/null +++ b/src/main/java/org/gridsuite/network/map/dto/definition/voltagelevel/FeederBayInfos.java @@ -0,0 +1,15 @@ +/** + * Copyright (c) 2025, RTE (http://www.rte-france.com) + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + */ +package org.gridsuite.network.map.dto.definition.voltagelevel; + +import com.powsybl.iidm.network.ThreeSides; +import org.gridsuite.network.map.dto.definition.extension.ConnectablePositionInfos; + +/** + * @author Etienne Lesot + */ +public record FeederBayInfos(String busbarSectionId, ConnectablePositionInfos connectablePositionInfos, ThreeSides connectionSide) { } diff --git a/src/main/java/org/gridsuite/network/map/dto/definition/voltagelevel/VoltageLevelFormInfos.java b/src/main/java/org/gridsuite/network/map/dto/definition/voltagelevel/VoltageLevelFormInfos.java index ac1ce76b..9ede0d8b 100644 --- a/src/main/java/org/gridsuite/network/map/dto/definition/voltagelevel/VoltageLevelFormInfos.java +++ b/src/main/java/org/gridsuite/network/map/dto/definition/voltagelevel/VoltageLevelFormInfos.java @@ -59,4 +59,7 @@ public class VoltageLevelFormInfos extends ElementInfosWithProperties { @JsonInclude(JsonInclude.Include.NON_NULL) private Map> busBarSectionInfos; + + @JsonInclude(JsonInclude.Include.NON_NULL) + private Map> feederBaysInfos; } diff --git a/src/main/java/org/gridsuite/network/map/dto/mapper/VoltageLevelInfosMapper.java b/src/main/java/org/gridsuite/network/map/dto/mapper/VoltageLevelInfosMapper.java index ac038533..2f77b029 100644 --- a/src/main/java/org/gridsuite/network/map/dto/mapper/VoltageLevelInfosMapper.java +++ b/src/main/java/org/gridsuite/network/map/dto/mapper/VoltageLevelInfosMapper.java @@ -14,6 +14,7 @@ import org.gridsuite.network.map.dto.ElementInfos; import org.gridsuite.network.map.dto.InfoTypeParameters; import org.gridsuite.network.map.dto.definition.busbarsection.BusBarSectionFormInfos; +import org.gridsuite.network.map.dto.definition.voltagelevel.FeederBayInfos; import org.gridsuite.network.map.dto.definition.voltagelevel.VoltageLevelFormInfos; import org.gridsuite.network.map.dto.definition.voltagelevel.VoltageLevelMapInfos; import org.gridsuite.network.map.dto.definition.voltagelevel.VoltageLevelTabInfos; @@ -23,6 +24,7 @@ import java.util.*; import java.util.stream.Collectors; +import static com.powsybl.iidm.network.Terminal.getConnectableSide; import static org.gridsuite.network.map.dto.utils.ElementUtils.*; /** @@ -106,6 +108,7 @@ static VoltageLevelFormInfos toFormInfos(Identifiable identifiable) { builder.isRetrievedBusbarSections(vlTopologyInfos.isRetrievedBusbarSections()); builder.isBusbarSectionPositionFound(vlTopologyInfos.isBusbarSectionPositionFound()); builder.busBarSectionInfos(vlTopologyInfos.getBusBarSectionInfosGrouped()); + builder.feederBaysInfos(getFeederBaysInfos(voltageLevel)); } builder.identifiableShortCircuit(ExtensionUtils.toIdentifiableShortCircuit(voltageLevel)); @@ -113,7 +116,29 @@ static VoltageLevelFormInfos toFormInfos(Identifiable identifiable) { return builder.build(); } - static VoltageLevelMapInfos toMapInfos(Identifiable identifiable) { + private static Map> getFeederBaysInfos(VoltageLevel voltageLevel) { + Map> feederBayInfos = new HashMap<>(); + String currentVoltageLevelId = voltageLevel.getId(); + voltageLevel.getConnectableStream() + .filter(connectable -> !(connectable instanceof BusbarSection)) + .forEach(connectable -> { + List connections = new ArrayList<>(); + for (Object obj : connectable.getTerminals()) { + Terminal terminal = (Terminal) obj; + if (terminal.getVoltageLevel().getId().equals(currentVoltageLevelId)) { + connections.add(new FeederBayInfos( + getBusOrBusbarSection(terminal), + getConnectablePosition(connectable, getConnectableSide(terminal).map(ThreeSides::getNum).orElse(0)), + getConnectableSide(terminal).orElse(null) + )); + } + } + feederBayInfos.put(connectable.getId(), connections); + }); + return feederBayInfos; + } + + protected static VoltageLevelMapInfos toMapInfos(Identifiable identifiable) { VoltageLevel voltageLevel = (VoltageLevel) identifiable; return VoltageLevelMapInfos.builder() .id(voltageLevel.getId()) diff --git a/src/main/java/org/gridsuite/network/map/dto/utils/ElementUtils.java b/src/main/java/org/gridsuite/network/map/dto/utils/ElementUtils.java index acb483b2..c1ddc791 100644 --- a/src/main/java/org/gridsuite/network/map/dto/utils/ElementUtils.java +++ b/src/main/java/org/gridsuite/network/map/dto/utils/ElementUtils.java @@ -7,12 +7,14 @@ package org.gridsuite.network.map.dto.utils; import com.powsybl.iidm.network.*; +import com.powsybl.iidm.network.extensions.ConnectablePosition; import com.powsybl.math.graph.TraversalType; +import lombok.NonNull; import org.gridsuite.network.map.dto.common.ReactiveCapabilityCurveMapData; import org.gridsuite.network.map.dto.common.TapChangerData; import org.gridsuite.network.map.dto.common.TapChangerStepData; import org.gridsuite.network.map.dto.definition.extension.BusbarSectionFinderTraverser; -import org.springframework.lang.NonNull; +import org.gridsuite.network.map.dto.definition.extension.ConnectablePositionInfos; import java.util.Collection; import java.util.List; @@ -39,6 +41,39 @@ public static void setIfNotNan(@NonNull final DoubleConsumer setter, final doubl } } + private static ConnectablePosition.Feeder getFeederInfos(Identifiable identifiable, int index) { + var connectablePosition = identifiable.getExtension(ConnectablePosition.class); + if (connectablePosition == null) { + return null; + } + + switch (index) { + case 0: + return connectablePosition.getFeeder(); + case 1: + return connectablePosition.getFeeder1(); + case 2: + return connectablePosition.getFeeder2(); + default: + throw new IllegalArgumentException("Invalid feeder index: " + index); + } + } + + public static ConnectablePositionInfos getConnectablePosition(Identifiable identifiable, int index) { + ConnectablePosition.Feeder feeder = getFeederInfos(identifiable, index); + return buildConnectablePositionInfos(feeder); + } + + public static ConnectablePositionInfos buildConnectablePositionInfos(ConnectablePosition.Feeder feeder) { + ConnectablePositionInfos.ConnectablePositionInfosBuilder builder = ConnectablePositionInfos.builder(); + if (feeder != null) { + builder.connectionDirection(feeder.getDirection() == null ? null : feeder.getDirection()) + .connectionPosition(feeder.getOrder().orElse(null)) + .connectionName(feeder.getName().orElse(null)); + } + return builder.build(); + } + public static String getBusOrBusbarSection(Terminal terminal) { if (terminal.getVoltageLevel().getTopologyKind().equals(TopologyKind.BUS_BREAKER)) { if (terminal.isConnected()) { diff --git a/src/main/java/org/gridsuite/network/map/dto/utils/ExtensionUtils.java b/src/main/java/org/gridsuite/network/map/dto/utils/ExtensionUtils.java index 0e977dcc..098a9da0 100644 --- a/src/main/java/org/gridsuite/network/map/dto/utils/ExtensionUtils.java +++ b/src/main/java/org/gridsuite/network/map/dto/utils/ExtensionUtils.java @@ -20,6 +20,7 @@ public static ConnectablePositionInfos toMapConnectablePosition(@NonNull final I case 0 -> connectablePosition.getFeeder(); case 1 -> connectablePosition.getFeeder1(); case 2 -> connectablePosition.getFeeder2(); + case 3 -> connectablePosition.getFeeder3(); default -> throw new IllegalArgumentException("Invalid feeder index: " + index); }) .ifPresent(feeder -> builder diff --git a/src/test/java/org/gridsuite/network/map/NetworkMapControllerTest.java b/src/test/java/org/gridsuite/network/map/NetworkMapControllerTest.java index 97cdb86c..9c7831ef 100644 --- a/src/test/java/org/gridsuite/network/map/NetworkMapControllerTest.java +++ b/src/test/java/org/gridsuite/network/map/NetworkMapControllerTest.java @@ -18,8 +18,8 @@ import com.powsybl.network.store.iidm.impl.NetworkFactoryImpl; import org.gridsuite.network.map.dto.ElementInfos.InfoType; import org.gridsuite.network.map.dto.ElementType; -import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.AfterAll; +import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.mockito.Mockito; @@ -1154,6 +1154,48 @@ void setUp() { .withDirection(ConnectablePosition.Direction.TOP).add() .add(); + // add line between vlgen4 et vlgen 5 for feederBays Infos + VoltageLevel vlgen7 = p5.newVoltageLevel() + .setId("VLGEN7") + .setNominalV(24.0) + .setHighVoltageLimit(30) + .setLowVoltageLimit(20) + .setTopologyKind(TopologyKind.NODE_BREAKER) + .add(); + vlgen7.getNodeBreakerView().newBusbarSection() + .setId("NGEN7") + .setName("NGEN7") + .setNode(0) + .add(); + createSwitch(vlgen4, "b4", SwitchKind.DISCONNECTOR, false, 0, 10); + createSwitch(vlgen4, "br11", SwitchKind.BREAKER, false, 10, 11); + createSwitch(vlgen7, "b5", SwitchKind.DISCONNECTOR, false, 0, 1); + createSwitch(vlgen7, "br21", SwitchKind.BREAKER, false, 1, 2); + network.newLine() + .setId("LINE7") + .setVoltageLevel1("VLGEN4") + .setNode1(11) + .setVoltageLevel2("VLGEN7") + .setNode2(2) + .setR(3.0) + .setX(33.0) + .setG1(0.0) + .setB1(386E-6 / 2) + .setG2(0.0) + .setB2(386E-6 / 2) + .add(); + Line line7 = network.getLine("LINE7"); + line7.newExtension(ConnectablePositionAdder.class) + .newFeeder1() + .withName("LINE7_Side_VLGEN4") + .withOrder(5) + .withDirection(ConnectablePosition.Direction.BOTTOM).add() + .newFeeder2() + .withName("LINE7_Side_VLGEN8") + .withOrder(3) + .withDirection(ConnectablePosition.Direction.TOP).add() + .add(); + // Add new variant network.getVariantManager().cloneVariant(VariantManagerConstants.INITIAL_VARIANT_ID, VARIANT_ID); network.getVariantManager().setWorkingVariant(VARIANT_ID); @@ -1184,7 +1226,6 @@ void setUp() { .withOrder(0) .withDirection(ConnectablePosition.Direction.TOP).add() .add(); - network.getVariantManager().setWorkingVariant(VariantManagerConstants.INITIAL_VARIANT_ID); // Add new variant 2 @@ -1380,7 +1421,6 @@ private void succeedingTestForElementInfosWithElementId(UUID networkUuid, String ) .andExpect(status().isOk()) .andReturn(); - JSONAssert.assertEquals(expectedJson, res.getResponse().getContentAsString(), JSONCompareMode.NON_EXTENSIBLE); } @@ -1440,7 +1480,6 @@ private void succeedingTestForElementsInfos(UUID networkUuid, String variantId, ) .andExpect(status().isOk()) .andReturn(); - JSONAssert.assertEquals(expectedJson, mvcResult.getResponse().getContentAsString(), JSONCompareMode.NON_EXTENSIBLE); } @@ -1514,7 +1553,6 @@ private void succeedingTestForEquipmentsInfos(UUID networkUuid, String variantId MvcResult mvcResult = mvc.perform(get("/v1/networks/{networkUuid}/{equipmentPath}", networkUuid, equipmentPath).queryParams(queryParams)) .andExpect(status().isOk()) .andReturn(); - JSONAssert.assertEquals(expectedJson, mvcResult.getResponse().getContentAsString(), JSONCompareMode.NON_EXTENSIBLE); } @@ -1681,10 +1719,10 @@ void shouldReturnLinesOperatingStatusData() throws Exception { @Test void shouldReturnLinesIds() throws Exception { - succeedingTestForElementsIds(NETWORK_UUID, null, List.of("NHV1_NHV2_1", "NHV1_NHV2_2", "LINE3", "LINE4").toString(), ElementType.LINE, null, null); - succeedingTestForElementsIds(NETWORK_UUID, null, List.of("NHV1_NHV2_1", "NHV1_NHV2_2", "LINE3", "LINE4").toString(), ElementType.LINE, null, List.of(24.0, 380.0)); - succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of("NHV1_NHV2_1", "NHV1_NHV2_2", "LINE3", "LINE4").toString(), ElementType.LINE, null, null); - succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of("NHV1_NHV2_1", "NHV1_NHV2_2", "LINE3", "LINE4").toString(), ElementType.LINE, null, List.of(24.0, 380.0)); + succeedingTestForElementsIds(NETWORK_UUID, null, List.of("NHV1_NHV2_1", "NHV1_NHV2_2", "LINE3", "LINE4", "LINE7").toString(), ElementType.LINE, null, null); + succeedingTestForElementsIds(NETWORK_UUID, null, List.of("NHV1_NHV2_1", "NHV1_NHV2_2", "LINE3", "LINE4", "LINE7").toString(), ElementType.LINE, null, List.of(24.0, 380.0)); + succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of("NHV1_NHV2_1", "NHV1_NHV2_2", "LINE3", "LINE4", "LINE7").toString(), ElementType.LINE, null, null); + succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of("NHV1_NHV2_1", "NHV1_NHV2_2", "LINE3", "LINE4", "LINE7").toString(), ElementType.LINE, null, List.of(24.0, 380.0)); succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of("NHV1_NHV2_1", "NHV1_NHV2_2", "LINE3").toString(), ElementType.LINE, List.of("P1"), null); succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of("NHV1_NHV2_1", "NHV1_NHV2_2", "LINE3").toString(), ElementType.LINE, List.of("P1"), List.of(24.0, 380.0)); succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of().toString(), ElementType.LINE, List.of("P1"), List.of(225.0)); @@ -2198,12 +2236,12 @@ void shouldReturnVotlageLevelsMapData() throws Exception { @Test void shouldReturnVoltageLevelsIds() throws Exception { - succeedingTestForElementsIds(NETWORK_UUID, null, List.of("VL", "VLGEN", "VLHV1", "VLHV2", "VLLOAD", "VLNEW2", "VLGEN3", "VLGEN4", "VLGEN5", "VLGEN6").toString(), ElementType.VOLTAGE_LEVEL, null, null); - succeedingTestForElementsIds(NETWORK_UUID, null, List.of("VL", "VLGEN", "VLHV1", "VLHV2", "VLLOAD", "VLNEW2", "VLGEN3", "VLGEN4", "VLGEN5", "VLGEN6").toString(), ElementType.VOLTAGE_LEVEL, null, List.of(24.0, 150.0, 225.0, 380.0)); - succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of("VL", "VLGEN", "VLHV1", "VLHV2", "VLLOAD", "VLNEW2", "VLGEN3", "VLGEN4", "VLGEN5", "VLGEN6").toString(), ElementType.VOLTAGE_LEVEL, null, null); - succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of("VL", "VLGEN", "VLHV1", "VLHV2", "VLLOAD", "VLNEW2", "VLGEN3", "VLGEN4", "VLGEN5", "VLGEN6").toString(), ElementType.VOLTAGE_LEVEL, null, List.of(24.0, 150.0, 225.0, 380.0)); - succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of("VLGEN", "VLHV1", "VLHV2", "VLLOAD", "VLNEW2", "VLGEN3", "VLGEN4", "VLGEN5", "VLGEN6").toString(), ElementType.VOLTAGE_LEVEL, List.of("P1", "P2", "P3", "P4", "P5", "P6"), null); - succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of("VLGEN", "VLHV1", "VLHV2", "VLLOAD", "VLNEW2", "VLGEN3", "VLGEN4", "VLGEN5", "VLGEN6").toString(), ElementType.VOLTAGE_LEVEL, List.of("P1", "P2", "P3", "P4", "P5", "P6"), List.of(24.0, 150.0, 225.0, 380.0)); + succeedingTestForElementsIds(NETWORK_UUID, null, List.of("VL", "VLGEN", "VLHV1", "VLHV2", "VLLOAD", "VLNEW2", "VLGEN3", "VLGEN4", "VLGEN5", "VLGEN6", "VLGEN7").toString(), ElementType.VOLTAGE_LEVEL, null, null); + succeedingTestForElementsIds(NETWORK_UUID, null, List.of("VL", "VLGEN", "VLHV1", "VLHV2", "VLLOAD", "VLNEW2", "VLGEN3", "VLGEN4", "VLGEN5", "VLGEN6", "VLGEN7").toString(), ElementType.VOLTAGE_LEVEL, null, List.of(24.0, 150.0, 225.0, 380.0)); + succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of("VL", "VLGEN", "VLHV1", "VLHV2", "VLLOAD", "VLNEW2", "VLGEN3", "VLGEN4", "VLGEN5", "VLGEN6", "VLGEN7").toString(), ElementType.VOLTAGE_LEVEL, null, null); + succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of("VL", "VLGEN", "VLHV1", "VLHV2", "VLLOAD", "VLNEW2", "VLGEN3", "VLGEN4", "VLGEN5", "VLGEN6", "VLGEN7").toString(), ElementType.VOLTAGE_LEVEL, null, List.of(24.0, 150.0, 225.0, 380.0)); + succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of("VLGEN", "VLHV1", "VLHV2", "VLLOAD", "VLNEW2", "VLGEN3", "VLGEN4", "VLGEN5", "VLGEN6", "VLGEN7").toString(), ElementType.VOLTAGE_LEVEL, List.of("P1", "P2", "P3", "P4", "P5", "P6"), null); + succeedingTestForElementsIds(NETWORK_UUID, VARIANT_ID, List.of("VLGEN", "VLHV1", "VLHV2", "VLLOAD", "VLNEW2", "VLGEN3", "VLGEN4", "VLGEN5", "VLGEN6", "VLGEN7").toString(), ElementType.VOLTAGE_LEVEL, List.of("P1", "P2", "P3", "P4", "P5", "P6"), List.of(24.0, 150.0, 225.0, 380.0)); } @Test @@ -2221,11 +2259,16 @@ void shouldReturnNotFoundInsteadOfVoltageLevelsMapData() throws Exception { } @Test - void shouldReturnVotlageLevelFormData() throws Exception { + void shouldReturnVoltageLevelFormData() throws Exception { succeedingTestForElementInfosWithElementId(NETWORK_UUID, null, ElementType.VOLTAGE_LEVEL, InfoType.FORM, "VLGEN4", resourceToString("/voltage-level-form-data.json")); succeedingTestForElementInfosWithElementId(NETWORK_UUID, VARIANT_ID, ElementType.VOLTAGE_LEVEL, InfoType.FORM, "VLGEN4", resourceToString("/voltage-level-form-data.json")); } + @Test + void shouldReturnVoltageLevelFormDataWithFeederBaysInfos() throws Exception { + succeedingTestForElementInfosWithElementId(NETWORK_UUID, null, ElementType.VOLTAGE_LEVEL, InfoType.FORM, "VLGEN5", resourceToString("/voltage-level-form-data-feederbays.json")); + } + @Test void shouldReturnVotlageLevelNonSymmetricalBusbarsFormData() throws Exception { succeedingTestForElementInfosWithElementId(NETWORK_UUID, null, ElementType.VOLTAGE_LEVEL, InfoType.FORM, "VLGEN5", resourceToString("/voltage-level-non-symmetrical-busbars-form-data.json")); diff --git a/src/test/resources/all-data-in-variant.json b/src/test/resources/all-data-in-variant.json index 97b24cf9..e643666e 100644 --- a/src/test/resources/all-data-in-variant.json +++ b/src/test/resources/all-data-in-variant.json @@ -115,6 +115,14 @@ { "id": "P5", "voltageLevels": [ + { + "id": "VLGEN7", + "substationId": "P5", + "nominalV": 24.0, + "country": "FR", + "lowVoltageLimit": 20.0, + "highVoltageLimit": 30.0 + }, { "id": "VLGEN5", "substationId": "P5", @@ -219,6 +227,14 @@ "ipMin": 0.0, "ipMax": 100.0 } + }, + { + "id": "VLGEN7", + "substationId": "P5", + "nominalV": 24.0, + "country": "FR", + "lowVoltageLimit": 20.0, + "highVoltageLimit": 30.0 } ], "lines": [ @@ -502,6 +518,26 @@ "b1": 1.93E-4, "g2": 0.0, "b2": 1.93E-4 + }, + { + "id": "LINE7", + "type": "LINE", + "voltageLevelId1": "VLGEN4", + "voltageLevelId2": "VLGEN7", + "nominalVoltage1": 24.0, + "nominalVoltage2": 24.0, + "substationId1": "P4", + "substationId2": "P5", + "country1": "FR", + "country2": "FR", + "terminal1Connected": true, + "terminal2Connected": true, + "r": 3.0, + "x": 33.0, + "g1": 0.0, + "b1": 1.93E-4, + "g2": 0.0, + "b2": 1.93E-4 } ], "hvdcLines": [ @@ -2345,6 +2381,26 @@ "voltageLevelId": "VLGEN6", "nominalVoltage": 24.0, "country": "FR" + }, + { + "id": "VLGEN4_0", + "v": "NaN", + "angle": "NaN", + "synchronousComponentNum": 1, + "connectedComponentNum": 1, + "voltageLevelId": "VLGEN4", + "nominalVoltage": 24.0, + "country": "FR" + }, + { + "id": "VLGEN7_0", + "v": "NaN", + "angle": "NaN", + "synchronousComponentNum": 1, + "connectedComponentNum": 1, + "voltageLevelId": "VLGEN7", + "nominalVoltage": 24.0, + "country": "FR" } ], "busbarSections": [ @@ -2375,6 +2431,11 @@ "id": "NGEN5_2_2", "name": "NGEN5_2_2", "voltageLevelId": "VLGEN5" + }, + { + "id": "NGEN7", + "name": "NGEN7", + "voltageLevelId": "VLGEN7" } ], "branches": [ @@ -2643,6 +2704,22 @@ "Country": "FR" } }, + { + "id": "LINE7", + "type": "LINE", + "voltageLevelId1": "VLGEN4", + "voltageLevelId2": "VLGEN7", + "nominalVoltage1": 24.0, + "nominalVoltage2": 24.0, + "substationId1": "P4", + "substationId2": "P5", + "country1": "FR", + "country2": "FR", + "terminal1Connected": true, + "terminal2Connected": true, + "r": 3.0, + "x": 33.0 + }, { "id": "NGEN_NHV1", "type": "TWO_WINDINGS_TRANSFORMER", diff --git a/src/test/resources/all-data.json b/src/test/resources/all-data.json index dc639143..06c2ec42 100644 --- a/src/test/resources/all-data.json +++ b/src/test/resources/all-data.json @@ -126,6 +126,14 @@ "ipMin": 0.0, "ipMax": 100.0 } + }, + { + "id": "VLGEN7", + "substationId": "P5", + "nominalV": 24.0, + "country": "FR", + "lowVoltageLimit": 20.0, + "highVoltageLimit": 30.0 } ], "country": "FR" @@ -219,6 +227,14 @@ "ipMin": 0.0, "ipMax": 100.0 } + }, + { + "id": "VLGEN7", + "substationId": "P5", + "nominalV": 24.0, + "country": "FR", + "lowVoltageLimit": 20.0, + "highVoltageLimit": 30.0 } ], "lines": [ @@ -502,6 +518,26 @@ "b1": 1.93E-4, "g2": 0.0, "b2": 1.93E-4 + }, + { + "id": "LINE7", + "type": "LINE", + "voltageLevelId1": "VLGEN4", + "voltageLevelId2": "VLGEN7", + "nominalVoltage1": 24.0, + "nominalVoltage2": 24.0, + "substationId1": "P4", + "substationId2": "P5", + "country1": "FR", + "country2": "FR", + "terminal1Connected": true, + "terminal2Connected": true, + "r": 3.0, + "x": 33.0, + "g1": 0.0, + "b1": 1.93E-4, + "g2": 0.0, + "b2": 1.93E-4 } ], "hvdcLines": [ @@ -2333,6 +2369,16 @@ "voltageLevelId": "VLGEN4", "nominalVoltage": 24.0, "country": "FR" + }, + { + "id": "VLGEN7_0", + "v": "NaN", + "angle": "NaN", + "synchronousComponentNum": 1, + "connectedComponentNum": 1, + "voltageLevelId": "VLGEN7", + "nominalVoltage": 24.0, + "country": "FR" } ], "busbarSections": [ @@ -2363,6 +2409,11 @@ "id": "NGEN5_2_2", "name": "NGEN5_2_2", "voltageLevelId": "VLGEN5" + }, + { + "id": "NGEN7", + "name": "NGEN7", + "voltageLevelId": "VLGEN7" } ], "branches": [ @@ -2631,6 +2682,22 @@ "Country": "FR" } }, + { + "id": "LINE7", + "type": "LINE", + "voltageLevelId1": "VLGEN4", + "voltageLevelId2": "VLGEN7", + "nominalVoltage1": 24.0, + "nominalVoltage2": 24.0, + "substationId1": "P4", + "substationId2": "P5", + "country1": "FR", + "country2": "FR", + "terminal1Connected": true, + "terminal2Connected": true, + "r": 3.0, + "x": 33.0 + }, { "id": "NGEN_NHV1", "type": "TWO_WINDINGS_TRANSFORMER", @@ -2816,4 +2883,4 @@ } } ] -} \ No newline at end of file +} diff --git a/src/test/resources/bus-bar-section-form-data.json b/src/test/resources/bus-bar-section-form-data.json index 5a9a8efa..66240fc4 100644 --- a/src/test/resources/bus-bar-section-form-data.json +++ b/src/test/resources/bus-bar-section-form-data.json @@ -22,5 +22,9 @@ "name": "NGEN5_2_2", "vertPos": 2, "horizPos": 2 + }, + { + "id": "NGEN7", + "name": "NGEN7" } ] \ No newline at end of file diff --git a/src/test/resources/bus-bar-section-list-data.json b/src/test/resources/bus-bar-section-list-data.json index ce64cf17..d75cc789 100644 --- a/src/test/resources/bus-bar-section-list-data.json +++ b/src/test/resources/bus-bar-section-list-data.json @@ -14,5 +14,9 @@ { "id": "NGEN5_2_2", "name": "NGEN5_2_2" + }, + { + "id": "NGEN7", + "name": "NGEN7" } ] \ No newline at end of file diff --git a/src/test/resources/bus-bar-section-operating-status-data.json b/src/test/resources/bus-bar-section-operating-status-data.json index 77ffd3f6..902a6f1a 100644 --- a/src/test/resources/bus-bar-section-operating-status-data.json +++ b/src/test/resources/bus-bar-section-operating-status-data.json @@ -8,12 +8,16 @@ "name": "NGEN5", "operatingStatus": "FORCED_OUTAGE" }, - { + { "id": "NGEN5_2_1", "name": "NGEN5_2_1" }, { "id": "NGEN5_2_2", "name": "NGEN5_2_2" + }, + { + "id": "NGEN7", + "name": "NGEN7" } ] \ No newline at end of file diff --git a/src/test/resources/lines-form-data.json b/src/test/resources/lines-form-data.json index 45906df5..abe5bc75 100644 --- a/src/test/resources/lines-form-data.json +++ b/src/test/resources/lines-form-data.json @@ -9,7 +9,7 @@ "q1": 2.2, "p2": 3.33, "q2": 4.44, - "currentLimits1": [ + "currentLimits": [ { "id": "limit set 1", "permanentLimit": 700.4, @@ -20,10 +20,8 @@ "acceptableDuration": 300 } ], - "applicability": null - } - ], - "currentLimits2": [ + "applicability": "SIDE1" + }, { "id": "limit set 1", "permanentLimit": 800.8, @@ -39,10 +37,10 @@ "acceptableDuration": 600 } ], - "applicability": null + "applicability": "SIDE2" } ], - "currentLimits": [ + "currentLimits1": [ { "id": "limit set 1", "permanentLimit": 700.4, @@ -53,8 +51,10 @@ "acceptableDuration": 300 } ], - "applicability": "SIDE1" - }, + "applicability": null + } + ], + "currentLimits2": [ { "id": "limit set 1", "permanentLimit": 800.8, @@ -70,7 +70,7 @@ "acceptableDuration": 600 } ], - "applicability": "SIDE2" + "applicability": null } ], "selectedOperationalLimitsGroup1": "limit set 1", @@ -100,7 +100,7 @@ "voltageLevelId2": "VLHV2", "terminal1Connected": true, "terminal2Connected": true, - "currentLimits1": [ + "currentLimits": [ { "id": "group2", "permanentLimit": 250.0, @@ -111,7 +111,7 @@ "acceptableDuration": 200 } ], - "applicability": null + "applicability": "SIDE1" }, { "id": "group1", @@ -128,10 +128,8 @@ "acceptableDuration": 100 } ], - "applicability": null - } - ], - "currentLimits2": [ + "applicability": "SIDE1" + }, { "id": "group4", "permanentLimit": 320.0, @@ -142,7 +140,7 @@ "acceptableDuration": 200 } ], - "applicability": null + "applicability": "SIDE2" }, { "id": "group3", @@ -154,10 +152,10 @@ "acceptableDuration": 150 } ], - "applicability": null + "applicability": "SIDE2" } ], - "currentLimits": [ + "currentLimits1": [ { "id": "group2", "permanentLimit": 250.0, @@ -168,7 +166,7 @@ "acceptableDuration": 200 } ], - "applicability": "SIDE1" + "applicability": null }, { "id": "group1", @@ -185,8 +183,10 @@ "acceptableDuration": 100 } ], - "applicability": "SIDE1" - }, + "applicability": null + } + ], + "currentLimits2": [ { "id": "group4", "permanentLimit": 320.0, @@ -197,7 +197,7 @@ "acceptableDuration": 200 } ], - "applicability": "SIDE2" + "applicability": null }, { "id": "group3", @@ -209,10 +209,9 @@ "acceptableDuration": 150 } ], - "applicability": "SIDE2" + "applicability": null } ], - "selectedOperationalLimitsGroup1": "group1", "selectedOperationalLimitsGroup2": "group4", "r": 3.0, @@ -237,7 +236,9 @@ "voltageLevelId2": "VLGEN3", "terminal1Connected": true, "terminal2Connected": true, - "currentLimits1": [ + "p1": 200.0, + "p2": 100.0, + "currentLimits": [ { "id": "group1", "permanentLimit": 220.0, @@ -253,10 +254,10 @@ "acceptableDuration": 100 } ], - "applicability": null + "applicability": "SIDE1" } ], - "currentLimits": [ + "currentLimits1": [ { "id": "group1", "permanentLimit": 220.0, @@ -272,12 +273,10 @@ "acceptableDuration": 100 } ], - "applicability": "SIDE1" + "applicability": null } ], "selectedOperationalLimitsGroup1": "group1", - "p1": 200.0, - "p2": 100.0, "operatingStatus": "PLANNED_OUTAGE", "r": 3.0, "x": 33.0, @@ -316,7 +315,7 @@ "voltageLevelId2": "VLGEN3", "terminal1Connected": true, "terminal2Connected": true, - "currentLimits2": [ + "currentLimits": [ { "id": "group1", "permanentLimit": 220.0, @@ -332,10 +331,10 @@ "acceptableDuration": 100 } ], - "applicability": null + "applicability": "SIDE2" } ], - "currentLimits": [ + "currentLimits2": [ { "id": "group1", "permanentLimit": 220.0, @@ -351,7 +350,7 @@ "acceptableDuration": 100 } ], - "applicability": "SIDE2" + "applicability": null } ], "selectedOperationalLimitsGroup2": "group1", @@ -369,5 +368,30 @@ }, "busOrBusbarSectionId1": "NGEN6", "busOrBusbarSectionId2": "NGEN3" + }, + { + "id": "LINE7", + "voltageLevelId1": "VLGEN4", + "voltageLevelId2": "VLGEN7", + "terminal1Connected": true, + "terminal2Connected": true, + "r": 3.0, + "x": 33.0, + "g1": 0.0, + "b1": 1.93E-4, + "g2": 0.0, + "b2": 1.93E-4, + "connectablePosition1": { + "connectionDirection": "BOTTOM", + "connectionPosition": 5, + "connectionName": "LINE7_Side_VLGEN4" + }, + "connectablePosition2": { + "connectionDirection": "TOP", + "connectionPosition": 3, + "connectionName": "LINE7_Side_VLGEN8" + }, + "busOrBusbarSectionId1": "NGEN4", + "busOrBusbarSectionId2": "NGEN7" } ] \ No newline at end of file diff --git a/src/test/resources/lines-list-data.json b/src/test/resources/lines-list-data.json index 22dbe3b8..4be80a8a 100644 --- a/src/test/resources/lines-list-data.json +++ b/src/test/resources/lines-list-data.json @@ -10,5 +10,8 @@ }, { "id": "LINE4" + }, + { + "id": "LINE7" } -] +] \ No newline at end of file diff --git a/src/test/resources/lines-map-data.json b/src/test/resources/lines-map-data.json index 28836e21..860959f8 100644 --- a/src/test/resources/lines-map-data.json +++ b/src/test/resources/lines-map-data.json @@ -32,5 +32,12 @@ "voltageLevelId2": "VLGEN3", "terminal1Connected": true, "terminal2Connected": true + }, + { + "id": "LINE7", + "voltageLevelId1": "VLGEN4", + "voltageLevelId2": "VLGEN7", + "terminal1Connected": true, + "terminal2Connected": true } ] \ No newline at end of file diff --git a/src/test/resources/lines-operating-status-data.json b/src/test/resources/lines-operating-status-data.json index 0d655cd7..b80b9aa8 100644 --- a/src/test/resources/lines-operating-status-data.json +++ b/src/test/resources/lines-operating-status-data.json @@ -15,12 +15,12 @@ }, { "id": "LINE3", + "operatingStatus": "PLANNED_OUTAGE", "voltageLevelId1": "VLGEN", "voltageLevelName1": "VLGEN_Name", "voltageLevelId2": "VLGEN3", "terminal1Connected": true, - "terminal2Connected": true, - "operatingStatus": "PLANNED_OUTAGE" + "terminal2Connected": true }, { "id": "LINE4", @@ -28,5 +28,12 @@ "voltageLevelId2": "VLGEN3", "terminal1Connected": true, "terminal2Connected": true + }, + { + "id": "LINE7", + "voltageLevelId1": "VLGEN4", + "voltageLevelId2": "VLGEN7", + "terminal1Connected": true, + "terminal2Connected": true } -] +] \ No newline at end of file diff --git a/src/test/resources/substations-form-data.json b/src/test/resources/substations-form-data.json index 5b243e3e..1bfcc78f 100644 --- a/src/test/resources/substations-form-data.json +++ b/src/test/resources/substations-form-data.json @@ -1,9 +1,4 @@ [ - { - "id": "P0", - "country": "FR", - "voltageLevels": [] - }, { "id": "P1", "name": "P1_Name", @@ -14,18 +9,18 @@ "voltageLevels": [ { "id": "VLGEN", + "name": "VLGEN_Name", + "properties": { + "Country": "FR" + }, "topologyKind": "BUS_BREAKER", "substationId": "P1", "nominalV": 24.0, - "name": "VLGEN_Name", "lowVoltageLimit": 200.0, "highVoltageLimit": 400.0, "identifiableShortCircuit": { "ipMin": 10.0, "ipMax": 120.0 - }, - "properties": { - "Country": "FR" } }, { @@ -36,12 +31,12 @@ }, { "id": "VLNEW2", - "topologyKind": "BUS_BREAKER", - "substationId": "P1", - "nominalV": 225.0, "properties": { "Country": "FR" - } + }, + "topologyKind": "BUS_BREAKER", + "substationId": "P1", + "nominalV": 225.0 } ] }, @@ -62,6 +57,11 @@ } ] }, + { + "id": "P0", + "country": "FR", + "voltageLevels": [] + }, { "id": "P3", "properties": { @@ -100,11 +100,46 @@ "nominalV": 24.0, "busbarCount": 1, "sectionCount": 2, - "switchKinds": ["DISCONNECTOR"], + "switchKinds": [ + "DISCONNECTOR" + ], "isRetrievedBusbarSections": true, "isBusbarSectionPositionFound": true, - "busBarSectionInfos" : { - "1" : ["NGEN4"] + "busBarSectionInfos": { + "1": [ + "NGEN4" + ] + }, + "feederBaysInfos": { + "SHUNT_VLNB": [ + { + "busbarSectionId": "NGEN4", + "connectablePositionInfos": { + "connectionDirection": null + }, + "connectionSide": null + } + ], + "LINE7": [ + { + "busbarSectionId": "NGEN4", + "connectablePositionInfos": { + "connectionDirection": "BOTTOM", + "connectionPosition": 5, + "connectionName": "LINE7_Side_VLGEN4" + }, + "connectionSide": "ONE" + } + ], + "SHUNT_NON_LINEAR": [ + { + "busbarSectionId": null, + "connectablePositionInfos": { + "connectionDirection": null + }, + "connectionSide": null + } + ] } } ] @@ -129,9 +164,42 @@ "switchKinds": [], "isRetrievedBusbarSections": false, "isBusbarSectionPositionFound": true, - "busBarSectionInfos" : { - "1" : [ "NGEN5"], - "2" : [ "NGEN5_2_1", "NGEN5_2_2"] + "busBarSectionInfos": { + "1": [ + "NGEN5" + ], + "2": [ + "NGEN5_2_1", + "NGEN5_2_2" + ] + }, + "feederBaysInfos": {} + }, + { + "id": "VLGEN7", + "topologyKind": "NODE_BREAKER", + "substationId": "P5", + "nominalV": 24.0, + "lowVoltageLimit": 20.0, + "highVoltageLimit": 30.0, + "busbarCount": 1, + "sectionCount": 1, + "switchKinds": [], + "isRetrievedBusbarSections": false, + "isBusbarSectionPositionFound": false, + "busBarSectionInfos": {}, + "feederBaysInfos": { + "LINE7": [ + { + "busbarSectionId": "NGEN7", + "connectablePositionInfos": { + "connectionDirection": "TOP", + "connectionPosition": 3, + "connectionName": "LINE7_Side_VLGEN8" + }, + "connectionSide": "TWO" + } + ] } } ] diff --git a/src/test/resources/substations-map-data.json b/src/test/resources/substations-map-data.json index 59c61307..a2302382 100644 --- a/src/test/resources/substations-map-data.json +++ b/src/test/resources/substations-map-data.json @@ -4,20 +4,20 @@ "name": "P1_Name", "voltageLevels": [ { - "id": "VLGEN", + "id": "VLNEW2", "substationId": "P1", - "nominalV": 24.0, - "name": "VLGEN_Name" + "nominalV": 225.0 }, { - "id": "VLHV1", + "id": "VLGEN", + "name": "VLGEN_Name", "substationId": "P1", - "nominalV": 380.0 + "nominalV": 24.0 }, { - "id": "VLNEW2", + "id": "VLHV1", "substationId": "P1", - "nominalV": 225.0 + "nominalV": 380.0 } ] }, @@ -47,31 +47,36 @@ ] }, { - "id": "P4", + "id": "P6", "voltageLevels": [ { - "id": "VLGEN4", - "substationId": "P4", + "id": "VLGEN6", + "substationId": "P6", "nominalV": 24.0 } ] }, { - "id": "P5", + "id": "P4", "voltageLevels": [ { - "id": "VLGEN5", - "substationId": "P5", + "id": "VLGEN4", + "substationId": "P4", "nominalV": 24.0 } ] }, { - "id": "P6", + "id": "P5", "voltageLevels": [ { - "id": "VLGEN6", - "substationId": "P6", + "id": "VLGEN7", + "substationId": "P5", + "nominalV": 24.0 + }, + { + "id": "VLGEN5", + "substationId": "P5", "nominalV": 24.0 } ] diff --git a/src/test/resources/substations-map-data_without_vl.json b/src/test/resources/substations-map-data_without_vl.json index 9502c827..462a22b1 100644 --- a/src/test/resources/substations-map-data_without_vl.json +++ b/src/test/resources/substations-map-data_without_vl.json @@ -5,9 +5,9 @@ "voltageLevels": [ { "id": "VLGEN", + "name": "VLGEN_Name", "substationId": "P1", - "nominalV": 24.0, - "name": "VLGEN_Name" + "nominalV": 24.0 }, { "id": "VLHV1", @@ -50,6 +50,16 @@ } ] }, + { + "id": "P6", + "voltageLevels": [ + { + "id": "VLGEN6", + "substationId": "P6", + "nominalV": 24.0 + } + ] + }, { "id": "P4", "voltageLevels": [ @@ -67,15 +77,10 @@ "id": "VLGEN5", "substationId": "P5", "nominalV": 24.0 - } - ] - }, - { - "id": "P6", - "voltageLevels": [ + }, { - "id": "VLGEN6", - "substationId": "P6", + "id": "VLGEN7", + "substationId": "P5", "nominalV": 24.0 } ] diff --git a/src/test/resources/substations-tab-data.json b/src/test/resources/substations-tab-data.json index f3b52a69..5e8ba82d 100644 --- a/src/test/resources/substations-tab-data.json +++ b/src/test/resources/substations-tab-data.json @@ -1,9 +1,4 @@ [ - { - "id": "P0", - "voltageLevels": [], - "country": "FR" - }, { "id": "P1", "name": "P1_Name", @@ -13,19 +8,19 @@ "voltageLevels": [ { "id": "VLGEN", + "name": "VLGEN_Name", + "properties": { + "Country": "FR" + }, "substationId": "P1", "nominalV": 24.0, "country": "FR", - "name": "VLGEN_Name", "lowVoltageLimit": 200.0, "highVoltageLimit": 400.0, "identifiableShortCircuit": { "ipMin": 10.0, "ipMax": 120.0 }, - "properties": { - "Country": "FR" - }, "substationProperties": { "Country": "FR" } @@ -41,12 +36,12 @@ }, { "id": "VLNEW2", - "substationId": "P1", - "nominalV": 225.0, - "country": "FR", "properties": { "Country": "FR" }, + "substationId": "P1", + "nominalV": 225.0, + "country": "FR", "substationProperties": { "Country": "FR" } @@ -69,6 +64,11 @@ } ] }, + { + "id": "P0", + "voltageLevels": [], + "country": "FR" + }, { "id": "P3", "properties": { @@ -125,6 +125,14 @@ "ipMin": 0.0, "ipMax": 100.0 } + }, + { + "id": "VLGEN7", + "substationId": "P5", + "nominalV": 24.0, + "country": "FR", + "lowVoltageLimit": 20.0, + "highVoltageLimit": 30.0 } ], "country": "FR" diff --git a/src/test/resources/switches-data-in-variant.json b/src/test/resources/switches-data-in-variant.json index e6a9eb9a..f5eae0c7 100644 --- a/src/test/resources/switches-data-in-variant.json +++ b/src/test/resources/switches-data-in-variant.json @@ -3,8 +3,16 @@ "id": "VL4_BBS_SHUNT_DISCONNECTOR", "open": false }, + { + "id": "b4", + "open": false + }, { "id": "VL4_SHUNT_BREAKER", "open": true + }, + { + "id": "br11", + "open": false } ] \ No newline at end of file diff --git a/src/test/resources/switches-data.json b/src/test/resources/switches-data.json index 2848d225..af40ffad 100644 --- a/src/test/resources/switches-data.json +++ b/src/test/resources/switches-data.json @@ -6,5 +6,13 @@ { "id": "VL4_SHUNT_BREAKER", "open": false + }, + { + "id": "b4", + "open": false + }, + { + "id": "br11", + "open": false } ] \ No newline at end of file diff --git a/src/test/resources/voltage-level-form-data-feederbays.json b/src/test/resources/voltage-level-form-data-feederbays.json new file mode 100644 index 00000000..5c2833b7 --- /dev/null +++ b/src/test/resources/voltage-level-form-data-feederbays.json @@ -0,0 +1,27 @@ +{ + "id": "VLGEN5", + "topologyKind": "NODE_BREAKER", + "substationId": "P5", + "nominalV": 24.0, + "lowVoltageLimit": 20.0, + "highVoltageLimit": 30.0, + "identifiableShortCircuit": { + "ipMin": 0.0, + "ipMax": 100.0 + }, + "busbarCount": 1, + "sectionCount": 1, + "switchKinds": [], + "isRetrievedBusbarSections": false, + "isBusbarSectionPositionFound": true, + "busBarSectionInfos": { + "1": [ + "NGEN5" + ], + "2": [ + "NGEN5_2_1", + "NGEN5_2_2" + ] + }, + "feederBaysInfos": {} +} \ No newline at end of file diff --git a/src/test/resources/voltage-level-form-data.json b/src/test/resources/voltage-level-form-data.json index f41d6921..e6cfd78a 100644 --- a/src/test/resources/voltage-level-form-data.json +++ b/src/test/resources/voltage-level-form-data.json @@ -1,14 +1,49 @@ { "id": "VLGEN4", + "topologyKind": "NODE_BREAKER", "substationId": "P4", "nominalV": 24.0, - "topologyKind": "NODE_BREAKER", "busbarCount": 1, "sectionCount": 2, - "switchKinds": ["DISCONNECTOR"], + "switchKinds": [ + "DISCONNECTOR" + ], "isRetrievedBusbarSections": true, "isBusbarSectionPositionFound": true, - "busBarSectionInfos" : { - "1" : [ "NGEN4"] + "busBarSectionInfos": { + "1": [ + "NGEN4" + ] + }, + "feederBaysInfos": { + "SHUNT_VLNB": [ + { + "busbarSectionId": "NGEN4", + "connectablePositionInfos": { + "connectionDirection": null + }, + "connectionSide": null + } + ], + "LINE7": [ + { + "busbarSectionId": "NGEN4", + "connectablePositionInfos": { + "connectionDirection": "BOTTOM", + "connectionPosition": 5, + "connectionName": "LINE7_Side_VLGEN4" + }, + "connectionSide": "ONE" + } + ], + "SHUNT_NON_LINEAR": [ + { + "busbarSectionId": null, + "connectablePositionInfos": { + "connectionDirection": null + }, + "connectionSide": null + } + ] } -} +} \ No newline at end of file diff --git a/src/test/resources/voltage-level-non-symmetrical-busbars-form-data.json b/src/test/resources/voltage-level-non-symmetrical-busbars-form-data.json index b17ebcad..5c2833b7 100644 --- a/src/test/resources/voltage-level-non-symmetrical-busbars-form-data.json +++ b/src/test/resources/voltage-level-non-symmetrical-busbars-form-data.json @@ -14,8 +14,14 @@ "switchKinds": [], "isRetrievedBusbarSections": false, "isBusbarSectionPositionFound": true, - "busBarSectionInfos" : { - "1" : [ "NGEN5"], - "2" : [ "NGEN5_2_1","NGEN5_2_2"] - } -} + "busBarSectionInfos": { + "1": [ + "NGEN5" + ], + "2": [ + "NGEN5_2_1", + "NGEN5_2_2" + ] + }, + "feederBaysInfos": {} +} \ No newline at end of file diff --git a/src/test/resources/voltage-levels-form-data.json b/src/test/resources/voltage-levels-form-data.json index f9b3b33b..143878b1 100644 --- a/src/test/resources/voltage-levels-form-data.json +++ b/src/test/resources/voltage-levels-form-data.json @@ -1,75 +1,117 @@ [ - { - "id": "VL", - "name":"VL", - "nominalV": 24.0, - "topologyKind": "BUS_BREAKER" - }, { "id": "VLGEN", + "name": "VLGEN_Name", + "properties": { + "Country": "FR" + }, + "topologyKind": "BUS_BREAKER", "substationId": "P1", "nominalV": 24.0, - "topologyKind": "BUS_BREAKER", - "name": "VLGEN_Name", "lowVoltageLimit": 200.0, "highVoltageLimit": 400.0, "identifiableShortCircuit": { "ipMin": 10.0, "ipMax": 120.0 - }, - "properties": { - "Country": "FR" } }, { "id": "VLHV1", + "topologyKind": "BUS_BREAKER", "substationId": "P1", - "nominalV": 380.0, - "topologyKind": "BUS_BREAKER" + "nominalV": 380.0 }, { "id": "VLHV2", + "topologyKind": "BUS_BREAKER", "substationId": "P2", - "nominalV": 380.0, - "topologyKind": "BUS_BREAKER" + "nominalV": 380.0 }, { "id": "VLLOAD", + "topologyKind": "BUS_BREAKER", "substationId": "P2", - "nominalV": 150.0, - "topologyKind": "BUS_BREAKER" + "nominalV": 150.0 }, { "id": "VLNEW2", - "substationId": "P1", - "nominalV": 225.0, - "topologyKind": "BUS_BREAKER", "properties": { "Country": "FR" - } + }, + "topologyKind": "BUS_BREAKER", + "substationId": "P1", + "nominalV": 225.0 }, { "id": "VLGEN3", + "topologyKind": "BUS_BREAKER", "substationId": "P3", - "nominalV": 24.0, - "topologyKind": "BUS_BREAKER" + "nominalV": 24.0 + }, + { + "id": "VLGEN6", + "topologyKind": "BUS_BREAKER", + "substationId": "P6", + "nominalV": 24.0 + }, + { + "id": "VL", + "name": "VL", + "topologyKind": "BUS_BREAKER", + "nominalV": 24.0 }, { "id": "VLGEN4", + "topologyKind": "NODE_BREAKER", "substationId": "P4", "nominalV": 24.0, - "topologyKind": "NODE_BREAKER", "busbarCount": 1, "sectionCount": 2, - "switchKinds": ["DISCONNECTOR"], + "switchKinds": [ + "DISCONNECTOR" + ], "isRetrievedBusbarSections": true, "isBusbarSectionPositionFound": true, - "busBarSectionInfos" : { - "1" : [ "NGEN4" ] + "busBarSectionInfos": { + "1": [ + "NGEN4" + ] + }, + "feederBaysInfos": { + "SHUNT_VLNB": [ + { + "busbarSectionId": "NGEN4", + "connectablePositionInfos": { + "connectionDirection": null + }, + "connectionSide": null + } + ], + "LINE7": [ + { + "busbarSectionId": "NGEN4", + "connectablePositionInfos": { + "connectionDirection": "BOTTOM", + "connectionPosition": 5, + "connectionName": "LINE7_Side_VLGEN4" + }, + "connectionSide": "ONE" + } + ], + "SHUNT_NON_LINEAR": [ + { + "busbarSectionId": null, + "connectablePositionInfos": { + "connectionDirection": null + }, + "connectionSide": null + } + ] } }, { "id": "VLGEN5", + "topologyKind": "NODE_BREAKER", "substationId": "P5", "nominalV": 24.0, "lowVoltageLimit": 20.0, @@ -78,21 +120,47 @@ "ipMin": 0.0, "ipMax": 100.0 }, - "topologyKind": "NODE_BREAKER", "busbarCount": 1, "sectionCount": 1, "switchKinds": [], "isRetrievedBusbarSections": false, "isBusbarSectionPositionFound": true, - "busBarSectionInfos" : { - "1" : [ "NGEN5"], - "2" : [ "NGEN5_2_1", "NGEN5_2_2" ] - } + "busBarSectionInfos": { + "1": [ + "NGEN5" + ], + "2": [ + "NGEN5_2_1", + "NGEN5_2_2" + ] + }, + "feederBaysInfos": {} }, { - "id": "VLGEN6", - "topologyKind": "BUS_BREAKER", - "substationId": "P6", - "nominalV": 24.0 + "id": "VLGEN7", + "topologyKind": "NODE_BREAKER", + "substationId": "P5", + "nominalV": 24.0, + "lowVoltageLimit": 20.0, + "highVoltageLimit": 30.0, + "busbarCount": 1, + "sectionCount": 1, + "switchKinds": [], + "isRetrievedBusbarSections": false, + "isBusbarSectionPositionFound": false, + "busBarSectionInfos": {}, + "feederBaysInfos": { + "LINE7": [ + { + "busbarSectionId": "NGEN7", + "connectablePositionInfos": { + "connectionDirection": "TOP", + "connectionPosition": 3, + "connectionName": "LINE7_Side_VLGEN8" + }, + "connectionSide": "TWO" + } + ] + } } ] \ No newline at end of file diff --git a/src/test/resources/voltage-levels-list-data.json b/src/test/resources/voltage-levels-list-data.json index 6705164a..4356f7da 100644 --- a/src/test/resources/voltage-levels-list-data.json +++ b/src/test/resources/voltage-levels-list-data.json @@ -1,11 +1,7 @@ [ - { - "id": "VL", - "name":"VL" - }, { "id": "VLGEN", - "name":"VLGEN_Name" + "name": "VLGEN_Name" }, { "id": "VLHV1" @@ -22,6 +18,13 @@ { "id": "VLGEN3" }, + { + "id": "VLGEN6" + }, + { + "id": "VL", + "name": "VL" + }, { "id": "VLGEN4" }, @@ -29,6 +32,6 @@ "id": "VLGEN5" }, { - "id": "VLGEN6" + "id": "VLGEN7" } -] +] \ No newline at end of file diff --git a/src/test/resources/voltage-levels-map-data.json b/src/test/resources/voltage-levels-map-data.json index 8f77d945..baeeac1d 100644 --- a/src/test/resources/voltage-levels-map-data.json +++ b/src/test/resources/voltage-levels-map-data.json @@ -1,14 +1,9 @@ [ - { - "id": "VL", - "name":"VL", - "nominalV": 24.0 - }, { "id": "VLGEN", + "name": "VLGEN_Name", "substationId": "P1", - "nominalV": 24.0, - "name": "VLGEN_Name" + "nominalV": 24.0 }, { "id": "VLHV1", @@ -40,6 +35,11 @@ "substationId": "P6", "nominalV": 24.0 }, + { + "id": "VL", + "name": "VL", + "nominalV": 24.0 + }, { "id": "VLGEN4", "substationId": "P4", @@ -49,5 +49,10 @@ "id": "VLGEN5", "substationId": "P5", "nominalV": 24.0 + }, + { + "id": "VLGEN7", + "substationId": "P5", + "nominalV": 24.0 } -] +] \ No newline at end of file