Pu Zhibing
2025-04-09 b8a3a680f3e6720a8329bfaae571b09659aace52
ruoyi-service/ruoyi-dataInterchange/src/main/java/com/ruoyi/dataInterchange/model/DOWNPlaybackMsgStartup.java
@@ -5,6 +5,8 @@
import io.netty.buffer.Unpooled;
import lombok.Data;
import java.io.UnsupportedEncodingException;
/**
 * 远程录像回放请求
 *
@@ -77,7 +79,12 @@
    */
   public byte[] encode() {
      ByteBuf byteBuf = Unpooled.buffer(148);
      byte[] bytes1 = this.getVehicleNo().getBytes();
      byte[] bytes1 = new byte[0];
      try {
         bytes1 = this.getVehicleNo().getBytes("GBK");
      } catch (UnsupportedEncodingException e) {
         throw new RuntimeException(e);
      }
      for (int i = 0; i < 21; i++) {
         if (i < bytes1.length) {
            byteBuf.writeByte(bytes1[i]);
@@ -94,7 +101,12 @@
      byteBuf.writeChar(this.getMemType());
      byteBuf.writeLong(this.getPlaybackStartTime());
      byteBuf.writeLong(this.getPlaybackEndTime());
      byte[] bytes2 = this.getAuthorizeCode().getBytes();
      byte[] bytes2 = new byte[0];
      try {
         bytes2 = this.getAuthorizeCode().getBytes("GBK");
      } catch (UnsupportedEncodingException e) {
         throw new RuntimeException(e);
      }
      for (int i = 0; i < 64; i++) {
         if (i < bytes2.length) {
            byteBuf.writeByte(bytes2[i]);
@@ -102,7 +114,12 @@
            byteBuf.writeByte(0x00);
         }
      }
      byte[] bytes3 = this.getGnssData().getBytes();
      byte[] bytes3 = new byte[0];
      try {
         bytes3 = this.getGnssData().getBytes("GBK");
      } catch (UnsupportedEncodingException e) {
         throw new RuntimeException(e);
      }
      for (int i = 0; i < 36; i++) {
         if (i < bytes3.length) {
            byteBuf.writeByte(bytes3[i]);