ningshuxia
2023-03-14 076301ec9c2c2fc117a062231c4c5f0e8ea6c23c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
 
namespace IStation.Model.Monitor 
{
    /// <summary>
    /// 最大值统计公式参数
    /// </summary>
    public class MaxValueStatisticsFormulaParas : JsonModel<MaxValueStatisticsFormulaParas>
    {
        /// <summary>
        /// 测点标识
        /// </summary>
        public long ObjectID { get; set; }
 
        /// <summary>
        /// 统计
        /// </summary>
        public double Statistic(IEnumerable<double> list)
        {
            if (list == null || list.Count() < 1)
                return default;
            return list.Max();
        }
 
    }
}