コード例 #1
0
        public Profile([JetBrains.Annotations.NotNull] string name,
                       [JetBrains.Annotations.NotNull] ReadOnlyCollection <double> values,
                       EnergyOrPower energyOrPower)
        {
            EnergyOrPower = energyOrPower;
            if (EnergyOrPower == EnergyOrPower.Unknown)
            {
                throw new Exception("Unknown profile");
            }

            Values = values;
            Name   = name;
        }
        public JsonSerializableProfile([NotNull] string name,
                                       [NotNull] ReadOnlyCollection <double> values,
                                       EnergyOrPower energyOrPower)
        {
            EnergyOrPower = energyOrPower;
            if (EnergyOrPower == EnergyOrPower.Unknown)
            {
                throw new Exception("Unknown profile");
            }

            Values = values;
            Name   = name;
        }
コード例 #3
0
 public ChangableProfile([NotNull] double[] values, [NotNull] string name, EnergyOrPower energyOrPower)
 {
     _values       = values;
     Name          = name;
     EnergyOrPower = energyOrPower;
 }