Innovenergy_trunk/csharp/Lib/Units/Composite/Ac1Bus.cs

28 lines
561 B
C#

using System.Diagnostics.CodeAnalysis;
namespace InnovEnergy.Lib.Units.Composite;
public record Ac1Bus : AcPhase
{
public Frequency Frequency { get; init; }
[SuppressMessage("ReSharper", "RedundantCast")]
public static Ac1Bus operator |(Ac1Bus left, Ac1Bus right)
{
var f = left.Frequency | right.Frequency;
var p = (AcPhase)left | (AcPhase)right;
return new Ac1Bus
{
Frequency = f,
Current = p.Current,
Voltage = p.Voltage,
Phi = p.Phi
};
}
}