there is a method in String class that can help you convert it,
but you should give this method the regex , in your case regex is ","
you can use this method to convert it:
public String[] convertToArray(String str, String regex){
return str.split(regex);
}
String[] str = convertToArray(str, ",");