1.使用split函数,将字符串按"."分开,写法如下:

String str = "a.b.c";

String[] items = str.split("\\.");

posted on 2015-01-21 13:48  guoxiang  阅读(169)  评论(0编辑  收藏  举报