Java Comma Separated List toCommaSeparated(List list)

Here you can find the source of toCommaSeparated(List list)

Description

to Comma Separated

License

Open Source License

Declaration

public static String toCommaSeparated(List<String> list) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

import java.util.List;

public class Main {
    public static String toCommaSeparated(List<String> list) {
        StringBuilder sb = new StringBuilder();
        for (String property : list) {
            sb.append(property).append(",");
        }/*from w  ww .j  a  v a 2 s  . c om*/
        sb.deleteCharAt(sb.length() - 1);
        return sb.toString();
    }
}

Related

  1. stringToList(final String commaSeparated)
  2. stringToList(String commaSeparatedList)
  3. toCommaDelimited(List values)
  4. toCommaList(Collection items)
  5. toCommaSeparated(List list)
  6. toCommaSeparatedString(List list)
  7. toList(final String commaSeparatedString)
  8. toListDelimitedByComma(String s)
  9. toListOfNonEmptyStringsDelimitedByCommaOrSemicolon(String s)