@Test public void shouldBeAbleToConvertIntegerNumbers() { assertThat(converter.convert("3", BigInteger.class, bundle), is(equalTo(new BigInteger("3")))); }
public BigInteger convert(String value, Class<? extends BigInteger> type, ResourceBundle bundle) { if (isNullOrEmpty(value)) { return null; } try { return new BigInteger(value); } catch (NumberFormatException e) { throw new ConversionError(MessageFormat.format(bundle.getString("is_not_a_valid_integer"), value)); } }
BigIntegerConverter implements Converter<BigInteger> { public BigInteger convert(String value, Class<? extends BigInteger> type, ResourceBundle bundle) { if (isNullOrEmpty(value)) { return null; } try { return new BigInteger(value); } catch (NumberFormatException e) { throw new ConversionError(MessageFormat.format(bundle.getString("is_not_a_valid_integer"), value)); } } }
BigIntegerConverter implements Converter<BigInteger> { public BigInteger convert(String value, Class<? extends BigInteger> type, ResourceBundle bundle) { if (isNullOrEmpty(value)) { return null; } try { return new BigInteger(value); } catch (NumberFormatException e) { throw new ConversionError(MessageFormat.format(bundle.getString("is_not_a_valid_integer"), value)); } }  }
BigIntegerConverter implements Converter<BigInteger> { public BigInteger convert(String value, Class<? extends BigInteger> type, ResourceBundle bundle) { if (isNullOrEmpty(value)) { return null; } try { return new BigInteger(value); } catch (NumberFormatException e) { throw new ConversionError(MessageFormat.format(bundle.getString("is_not_a_valid_integer"), value)); } }  BigInteger convert(String value, Class<? extends BigInteger> type, ResourceBundle bundle); }
BigIntegerConverter implements Converter<BigInteger> { public BigInteger convert(String value, Class<? extends BigInteger> type, ResourceBundle bundle) { if (isNullOrEmpty(value)) { return null; } try { return new BigInteger(value); } catch (NumberFormatException e) { throw new ConversionError(MessageFormat.format(bundle.getString("is_not_a_valid_integer"), value)); } }  BigInteger convert(String value, Class<? extends BigInteger> type, ResourceBundle bundle);  }