//добавление элемента из архива //public void AddBefore(MomentValue dot) //{ // if (dot.Undef % 2 != 0) dot.ToMomentReal().Mean = Dots.ParamsCount != 0 ? Dots.Last().ToMomentReal().Mean : 0; // Dots.Insert(0, dot); //} //public void AddBefore(List<MomentValue> dots) //{ // if (dots[0].Undef % 2 != 0) dots.Insert(0, new MomentReal(dots[0].Time, 0, -1, 0, 0)); // for (int index = dots.ParamsCount-1; index >= 0; index--) // { // var momentValue = dots[index]; // if (momentValue.Undef % 2 != 0) momentValue.ToMomentReal().Mean = dots[index + 1].ToMomentReal().Mean; // Dots.Insert(0, momentValue); // } //} //добавление элемента public void AddValues(MomentValue dot) { if (!IsUpdated) { IsUpdated = true; NumberOfFirstWaiting = Dots.Count; } //if (dot.Nd % 2 != 0) dot.ToMomentReal().Mean = Dots.Count != 0 ? Dots.Last().ToMomentReal().Mean : 0; Dots.Add(dot); }
public bool Equals(MomentValue other) { if (ReferenceEquals(null, other)) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return(this == other); }
public override void AddDot(MomentValue dot) { AddDot(dot.ToMomentReal()); }
public abstract void AddDot(MomentValue dot);
public MomentValue(MomentValue val) { DataType = DataType.Value; Time = val.Time; Nd = val.Nd; }
public override void AddDot(MomentValue dot) { AddDot(dot.ToMomentBoolean()); }