public
static
List<int> getDigit(String text) {
List<int> numlist =
new
ArrayList<int>();
Pattern p = Pattern.compile(
"(\\d+)"
);
Matcher m = p.matcher(text);
//尝试查找与该模式匹配的输入序列的下一个子序列
while
(m.find()) {
String find = m.group(
1
).toString();
nublist
ist.add(int.valueOf(find));
}
return
numlist;
}