欧美一区二区三区,国内熟女精品熟女A片视频小说,日本av网,小鲜肉男男GAY做受XXX网站

java如何生成12位序列號(hào)

java如何生成12位序列號(hào)?

private static int maxvaluefive=99999999;

private static int minvaluefive=0;

private static AtomicInteger atomic = new AtomicInteger(minvaluefive);

/** 生成序列號(hào) */

static String getSeqFive(int coverPad) {

for (;;) {

int current = atomic.get();

int newValue = current >= maxvaluefive ? minvaluefive : current + 1;

if (atomic.compareAndSet(current, newValue)) {

return StringUtils.leftPad(String.valueOf(current), coverPad, "0");

}

}

}

java截取字符串,java如何生成12位序列號(hào)