@enervance/insight-cim-model 0.0.59 → 0.0.61
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/converter/integral7/converter-i7.d.ts +1 -1
- package/dist/converter/integral7/converter-i7.js +36 -54
- package/dist/converter/integral7/converter-i7.js.map +1 -1
- package/dist/converter/integral7/interface-i7/IObjectMappingConfig.d.ts +4 -0
- package/dist/converter/integral7/interface-i7/export-frame-i7.js +0 -9
- package/dist/converter/integral7/interface-i7/export-frame-i7.js.map +1 -1
- package/dist/converter/integral7/utils-cgmes-export.js +0 -22
- package/dist/converter/integral7/utils-cgmes-export.js.map +1 -1
- package/dist/model/assetinfo/WireInfo.js +3 -3
- package/dist/model/dc/DCLine.js +17 -17
- package/dist/model/dc/DCLineSegment.js +25 -25
- package/dist/model/loadmodel/ConformLoad.js +33 -33
- package/dist/model/loadmodel/ConformLoadGroup.js +22 -22
- package/dist/model/loadmodel/LoadArea.js +21 -21
- package/dist/model/loadmodel/SubLoadArea.js +22 -22
- package/dist/package.json +16 -16
- package/package.json +2 -2
|
@@ -66,7 +66,7 @@ export declare class ConverterI7 {
|
|
|
66
66
|
convertKnotenLk(cimModel: Model, laengskupplungIDs: number[]): Promise<void>;
|
|
67
67
|
convertSchlaufen(cimModel: Model, integral7: Integral7Model, knotenSoIDs: number[]): Promise<void>;
|
|
68
68
|
convertBelastungen(cimModel: INTEGRALModel, knotenSfIDs: number[], defaultValuesConfig: IDefaultValuesConfig, targetClass: string): Promise<any>;
|
|
69
|
-
convertEinspeisungen(cimModel: INTEGRALModel, knotenSfIDs: number[],
|
|
69
|
+
convertEinspeisungen(cimModel: INTEGRALModel, knotenSfIDs: number[], objectMappingConfig: IObjectMappingConfig): Promise<void>;
|
|
70
70
|
convertErsatzQuerZweige(cimModel: INTEGRALModel, knotenSfIDs: number[], targetClass: string): Promise<void>;
|
|
71
71
|
convertGeneratoren(cimModel: INTEGRALModel, knotenSfIDs: number[], energyTypesConfig: any): Promise<void>;
|
|
72
72
|
convertAsynchronmotor(cimModel: INTEGRALModel, knotenSfIDs: number[], defaultValuesConfig: IDefaultValuesConfig): Promise<void>;
|
|
@@ -202,8 +202,11 @@ class ConverterI7 {
|
|
|
202
202
|
yield frame.closeXMLModel();
|
|
203
203
|
let endTime = perf_hooks_1.performance.now();
|
|
204
204
|
frame.cimModel.purgeData();
|
|
205
|
-
console.log(
|
|
205
|
+
console.log(`SerializeModel ${geoRegion.name} ${(endTime - startTime) / 1000} seconds\n`);
|
|
206
|
+
let memoryUsed = process.memoryUsage();
|
|
207
|
+
console.log(`heapUsed ${Math.round(memoryUsed['heapUsed'] / 1024 / 1024 * 100) / 100} MB`);
|
|
206
208
|
}
|
|
209
|
+
console.log('________________________________________________');
|
|
207
210
|
console.log('Serialize BD Profiles');
|
|
208
211
|
for (const entry of this.exportFramesBoundary.entries()) {
|
|
209
212
|
const geoRegionUUID = entry[0];
|
|
@@ -321,7 +324,7 @@ class ConverterI7 {
|
|
|
321
324
|
}
|
|
322
325
|
if (knotenSoIDs.length > 0 || integral7Modell.knotenSfIDs.length > 0) {
|
|
323
326
|
startTime = perf_hooks_1.performance.now();
|
|
324
|
-
yield this.convertEinspeisungen(cimModel, soSfKnoten, objectMappingConfig
|
|
327
|
+
yield this.convertEinspeisungen(cimModel, soSfKnoten, objectMappingConfig);
|
|
325
328
|
logExecutionTime(this.logger, startTime, `convertEinspeisungen`);
|
|
326
329
|
}
|
|
327
330
|
if (knotenSoIDs.length > 0 || integral7Modell.knotenSfIDs.length > 0) {
|
|
@@ -428,54 +431,20 @@ class ConverterI7 {
|
|
|
428
431
|
logExecutionTime(this.logger, startTime, `assignment of sequence number`);
|
|
429
432
|
startTime = perf_hooks_1.performance.now();
|
|
430
433
|
yield this.convertNetzvarianten(cimModel, integral7Modell);
|
|
431
|
-
logExecutionTime(this.logger, startTime, `convertNetzvarianten`);
|
|
432
|
-
console.log(this.exportFramesBoundary);
|
|
433
434
|
for (const key of integral7Modell.i7SchemaID2UUID.keys()) {
|
|
434
|
-
startTime = perf_hooks_1.performance.now();
|
|
435
435
|
yield this.convertSchemaStandorte(cimModel, integral7Modell, standortIDs, key, constants_1.NsgConstants.onlyEingeblendet);
|
|
436
|
-
logExecutionTime(this.logger, startTime, `convertSchemaStandorte`);
|
|
437
|
-
startTime = perf_hooks_1.performance.now();
|
|
438
436
|
yield this.convertSchemaKnotenSo(cimModel, integral7Modell, knotenSoIDs, key, constants_1.NsgConstants.onlyEingeblendet);
|
|
439
|
-
logExecutionTime(this.logger, startTime, `convertSchemaKnotenSo`);
|
|
440
|
-
startTime = perf_hooks_1.performance.now();
|
|
441
|
-
logExecutionTime(this.logger, startTime, `convertSchemaHgueKnotenSo`);
|
|
442
|
-
startTime = perf_hooks_1.performance.now();
|
|
443
437
|
yield this.convertSchemaSchaltanlage(cimModel, integral7Modell, schaltanlagenIDs, key, constants_1.NsgConstants.onlyEingeblendet);
|
|
444
|
-
logExecutionTime(this.logger, startTime, `convertSchemaSchaltanlage`);
|
|
445
|
-
startTime = perf_hooks_1.performance.now();
|
|
446
438
|
yield this.convertSchemaSchaltanlagenAbschnitte(cimModel, integral7Modell, schaltanlagenAbschnittIDs, key, constants_1.NsgConstants.onlyEingeblendet);
|
|
447
|
-
logExecutionTime(this.logger, startTime, `convertSchemaSchaltanlagenAbschnitte`);
|
|
448
|
-
startTime = perf_hooks_1.performance.now();
|
|
449
439
|
yield this.convertSchemaSammelschienenAbschnitte(cimModel, integral7Modell, schaltanlagenAbschnittIDs, key, constants_1.NsgConstants.onlyEingeblendet);
|
|
450
|
-
logExecutionTime(this.logger, startTime, `convertSchemaSammelschienenAbschnitte`);
|
|
451
|
-
startTime = perf_hooks_1.performance.now();
|
|
452
440
|
yield this.convertSchemaSchaltfeldElemente(cimModel, integral7Modell, schaltfeldIDs, key, constants_1.NsgConstants.onlyEingeblendet);
|
|
453
|
-
logExecutionTime(this.logger, startTime, `convertSchemaSchaltfeldElemente`);
|
|
454
|
-
startTime = perf_hooks_1.performance.now();
|
|
455
441
|
yield this.convertSchemaQuerkupplungen(cimModel, integral7Modell, key, constants_1.NsgConstants.onlyEingeblendet);
|
|
456
|
-
logExecutionTime(this.logger, startTime, `convertSchemaQuerkupplungen`);
|
|
457
|
-
startTime = perf_hooks_1.performance.now();
|
|
458
442
|
yield this.convertSchemaLaengskupplungen(cimModel, integral7Modell, key, constants_1.NsgConstants.onlyEingeblendet);
|
|
459
|
-
logExecutionTime(this.logger, startTime, `convertSchemaLaengskupplungen`);
|
|
460
|
-
startTime = perf_hooks_1.performance.now();
|
|
461
443
|
yield this.convertSchemaTransformatoren2W(cimModel, integral7Modell, key, constants_1.NsgConstants.onlyEingeblendet);
|
|
462
|
-
logExecutionTime(this.logger, startTime, `convertSchemaTransformatoren2W`);
|
|
463
|
-
startTime = perf_hooks_1.performance.now();
|
|
464
444
|
yield this.convertSchemaTransformatoren3W(cimModel, integral7Modell, standortIDs, key, constants_1.NsgConstants.onlyEingeblendet);
|
|
465
|
-
logExecutionTime(this.logger, startTime, `convertSchemaTransformatoren3W`);
|
|
466
|
-
startTime = perf_hooks_1.performance.now();
|
|
467
445
|
yield this.convertSchemaQuerzweige(cimModel, integral7Modell, key, constants_1.NsgConstants.onlyEingeblendet);
|
|
468
|
-
logExecutionTime(this.logger, startTime, `convertSchemaQuerzweige`);
|
|
469
|
-
startTime = perf_hooks_1.performance.now();
|
|
470
|
-
logExecutionTime(this.logger, startTime, `convertSchemaSternpunktSchiene`);
|
|
471
|
-
startTime = perf_hooks_1.performance.now();
|
|
472
|
-
logExecutionTime(this.logger, startTime, `convertSchemaSternpunktKnoten`);
|
|
473
|
-
startTime = perf_hooks_1.performance.now();
|
|
474
446
|
yield this.convertSchemaLeitungen(cimModel, integral7Modell, key, constants_1.NsgConstants.onlyEingeblendet);
|
|
475
|
-
logExecutionTime(this.logger, startTime, `convertSchemaLeitungen`);
|
|
476
|
-
startTime = perf_hooks_1.performance.now();
|
|
477
447
|
yield this.convertSchemaKnotenSo2(cimModel, integral7Modell, [...integral7Modell.integralAdditionalGrenzknotenIDs.values()], key, constants_1.NsgConstants.onlyEingeblendet);
|
|
478
|
-
logExecutionTime(this.logger, startTime, `convertSchemaKnotenSo`);
|
|
479
448
|
integral7Modell.integralLaengskupplungen.clear();
|
|
480
449
|
integral7Modell.integralHgueLeitungen.clear();
|
|
481
450
|
integral7Modell.integralNSGSchaltanlage.clear();
|
|
@@ -494,6 +463,7 @@ class ConverterI7 {
|
|
|
494
463
|
integral7Modell.placedCIMObjectsForDLProfil.clear();
|
|
495
464
|
}
|
|
496
465
|
}
|
|
466
|
+
logExecutionTime(this.logger, startTime, `convertNetzvarianten`);
|
|
497
467
|
});
|
|
498
468
|
}
|
|
499
469
|
assignTerminalSequenceNumber(cimModel) {
|
|
@@ -514,7 +484,6 @@ class ConverterI7 {
|
|
|
514
484
|
}
|
|
515
485
|
}
|
|
516
486
|
else {
|
|
517
|
-
console.log(`Terminal without connection ${terminalUUID}`);
|
|
518
487
|
}
|
|
519
488
|
}
|
|
520
489
|
}
|
|
@@ -533,7 +502,6 @@ class ConverterI7 {
|
|
|
533
502
|
}
|
|
534
503
|
}
|
|
535
504
|
else {
|
|
536
|
-
console.log(`Terminal without connection ${terminalUUID}`);
|
|
537
505
|
}
|
|
538
506
|
}
|
|
539
507
|
}
|
|
@@ -552,7 +520,6 @@ class ConverterI7 {
|
|
|
552
520
|
}
|
|
553
521
|
}
|
|
554
522
|
else {
|
|
555
|
-
console.log(`Terminal without connection ${terminalUUID}`);
|
|
556
523
|
}
|
|
557
524
|
}
|
|
558
525
|
}
|
|
@@ -876,6 +843,8 @@ class ConverterI7 {
|
|
|
876
843
|
const filteredResultsNsgSchaltfeld = util_functions_1.DLUtilFunctions.filterByVariantenNrOnlyEingeblendet(resultsNsgSchaltfeld, variantenNr, onlyEingeblendet);
|
|
877
844
|
for (const i7Data of filteredResultsNsgSchaltfeld) {
|
|
878
845
|
const nsgSaa = integral7.integralNSGSAAbschnitt.get(i7Data.nsgsaa);
|
|
846
|
+
if (!nsgSaa)
|
|
847
|
+
continue;
|
|
879
848
|
const nsgSa = integral7.integralNSGSchaltanlage.get(nsgSaa.nsgsaid);
|
|
880
849
|
if (nsgSa === undefined) {
|
|
881
850
|
continue;
|
|
@@ -996,6 +965,8 @@ class ConverterI7 {
|
|
|
996
965
|
ssabs.forEach(ssab => relevantSSabIDs.add(ssab.id));
|
|
997
966
|
util_functions_1.DLUtilFunctions.placeKupplung(kpFeldI7KnotenBeziehungen, uuidPointsMap, cimModel, relevantSSabIDs, integral7.integralNSGSsab, this.integralID2UUID, integral7.placedCIMObjectsForDLProfil, kpFeldDeltaausrichtung, kpFeldLeftOffset, false);
|
|
998
967
|
const nsgSaa = integral7.integralNSGSAAbschnitt.get(i7Data.nsgsaa);
|
|
968
|
+
if (!nsgSaa)
|
|
969
|
+
continue;
|
|
999
970
|
const nsgSa = integral7.integralNSGSchaltanlage.get(nsgSaa.nsgsaid);
|
|
1000
971
|
uuidPointsMap.forEach((entryDiagramObject, key) => {
|
|
1001
972
|
if (!(entryDiagramObject.identifiedObject instanceof Terminal_1.Terminal || entryDiagramObject.identifiedObject instanceof ConnectivityNode_1.ConnectivityNode)) {
|
|
@@ -1034,18 +1005,20 @@ class ConverterI7 {
|
|
|
1034
1005
|
util_functions_1.DLUtilFunctions.placeKupplung(lKupplungI7KnotenBeziehungen, uuidPointsMap, cimModel, relevantSSabIDs, integral7.integralNSGSsab, this.integralID2UUID, integral7.placedCIMObjectsForDLProfil, 0, 0, true);
|
|
1035
1006
|
}
|
|
1036
1007
|
const nsgSaa = integral7.integralNSGSAAbschnitt.get(i7Data.nsgsaa);
|
|
1037
|
-
const nsgSa = integral7.integralNSGSchaltanlage.get(nsgSaa.nsgsaid);
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
if (entryDiagramObject.
|
|
1041
|
-
entryDiagramObject.rotation
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1008
|
+
const nsgSa = integral7.integralNSGSchaltanlage.get(nsgSaa === null || nsgSaa === void 0 ? void 0 : nsgSaa.nsgsaid);
|
|
1009
|
+
if (!nsgSa) {
|
|
1010
|
+
uuidPointsMap.forEach((entryDiagramObject, key) => {
|
|
1011
|
+
if (!(entryDiagramObject.identifiedObject instanceof Terminal_1.Terminal || entryDiagramObject.identifiedObject instanceof ConnectivityNode_1.ConnectivityNode)) {
|
|
1012
|
+
if (entryDiagramObject.rotation === undefined) {
|
|
1013
|
+
entryDiagramObject.rotation = util_functions_1.DLUtilFunctions.getRotationBasedOnNsgSa(nsgSa.ausrichtung);
|
|
1014
|
+
}
|
|
1015
|
+
else {
|
|
1016
|
+
entryDiagramObject.rotation += util_functions_1.DLUtilFunctions.getRotationBasedOnNsgSa(nsgSa.ausrichtung);
|
|
1017
|
+
}
|
|
1045
1018
|
}
|
|
1046
|
-
}
|
|
1047
|
-
|
|
1048
|
-
|
|
1019
|
+
});
|
|
1020
|
+
util_functions_1.DLUtilFunctions.rotateShiftAddBasedOnNsgSAA(cimModel, integral7, variantenNr, i7Data.nsgsaa, uuidPointsMap);
|
|
1021
|
+
}
|
|
1049
1022
|
}
|
|
1050
1023
|
}
|
|
1051
1024
|
});
|
|
@@ -2011,8 +1984,11 @@ class ConverterI7 {
|
|
|
2011
1984
|
}
|
|
2012
1985
|
});
|
|
2013
1986
|
}
|
|
2014
|
-
convertEinspeisungen(cimModel, knotenSfIDs,
|
|
1987
|
+
convertEinspeisungen(cimModel, knotenSfIDs, objectMappingConfig) {
|
|
1988
|
+
var _a;
|
|
2015
1989
|
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
1990
|
+
const targetConfig = objectMappingConfig.Einspeisung;
|
|
1991
|
+
const targetClass = objectMappingConfig.Einspeisung.class;
|
|
2016
1992
|
if (this.isTableAvailable(integral_sql_1.Integral7TableNames.EINSPEISUNG)) {
|
|
2017
1993
|
const result = yield this.mysqlController.execQuery(integral_sql_1.getI7Query(integral_sql_1.I7Objects.EINSPEISUNG, knotenSfIDs));
|
|
2018
1994
|
switch (targetClass) {
|
|
@@ -2025,7 +2001,15 @@ class ConverterI7 {
|
|
|
2025
2001
|
break;
|
|
2026
2002
|
}
|
|
2027
2003
|
default: {
|
|
2028
|
-
|
|
2004
|
+
if ((_a = targetConfig.referencePriority) === null || _a === void 0 ? void 0 : _a.prio) {
|
|
2005
|
+
const i7SlacksResults = result.filter(it => it.spannungsgeregelt);
|
|
2006
|
+
const i7EnergySourceResults = result.filter(it => !it.spannungsgeregelt);
|
|
2007
|
+
yield this.convertEinspeisungen2EnergySource(cimModel, i7EnergySourceResults);
|
|
2008
|
+
yield this.convertEinspeisungen2ExternalNetworkInjection(cimModel, i7SlacksResults);
|
|
2009
|
+
}
|
|
2010
|
+
else {
|
|
2011
|
+
yield this.convertEinspeisungen2EnergySource(cimModel, result);
|
|
2012
|
+
}
|
|
2029
2013
|
}
|
|
2030
2014
|
}
|
|
2031
2015
|
}
|
|
@@ -2990,7 +2974,6 @@ class ConverterI7 {
|
|
|
2990
2974
|
externalNetworkInjection.controlEnabled = inBetrieb;
|
|
2991
2975
|
regulatingControl.addRegulatingCondEq(externalNetworkInjection);
|
|
2992
2976
|
externalNetworkInjection.regulatingControl = regulatingControl;
|
|
2993
|
-
this.setTapChangerControl;
|
|
2994
2977
|
cimModel.addRegulatingControl(regulatingControl);
|
|
2995
2978
|
break;
|
|
2996
2979
|
}
|
|
@@ -3759,7 +3742,6 @@ class ConverterI7 {
|
|
|
3759
3742
|
if (this.isTableAvailable(integral_sql_1.Integral7TableNames.HGUE_LEITUNG) && integral7.hgueAnschlussKnotenIDs.length > 0) {
|
|
3760
3743
|
const result = yield this.mysqlController.execQuery(integral_sql_1.getI7Query(integral_sql_1.I7Objects.HGUE_LEITUNG, integral7.hgueAnschlussKnotenIDs));
|
|
3761
3744
|
for (const i7Data of result) {
|
|
3762
|
-
console.log(utils_1.getUUID(i7Data.guid_dcline));
|
|
3763
3745
|
if (utils_1.getUUID(i7Data.guid_dcline) === '6a5b7e1e-f8be-4165-9752-2e2359d9b4f8') {
|
|
3764
3746
|
let stop = true;
|
|
3765
3747
|
}
|