remove private constructor, no longer needed bcs of "required"
This commit is contained in:
parent
cc2ab03d01
commit
c955b97c2b
|
@ -1,11 +1,8 @@
|
||||||
|
|
||||||
namespace InnovEnergy.Lib.Units.Composite;
|
namespace InnovEnergy.Lib.Units.Composite;
|
||||||
|
|
||||||
|
public class Ac3Bus
|
||||||
public sealed class Ac3Bus
|
|
||||||
{
|
{
|
||||||
private Ac3Bus() {}
|
|
||||||
|
|
||||||
public required AcPhase L1 { get; init; }
|
public required AcPhase L1 { get; init; }
|
||||||
public required AcPhase L2 { get; init; }
|
public required AcPhase L2 { get; init; }
|
||||||
public required AcPhase L3 { get; init; }
|
public required AcPhase L3 { get; init; }
|
||||||
|
|
|
@ -5,8 +5,6 @@ namespace InnovEnergy.Lib.Units.Composite;
|
||||||
|
|
||||||
public sealed class AcPhase
|
public sealed class AcPhase
|
||||||
{
|
{
|
||||||
private AcPhase(){}
|
|
||||||
|
|
||||||
public required Voltage Voltage { get; init; }
|
public required Voltage Voltage { get; init; }
|
||||||
public required Current Current { get; init; }
|
public required Current Current { get; init; }
|
||||||
public required AcPower Power { get; init; }
|
public required AcPower Power { get; init; }
|
||||||
|
|
|
@ -98,13 +98,10 @@ public sealed class AcPower
|
||||||
|
|
||||||
public static AcPower operator -(AcPower p)
|
public static AcPower operator -(AcPower p)
|
||||||
{
|
{
|
||||||
var activePower = -p.Active;
|
|
||||||
var reactivePower = -p.Reactive;
|
|
||||||
|
|
||||||
return FromActiveReactive
|
return FromActiveReactive
|
||||||
(
|
(
|
||||||
activePower,
|
-p.Active,
|
||||||
reactivePower
|
-p.Reactive
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue