天天看点

Java生成一个全小写的UUID

import java.util.UUID;

public class UUIDDemo {
    public static void main(String[] args) {
        //转小写去横杠
        String uuid = UUID.randomUUID().toString().replaceAll("-", "").toLowerCase();
        System.out.println("转小写去横杠之后的uuid为:"+uuid);
 }
}