Joing the values together in a comma separated list
@param values The values to join
@return The combined values
962752
protected String join(List<String> values)
    {
        StringBuilder sb = new StringBuilder(100);
        if(values.size() == 0)
            return sb.toString();

        sb.append(values.get(0));

        if(values.size() == 1)
            return sb.toString();

        for (int i = 1; i < values.size(); i++)
        {
            sb.append(",").append(values.get(i));
        }

        return sb.toString();
    }
1062157
public static String join(List<String> list, String separator) {
        if (list == null) {
            return null;
        }

        return join(list.toArray(), separator, 0, list.size());
    }
449002
public static Set<String> parseParameterList(String values) {
		Set<String> result = new TreeSet<String>();
		if (values != null && values.trim().length() > 0) {
			// the spec says the scope is separated by spaces
			String[] tokens = values.split("[\\s+]");
			result.addAll(Arrays.asList(tokens));
		}
		return result;
	}
327598
@SafeVarargs
    public static <T> List<T> newLists(T... values) {
        if(null == values || values.length == 0){
            Assert.notNull(values, "values not is null.");
        }
        return Arrays.asList(values);
    }
222506
public String join(List<String> list) {

        if (list == null) {
            return null;
        }

        StringBuilder sb = new StringBuilder();
        boolean first = true;
        for (String s : list) {

            if (s == null) {
                if (convertEmptyToNull) {
                    s = "";
                } else {
                    throw new IllegalArgumentException("StringListFlattener does not support null strings in the list. Consider calling setConvertEmptyToNull(true).");
                }
            }

            if (!first) {
                sb.append(separator);
            }

            for (int i = 0; i < s.length(); i++) {
                char c = s.charAt(i);
                if (c == escapeChar || c == separator) {
                    sb.append(escapeChar);
                }
                sb.append(c);
            }

            first = false;
        }
        return sb.toString();
    }
251809
@SafeVarargs
    public final List<V> putValues(String name, V... values) {
        List<V> list = new ArrayList<>();
        list.addAll(Arrays.asList(values));
        return super.put(name, list);
    }
987956
public static String join(Collection<?> objects, String separator) {
        String result = null;

        if (objects.size() > 0) {
            for (Object object : objects) {
                if (result == null) {
                    result = object.toString();
                } else {
                    result += separator + object.toString();
                }
            }
        } else {
            result = "";
        }

        return result;
    }
511756
public static String join(String joint, String... values) {
		final StringBuilder b = new StringBuilder();
		for (final String value : values) {
			if (value != null && !EMPTY_STRING.equals(value)) {
				if (b.length() > 0) {
					b.append(joint);
				}
				b.append(value);
			}
		}
		return b.toString();
	}
1175579
public static String join(String[] strings, String separator) {
      StringBuilder sb = new StringBuilder();
      boolean first = true;
      for (String s : strings) {
         if (first) {
            first = false;
         } else {
            sb.append(separator);
         }
         sb.append(s);
      }
      return sb.toString();
   }
62159
public static <T> String join(String delimiter, Collection<T> strings) {
        StringBuilder builder = new StringBuilder();
        boolean first = true;
        for (T o : strings) {
            if (first) {
                first = false;
            } else {
                builder.append(delimiter);
            }
            builder.append(Objects.toString(o));
        }
        return builder.toString();
    }
334998
public static String join(final Iterable<?> elements, final char separator) {
        return Joiner.on(separator).skipNulls().join(elements);
    }
408135
public static String join(String _delimiter, String[] _strings) {
        return join(_delimiter, Arrays.asList(_strings));
    }
1257131
public static <T> List<T> list(T... values) {
        return new ArrayList<T>(Arrays.asList(values));
    }
1205177
public static String join(Collection<String> collection, String separator) {
        if (collection == null) {
            return null;
        }
        return join(collection.toArray(new String[collection.size()]), separator, 0, collection.size());
    }
351917
private static <T> List<T> join(List<T> list1, List<T> list2) {
        return list1.appendList(list2);
    }
1085485
public static Double[] wrap(double... values) {
		if (null == values) {
			return null;
		}
		final int length = values.length;
		if (0 == length) {
			return new Double[0];
		}

		final Double[] array = new Double[length];
		for (int i = 0; i < length; i++) {
			array[i] = Double.valueOf(values[i]);
		}
		return array;
	}
350987
public static String joiningWithDelimiter(CharSequence delimiter,
            List<String> stringList) {
        return joiningWith(stringList.stream(), delimiter);
    }