Convert String[] to comma separated string in java
Android developers are probably looking for TextUtils.join
Android docs: http://developer.android.com/reference/android/text/TextUtils.html
Code:
String[] name = {"amit", "rahul", "surya"};
TextUtils.join(",",name)
Either write a simple method yourself, or use one of the various utilities out there.
Personally I use apache StringUtils (StringUtils.join)
edit: in Java 8, you don't need this at all anymore:
String joined = String.join(",", name);