commit | author | age
|
a18bfa
|
1 |
package cn.autoform.web.controller.resumable.redis.lock; |
Z |
2 |
|
|
3 |
import java.io.Serializable; |
|
4 |
|
|
5 |
import lombok.AllArgsConstructor; |
|
6 |
import lombok.Data; |
|
7 |
import lombok.EqualsAndHashCode; |
|
8 |
import lombok.NoArgsConstructor; |
|
9 |
|
|
10 |
/** |
|
11 |
* 锁类 |
|
12 |
* @author wangyuxin |
|
13 |
* |
|
14 |
*/ |
|
15 |
@Data |
|
16 |
@AllArgsConstructor |
|
17 |
@NoArgsConstructor |
|
18 |
@EqualsAndHashCode(of="lockInfo") |
|
19 |
public class Lock implements Serializable{ |
|
20 |
|
|
21 |
|
|
22 |
/** |
|
23 |
* |
|
24 |
*/ |
|
25 |
private static final long serialVersionUID = 8811304440312972451L; |
|
26 |
|
|
27 |
|
|
28 |
/** |
|
29 |
* 锁信息 |
|
30 |
*/ |
|
31 |
private String lockInfo; |
|
32 |
|
|
33 |
/** |
|
34 |
* 钥匙信息 |
|
35 |
*/ |
|
36 |
private Key key; |
|
37 |
|
|
38 |
/** |
|
39 |
* 超时时间 |
|
40 |
*/ |
|
41 |
private Long timeOut; |
|
42 |
|
|
43 |
public Lock(String lockInfo) { |
|
44 |
this(lockInfo, null, null); |
|
45 |
} |
|
46 |
|
|
47 |
} |