java110
2021-08-16 b047995d946a82ee0d4f15d01b6412f051abc452
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
package com.java110.oa.activity;
 
import org.activiti.engine.impl.cfg.IdGenerator;
 
import java.util.UUID;
 
/**
 * @ClassName ActivityIdGenerator
 * @Description TODO
 * @Author wuxw
 * @Date 2019/10/22 21:56
 * @Version 1.0
 * add by wuxw 2019/10/22
 **/
public class ActivityIdGenerator implements IdGenerator {
    /**
     * 封装JDK自带的UUID, 通过Random数字生成, 中间无-分割.
     */
    public static String uuid() {
        return UUID.randomUUID().toString().replaceAll("-", "");
    }
 
    /**
     * Activiti ID 生成
     */
    @Override
    public String getNextId() {
        return uuid();
    }
 
}