FSchumacher commented on pull request #595:
URL: https://github.com/apache/jmeter/pull/595#issuecomment-637596512
...
> I'm not sure MessageFormat is a proper templating framework though: there
are no named parameters, so the template string would be awkward and it would
be hard to reason about :-/
Yes, I agree. MessageFormat might be hard to read, but
* it is better then my first implementation, which used `String#format`
which sucked even more ;)
* it can use formatting options for numbers, which is handy, as it allows
something like `{1,number,000}`
* other template languages might look like the JMeter built-in variable
replacement syntax or would have to be included (for the former I thought about
StringSubstitutor from commons-text)
Do you have a special templating system in mind, that we can/should use?
One idea would be to parse the format string and generate the three
placeholders à la `#{prefix} #{path} #{count,number,000}` -> `{0} {1}
{2,number,000}` via `s/#{count\b/{2/`, etc.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]