Here you can find the source of isNumeric(final String str)
public static boolean isNumeric(final String str)
//package com.java2s; //License from project: Open Source License import java.text.NumberFormat; import java.text.ParsePosition; public class Main { public static boolean isNumeric(final String str) { final NumberFormat formatter = NumberFormat.getInstance(); final ParsePosition pos = new ParsePosition(0); formatter.parse(str, pos);/*from ww w . ja v a 2 s. c om*/ return str.length() == pos.getIndex(); } }