From 27d341342925f11c19fb7a31da7050f5e9041319 Mon Sep 17 00:00:00 2001
From: feiyu02 <risaku@163.com>
Date: 星期四, 19 十月 2023 17:52:29 +0800
Subject: [PATCH] 新增数据分析模块

---
 src/main/java/com/flightfeather/monitor/analysis/dust/ExceptionValueMutation.kt |   39 +++++++++++++++++++++++++++++++++++++++
 1 files changed, 39 insertions(+), 0 deletions(-)

diff --git a/src/main/java/com/flightfeather/monitor/analysis/dust/ExceptionValueMutation.kt b/src/main/java/com/flightfeather/monitor/analysis/dust/ExceptionValueMutation.kt
new file mode 100644
index 0000000..2a0387e
--- /dev/null
+++ b/src/main/java/com/flightfeather/monitor/analysis/dust/ExceptionValueMutation.kt
@@ -0,0 +1,39 @@
+package com.flightfeather.monitor.analysis.dust
+
+import com.flightfeather.monitor.analysis.DataAnalysisInterface
+import com.flightfeather.monitor.domain.ds1.entity.DustExceptionSetting
+import com.flightfeather.monitor.domain.ds1.entity.DustSiteData
+import java.util.*
+import kotlin.properties.Delegates
+
+/**
+ * 閲忕骇绐佸彉寮傚父鍒嗘瀽
+ */
+class ExceptionValueMutation(config: DustExceptionSetting) : DataAnalysisInterface<DustSiteData,
+        DustExceptionSetting>(config) {
+
+    private var mutationNum by Delegates.notNull<Int>()
+
+    private var mutationRate by Delegates.notNull<Double>()
+
+    private var lastDataTime: Date? = null
+
+    override fun initConfig(config: DustExceptionSetting) {
+        mutationNum = config.mutationNum
+        mutationRate = config.mutationRate
+    }
+
+    override fun onNextData(data: DustSiteData) {
+        if (lastDataTime != null) {
+            // 鐩搁偦鏁版嵁鏃堕棿灏忎簬鎴栫瓑浜�30鍒嗛挓鍒嗕负涓�缁�
+        }
+
+        lastDataTime = data.lst
+    }
+
+    override fun toDb() {
+        TODO("Not yet implemented")
+    }
+
+
+}
\ No newline at end of file

--
Gitblit v1.9.3