private static String getUUID() {
// 自动生成主键,例如550E8400-E29B-11D4-A716-446655440000
String id = UUID.randomUUID().toString();
String replaceAll = id.replaceAll("-", "");
//550E8400E29B11D4A716446655440000
return replaceAll;
}
Java生成主键id
最新推荐文章于 2024-08-23 09:40:50 发布