Jelajahi Sumber

提交新定义td数据库实体

lengfaqiang 2 tahun lalu
induk
melakukan
312c9cc228

+ 25 - 0
slope-modules/slope-detection/src/main/java/com/sckw/slope/detection/dao/tdengine/DeviceMapper.java

@@ -0,0 +1,25 @@
+package com.sckw.slope.detection.dao.tdengine;
+
+import com.baomidou.dynamic.datasource.annotation.DS;
+import com.sckw.slope.detection.model.dos.tdengine.Device;
+import org.apache.ibatis.annotations.Mapper;
+import org.springframework.stereotype.Repository;
+
+import java.util.Date;
+
+@DS("td")
+@Mapper
+@Repository
+public interface DeviceMapper {
+    int deleteByPrimaryKey(Date ts);
+
+    int insert(Device record);
+
+    int insertSelective(Device record);
+
+    Device selectByPrimaryKey(Date ts);
+
+    int updateByPrimaryKeySelective(Device record);
+
+    int updateByPrimaryKey(Device record);
+}

+ 31 - 0
slope-modules/slope-detection/src/main/java/com/sckw/slope/detection/model/dos/tdengine/Device.java

@@ -0,0 +1,31 @@
+package com.sckw.slope.detection.model.dos.tdengine;
+
+import java.io.Serializable;
+import java.util.Date;
+
+/**
+    * STABLE
+    */
+public class Device implements Serializable {
+
+    private Date ts;
+
+    private String guid;
+
+    private String tslver;
+
+    private String key;
+
+    private String cvalue;
+
+    private String jsonText;
+
+    /**
+    * TAG
+    */
+
+    private String sn;
+
+    private static final long serialVersionUID = 1L;
+
+}