Skip to content

Commit

Permalink
fix: CIM::String does not overload operator =
Browse files Browse the repository at this point in the history
Signed-off-by: Niklas Eiling <niklas.eiling@eonerc.rwth-aachen.de>
  • Loading branch information
n-eiling committed Jan 15, 2025
1 parent 22cdeb9 commit 0cd8c4a
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions dpsim-models/src/CIM/Reader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -604,7 +604,7 @@ Reader::mapSynchronousMachine(CIMPP::SynchronousMachine *machine) {
if (CIMPP::SynchronousMachineTimeConstantReactance *genDyn =
dynamic_cast<CIMPP::SynchronousMachineTimeConstantReactance *>(
obj)) {
if (genDyn->SynchronousMachine->mRID == machine->mRID) {
if (genDyn->SynchronousMachine->mRID.value == machine->mRID.value) {
// stator
Real Rs = genDyn->statorResistance.value;
Real Ll = genDyn->statorLeakageReactance.value;
Expand Down Expand Up @@ -740,7 +740,7 @@ Reader::mapSynchronousMachine(CIMPP::SynchronousMachine *machine) {
if (CIMPP::SynchronousMachineTimeConstantReactance *genDyn =
dynamic_cast<CIMPP::SynchronousMachineTimeConstantReactance *>(
obj)) {
if (genDyn->SynchronousMachine->mRID == machine->mRID) {
if (genDyn->SynchronousMachine->mRID.value == machine->mRID.value) {
// stator
Real Rs = genDyn->statorResistance.value;
Real Ll = genDyn->statorLeakageReactance.value;
Expand Down Expand Up @@ -829,7 +829,7 @@ Reader::mapSynchronousMachine(CIMPP::SynchronousMachine *machine) {
if (CIMPP::GeneratingUnit *genUnit =
dynamic_cast<CIMPP::GeneratingUnit *>(obj)) {
for (auto syncGen : genUnit->RotatingMachine) {
if (syncGen->mRID == machine->mRID) {
if (syncGen->mRID.value == machine->mRID.value) {
// Check whether relevant input data are set, otherwise set default values
Real setPointActivePower = 0;
Real setPointVoltage = 0;
Expand Down Expand Up @@ -907,7 +907,7 @@ Reader::mapSynchronousMachine(CIMPP::SynchronousMachine *machine) {
if (CIMPP::SynchronousMachineTimeConstantReactance *genDyn =
dynamic_cast<CIMPP::SynchronousMachineTimeConstantReactance *>(
obj)) {
if (genDyn->SynchronousMachine->mRID == machine->mRID) {
if (genDyn->SynchronousMachine->mRID.value == machine->mRID.value) {

// stator
Real Rs = genDyn->statorResistance.value;
Expand Down Expand Up @@ -1103,7 +1103,7 @@ Real Reader::determineBaseVoltageAssociatedWithEquipment(
if (CIMPP::BaseVoltage *baseVolt =
dynamic_cast<CIMPP::BaseVoltage *>(obj)) {
for (auto comp : baseVolt->ConductingEquipment) {
if (comp->name == equipment->name) {
if (comp->name.value == equipment->name.value) {
baseVoltage =
unitValue(baseVolt->nominalVoltage.value, UnitMultiplier::k);
}
Expand All @@ -1116,7 +1116,7 @@ Real Reader::determineBaseVoltageAssociatedWithEquipment(
if (CIMPP::TopologicalNode *topNode =
dynamic_cast<CIMPP::TopologicalNode *>(obj)) {
for (auto term : topNode->Terminal) {
if (term->ConductingEquipment->name == equipment->name) {
if (term->ConductingEquipment->name.value == equipment->name.value) {
baseVoltage = unitValue(topNode->BaseVoltage->nominalVoltage.value,
UnitMultiplier::k);
}
Expand Down

0 comments on commit 0cd8c4a

Please sign in to comment.