Fixed StringSet.toString to use comma as separator.

This commit is contained in:
Christian P. MOMON 2015-09-21 12:42:50 +02:00
parent 6984f9fbfc
commit e8e29cb938

View file

@ -190,7 +190,14 @@ public class StringSet extends HashSet<String>
{ {
StringSet result; StringSet result;
String merge = this.toString(); StringBuffer buffer = new StringBuffer(length());
for (String string : this)
{
buffer.append(string);
}
String merge = buffer.toString();
clear(); clear();
add(merge); add(merge);
@ -382,14 +389,7 @@ public class StringSet extends HashSet<String>
{ {
String result; String result;
StringBuffer buffer = new StringBuffer(length()); result = toStringList().toStringWithCommas();
for (String string : this)
{
buffer.append(string);
}
result = buffer.toString();
// //
return result; return result;