Added toStringSeparatedBy method in StringListUtils.

This commit is contained in:
Christian P. MOMON 2016-06-29 19:36:31 +02:00
parent 169b2702ed
commit cc33285f5f

View file

@ -495,6 +495,72 @@ public class StringListUtils
return result; return result;
} }
/**
*
* @param source
* @return
*/
public static String toStringSeparatedBy(final Collection<String> source, final String separator)
{
String result;
if (source == null)
{
result = null;
}
else
{
result = new StringList(source).toStringSeparatedBy(separator);
}
//
return result;
}
/**
*
* @param strings
* @return
*/
public static String toStringSeparatedBy(final String[] source, final String separator)
{
String result;
if (source == null)
{
result = null;
}
else
{
result = new StringList(source).toStringSeparatedBy(separator);
}
//
return result;
}
/**
*
* @param strings
* @return
*/
public static String toStringSeparatedBy(final StringList source, final String separator)
{
String result;
if (source == null)
{
result = null;
}
else
{
result = source.toStringSeparatedBy(separator);
}
//
return result;
}
/** /**
* *
* @param strings * @param strings