RandomStringUtils 生成随机字符串

代码:

System.out.println(RandomStringUtils.randomAlphanumeric(32));
System.out.println(RandomStringUtils.randomAlphabetic(32));
System.out.println(RandomStringUtils.randomNumeric(32));
System.out.println(RandomStringUtils.randomPrint(32));
System.out.println(RandomStringUtils.random(32,”utf-8″));
System.out.println(RandomStringUtils.random(32));
System.out.println(RandomStringUtils.randomAscii(32));
System.out.println(RandomStringUtils.randomGraph(32));

对应输出:

PxszorswiThGgdUjzcRTP3YHh1TltdrK
nlWFVnmtXjoNJpuOyEESjxIInScYcOIO
75751119690962135718497019074450
Lu,w4C/T57nf%CUt+%5>+pQ :5nt&zaI
uuf8ffuut-u-u-8t-tuut8t-fut8tt8u
᩹酋䮷氿𦄺엚𨎨䬢𪓐𬊱𨀡墓𩬀𣽯릾貄쉝𡝪𧕅𣫩𩺁
hSR{/1>3

Original: https://www.cnblogs.com/oyww-2027/p/15384936.html
Author: OYそ
Title: RandomStringUtils 生成随机字符串

原创文章受到原创版权保护。转载请注明出处:https://www.johngo689.com/579464/

转载文章受原作者版权保护。转载请注明原作者出处!

(0)

大家都在看

亲爱的 Coder【最近整理,可免费获取】👉 最新必读书单  | 👏 面试题下载  | 🌎 免费的AI知识星球