Exemple #1
0
 private MeasurementValueType(MeasurementValueTypeName name,
                              string label,
                              string unit)
 {
     this._name  = name;
     this._label = label;
     this._unit  = unit;
 }
Exemple #2
0
 public MeasurementStandard(string name,
                            MeasurementValueTypeName pollutant,
                            double limit,
                            double percent,
                            string averaging)
 {
     Name      = name;
     Pollutant = pollutant;
     Limit     = limit;
     Percent   = percent;
     Averaging = averaging;
 }
 private Standard(string name,
                  MeasurementValueTypeName pollutant,
                  double limit,
                  double percent,
                  string averaging)
 {
     _name      = name;
     _pollutant = pollutant;
     _limit     = limit;
     _percent   = percent;
     _averaging = averaging;
 }
Exemple #4
0
 public static MeasurementValueType GetForName(MeasurementValueTypeName name)
 => EnumMap.First(type => type.Name == name) ?? throw new ArgumentException("Invalid MeasurementValueType name.");
 public static Standard Create(string name,
                               MeasurementValueTypeName pollutant,
                               double limit,
                               double percent,
                               string averaging)
 => new Standard(name, pollutant, limit, percent, averaging);
 public static Value Create(MeasurementValueTypeName typeName, double value)
 => new Value(typeName, value);
 private Value(MeasurementValueTypeName typeName, double value)
 {
     _typeName = typeName;
     _value    = value;
 }
Exemple #8
0
 public MeasurementValue(MeasurementValueTypeName name, double value)
 {
     Name  = name;
     Value = value;
 }
 public static MeasurementStandard Create(string name,
                                          MeasurementValueTypeName pollutantName,
                                          double limit,
                                          double percent,
                                          string averaging)
 => new MeasurementStandard(null, name, MeasurementValueType.GetForName(pollutantName), limit, percent, averaging);
Exemple #10
0
 public static MeasurementValue Create(MeasurementValueTypeName typeName, double value)
 => new MeasurementValue(null, MeasurementValueType.GetForName(typeName), value);