648540858
2024-03-28 1de344674afd6bb35b51b165bbad76dbe6299b7e
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
package com.genersoft.iot.vmp.jt1078.proc.entity;
 
import com.genersoft.iot.vmp.jt1078.proc.response.Rs;
 
/**
 * @author QingtaiJiang
 * @date 2023/4/27 18:23
 * @email qingtaij@163.com
 */
public class Cmd {
    String devId;
    Long packageNo;
    String msgId;
    String respId;
    Rs rs;
 
    public Cmd() {
    }
 
    public Cmd(Builder builder) {
        this.devId = builder.devId;
        this.packageNo = builder.packageNo;
        this.msgId = builder.msgId;
        this.respId = builder.respId;
        this.rs = builder.rs;
    }
 
    public String getDevId() {
        return devId;
    }
 
    public void setDevId(String devId) {
        this.devId = devId;
    }
 
    public Long getPackageNo() {
        return packageNo;
    }
 
    public void setPackageNo(Long packageNo) {
        this.packageNo = packageNo;
    }
 
    public String getMsgId() {
        return msgId;
    }
 
    public void setMsgId(String msgId) {
        this.msgId = msgId;
    }
 
    public String getRespId() {
        return respId;
    }
 
    public void setRespId(String respId) {
        this.respId = respId;
    }
 
    public Rs getRs() {
        return rs;
    }
 
    public void setRs(Rs rs) {
        this.rs = rs;
    }
 
    public static class Builder {
        String devId;
        Long packageNo;
        String msgId;
        String respId;
        Rs rs;
 
        public Builder setDevId(String devId) {
            this.devId = devId.replaceFirst("^0*", "");
            return this;
        }
 
        public Builder setPackageNo(Long packageNo) {
            this.packageNo = packageNo;
            return this;
        }
 
        public Builder setMsgId(String msgId) {
            this.msgId = msgId;
            return this;
        }
 
        public Builder setRespId(String respId) {
            this.respId = respId;
            return this;
        }
 
        public Builder setRs(Rs re) {
            this.rs = re;
            return this;
        }
 
        public Cmd build() {
            return new Cmd(this);
        }
    }
 
 
    @Override
    public String toString() {
        return "Cmd{" +
                "devId='" + devId + '\'' +
                ", packageNo=" + packageNo +
                ", msgId='" + msgId + '\'' +
                ", respId='" + respId + '\'' +
                ", rs=" + rs +
                '}';
    }
}