예제 #1
0
 protected override void AddItem(decimal?item)
 {
     if (!item.HasValue)
     {
         return;
     }
     Accumulator = new SumData <decimal>()
     {
         ElementCount = Accumulator.ElementCount + 1,
         Sum          = Accumulator.Sum + item.Value
     };
 }
예제 #2
0
 protected override void RemoveItem(double?item)
 {
     if (!item.HasValue)
     {
         return;
     }
     Accumulator = new SumData <double>()
     {
         ElementCount = Accumulator.ElementCount - 1,
         Sum          = Accumulator.Sum - item.Value
     };
 }
예제 #3
0
 protected override void ResetAccumulator()
 {
     Accumulator = new SumData <decimal>();
 }
예제 #4
0
 protected override void ResetAccumulator()
 {
     Accumulator = new SumData <double>();
 }
예제 #5
0
 protected override void ResetAccumulator()
 {
     Accumulator = new SumData <float>();
 }