Code example for NumberFormat

Methods: parse

0
	 */ 
	public static Number parseNumber(final String number,
		final NumberFormat format)
	{ 
		try { 
			return format.parse(number);
		} 
		catch (final ParseException exc) {
			final NumberFormatException nfe = new NumberFormatException();
			nfe.initCause(exc);
			throw nfe;
		} 
	} 
 
	/** 
	 * Parses a {@link Number} from the given string, respecting the default 
	 * {@link Locale}. 
	 *  
	 * @throws NumberFormatException if the number cannot be parsed 
	 */ 
Stop searching for code, let great code find you!  Add Codota to your java IDE