mitao
2025-02-21 31573d6180d15ef65ed0df9c2732495f40b12663
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
package com.panzhihua.common.utlis;
 
import cn.hutool.core.util.IdUtil;
 
/**
 * @author xyh
 * @date 2021/6/10 15:29
 */
public class Snowflake {
    public static long getId() {
        cn.hutool.core.lang.Snowflake snowflake = IdUtil.getSnowflake(1, 1);
        long id = snowflake.nextId();
        return id;
    }
}