mirror of
https://github.com/apache/cloudstack.git
synced 2025-12-15 18:12:35 +01:00
String concatenation cleanup
Replaced string concatenation in loop with StringBuilder Signed-off-by: Laszlo Hornyak <laszlo.hornyak@gmail.com>
This commit is contained in:
parent
8e3ae40ba2
commit
74a3cb4d5e
@ -90,11 +90,11 @@ public class QemuImg {
|
|||||||
|
|
||||||
if (options != null && !options.isEmpty()) {
|
if (options != null && !options.isEmpty()) {
|
||||||
s.add("-o");
|
s.add("-o");
|
||||||
String optionsStr = "";
|
final StringBuilder optionsStr = new StringBuilder();
|
||||||
for (Map.Entry<String, String> option : options.entrySet()) {
|
for (Map.Entry<String, String> option : options.entrySet()) {
|
||||||
optionsStr += option.getKey() + "=" + option.getValue() + ",";
|
optionsStr.append(option.getKey()).append('=').append(option.getValue()).append(',');
|
||||||
}
|
}
|
||||||
s.add(optionsStr);
|
s.add(optionsStr.toString());
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user