InfoFlagsStr in Results as an item in WMeterRsltItemSpec.
This commit is contained in:
@@ -371,6 +371,12 @@ namespace Results.Entities
|
||||
#endif
|
||||
}
|
||||
|
||||
/// <summary> Wrapper </summary>
|
||||
public virtual string InfoFlagsStr()
|
||||
{
|
||||
return Utils.ErrorFlagsStr(InfoFlags);
|
||||
}
|
||||
|
||||
public virtual bool IsPartCompatible(int waterMeterPartNr)
|
||||
{
|
||||
if ((this.Part == 0) || (waterMeterPartNr == 0)) return true;
|
||||
|
||||
@@ -186,6 +186,30 @@ namespace Results.Entities
|
||||
#endif
|
||||
}
|
||||
|
||||
public virtual long InfoFlagsFromTests()
|
||||
{
|
||||
long infoFlags = 0;
|
||||
foreach (var mtr in MeterTestRslts)
|
||||
{
|
||||
if (mtr.Evaluate() && mtr.TestDone) infoFlags |= mtr.TestRslt.InfoFlags;
|
||||
}
|
||||
return infoFlags;
|
||||
}
|
||||
|
||||
public virtual long InfoFlagsFromTestsAndWM()
|
||||
{
|
||||
return InfoFlagsFromTests() | InfoFlags;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Convert combined errorFlags of all tests to string
|
||||
/// </summary>
|
||||
/// <returns>ErrorFlags string</returns>
|
||||
public virtual string InfoFlagsStr()
|
||||
{
|
||||
return Utils.ErrorFlagsStr(InfoFlagsFromTestsAndWM());
|
||||
}
|
||||
|
||||
public virtual string PassedOrErrorFlagsStr()
|
||||
{
|
||||
string eFlags = Utils.ErrorFlagsStr(ErrorFlagsFromTestsAndWM());
|
||||
|
||||
Reference in New Issue
Block a user