public static String join ( Collection < ? extends Object > lst , String separator ) { StringBuilder buf = new StringBuilder ( lst . size ( ) * 64 ) ; boolean first = true ; for ( Object value : lst ) { if ( first ) first = false ; else buf . append ( separator ) ; buf . append ( value . toString ( ) ) ; } return buf . toString ( ) ; }
Concatenates a list of objects using the given separator .