目前在随机变量中我可以在变量的输出格式中加上前缀或后缀.然而,这个不错的功能不适用于简单的计数器控制器.每次当我使用变量时连接字符串+ $ {counter}不是一个很好的选择,因为我做了很多.
有没有办法以随机变量的方式实现前缀+计数器呢?
谢谢.
您是在谈论计数器配置元素吗?
如果是这样,可以使用数字格式属性:
看:
Format Optional format, e.g. 000 will format as 001, 002 etc.
This is passed to DecimalFormat, so any valid formats can be used.
If there is a problem interpreting the format, then it is ignored.
[The default format is generated using Long.toString()]
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
7322 次 |
最近记录: |