code: private static String join(Collection<?> args, String delim) {
          StringBuilder buf = new StringBuilder();
          for (Object arg : args) {
              if (buf.length()>0) buf.append(delim);
              buf.append(arg);
          }
          return buf.toString();
      }
docs: TODO: what's the better place for this?