public static IEnumerable <string> GetShortNames(byte flags, IQualityBitInfo info) { for (byte i = 0; i < 8; ++i) { if ((flags & (1 << i)) != 0) { yield return(info.GetShortLabel(i)); } } }
public Measurement(string displayValue, TimestampMode tsmode, MeasType type, UInt16 index, IQualityBitInfo info) { this.valueAsString = displayValue; this.timeStamp = DateTime.Now; this.tsmode = tsmode; this.type = type; this.index = index; this.info = info; this.quality = 0; }
public Measurement(string displayValue, MeasurementBase meas, TimestampMode tsmode, MeasType type, UInt16 index, IQualityBitInfo info) { this.valueAsString = displayValue; this.timeStamp = (tsmode == TimestampMode.INVALID) ? DateTime.Now : meas.Timestamp; this.tsmode = tsmode; this.type = type; this.index = index; this.info = info; this.quality = meas.Quality; }