Here you can find the source of join(Enumeration enumeration, String s)
public static String join(Enumeration enumeration, String s)
//package com.java2s; //License from project: Open Source License import java.util.*; public class Main { public static String join(Enumeration enumeration, String s) { StringBuffer stringbuffer = new StringBuffer(); while (enumeration.hasMoreElements()) { String s1 = (String) enumeration.nextElement(); stringbuffer.append(s1);/*w ww . j a v a 2 s.c o m*/ if (enumeration.hasMoreElements()) { stringbuffer.append(s); } } return stringbuffer.toString(); } }