From f09b972bb7adf8d4fd75fcb87c85973e493432a8 Mon Sep 17 00:00:00 2001 From: Junjie <xjj@123> Date: 星期二, 30 四月 2024 11:14:20 +0800 Subject: [PATCH] # --- zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/rcs/model/protocol/ShuttleProtocol.java | 31 ++++++++++++++++++++++++++----- 1 files changed, 26 insertions(+), 5 deletions(-) diff --git a/zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/rcs/model/protocol/ShuttleProtocol.java b/zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/rcs/model/protocol/ShuttleProtocol.java index 20886e1..619c409 100644 --- a/zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/rcs/model/protocol/ShuttleProtocol.java +++ b/zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/rcs/model/protocol/ShuttleProtocol.java @@ -7,23 +7,19 @@ import com.zy.asrs.wcs.core.service.LocService; import com.zy.asrs.wcs.core.utils.RedisUtil; import com.zy.asrs.wcs.rcs.constant.DeviceRedisConstant; -import com.zy.asrs.wcs.rcs.model.enums.ShuttleDeviceStatusType; import com.zy.asrs.wcs.rcs.model.enums.ShuttleProtocolStatusType; import com.zy.asrs.wcs.rcs.entity.Device; import com.zy.asrs.wcs.rcs.entity.ShuttleDeviceStatus; -import com.zy.asrs.wcs.rcs.model.enums.SlaveType; import com.zy.asrs.wcs.rcs.service.ShuttleDeviceStatusService; import lombok.Data; import lombok.extern.slf4j.Slf4j; - -import java.util.HashMap; /** * 鍥涘悜绌挎杞� */ @Slf4j @Data -public class ShuttleProtocol { +public class ShuttleProtocol implements Cloneable{ //**********************蹇呴』瀛樺湪灞炴��********************** /** @@ -60,6 +56,11 @@ * 灏忚溅璁惧鐘舵�� */ private Integer deviceStatus; + + /** + * 灏忚溅妯″紡锛�0锛氭墜鍔� 1锛氳嚜鍔� + */ + private Integer mode; /** * 褰撳墠浜岀淮鐮� @@ -163,6 +164,16 @@ private Long deviceDataLog = System.currentTimeMillis(); /** + * 鎸囦护涓嬪彂鏃堕棿 + */ + private Long sendTime = 0L; + + /** + * 鏈�杩戜竴娆″湪绾挎椂闂� + */ + private Long lastOnlineTime = System.currentTimeMillis(); + + /** * 璁惧淇℃伅 */ private Device device; @@ -248,4 +259,14 @@ return currentLoc.getLocNo(); } + @Override + public ShuttleProtocol clone() { + try { + return (ShuttleProtocol) super.clone(); + } catch (CloneNotSupportedException e) { + e.printStackTrace(); + } + return null; + } + } -- Gitblit v1.9.1