-
Notifications
You must be signed in to change notification settings - Fork 9
/
ReturnBoxContainerRequest.go
37 lines (32 loc) · 1.11 KB
/
ReturnBoxContainerRequest.go
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
package wdk
import (
"sync"
)
// ReturnBoxContainerRequest 结构体
type ReturnBoxContainerRequest struct {
// 周转箱列表
BoxCodeList []string `json:"box_code_list,omitempty" xml:"box_code_list>string,omitempty"`
// 收箱交接单号
HandOverNo string `json:"hand_over_no,omitempty" xml:"hand_over_no,omitempty"`
// 仓编号
WarehouseCode string `json:"warehouse_code,omitempty" xml:"warehouse_code,omitempty"`
// 操作时间
OperateTime string `json:"operate_time,omitempty" xml:"operate_time,omitempty"`
}
var poolReturnBoxContainerRequest = sync.Pool{
New: func() any {
return new(ReturnBoxContainerRequest)
},
}
// GetReturnBoxContainerRequest() 从对象池中获取ReturnBoxContainerRequest
func GetReturnBoxContainerRequest() *ReturnBoxContainerRequest {
return poolReturnBoxContainerRequest.Get().(*ReturnBoxContainerRequest)
}
// ReleaseReturnBoxContainerRequest 释放ReturnBoxContainerRequest
func ReleaseReturnBoxContainerRequest(v *ReturnBoxContainerRequest) {
v.BoxCodeList = v.BoxCodeList[:0]
v.HandOverNo = ""
v.WarehouseCode = ""
v.OperateTime = ""
poolReturnBoxContainerRequest.Put(v)
}