randomStrIncludeSpcial static method
生成指定长度或随机长度的随机字符串 将包含特殊字符
Implementation
static String randomStrIncludeSpcial({int? length}) {
var codeUnits =
List.generate(length ?? _random.nextInt(pow(2, 10).toInt()), (index) {
return _random.nextInt(33) + 89;
});
return String.fromCharCodes(codeUnits);
}