String split three ways

String str = new String;

1:   str.split("");

2: StringTokenizer method hasMoreTokens () nextToken () The default delimiter lot, such as spaces

3:StringUtils.delimitedListToStringArray(value,"-");

 

 

Incidentally comes a little

org.apache.commons in commons-lang3 in StringUtils.isNumeric () think digital is empty

boolean s = StringUtils.isNumeric("");

Guess you like

Origin www.cnblogs.com/senjiang/p/11262743.html