@Test public void testConvertNull() throws Exception { assertThatThrownBy(() -> converter.convert(null)) .isInstanceOf(IllegalArgumentException.class); }
@Override public URL convert(String s) throws IllegalArgumentException { try { return new URL(StringUtils.removeTrailingSlash(s)); } catch (MalformedURLException e) { throw new IllegalArgumentException(e.getMessage()); } }
UrlValueConverter extends AbstractValueConverter<URL> { @Override public URL convert(String s) throws IllegalArgumentException { try { return new URL(StringUtils.removeTrailingSlash(s)); } catch (MalformedURLException e) { throw new IllegalArgumentException(e.getMessage()); } } }
UrlValueConverter extends AbstractValueConverter<URL> { @Override public URL convert(String s) throws IllegalArgumentException { try { return new URL(StringUtils.removeTrailingSlash(s)); } catch (MalformedURLException e) { throw new IllegalArgumentException(e.getMessage()); } } private  UrlValueConverter(); }
UrlValueConverter extends AbstractValueConverter<URL> { @Override public URL convert(String s) throws IllegalArgumentException { try { return new URL(StringUtils.removeTrailingSlash(s)); } catch (MalformedURLException e) { throw new IllegalArgumentException(e.getMessage()); } } private  UrlValueConverter(); @Override URL convert(String s); @Override String toString(URL value); @Override String toSafeString(URL value); }
UrlValueConverter extends AbstractValueConverter<URL> { @Override public URL convert(String s) throws IllegalArgumentException { try { return new URL(StringUtils.removeTrailingSlash(s)); } catch (MalformedURLException e) { throw new IllegalArgumentException(e.getMessage()); } } private  UrlValueConverter(); @Override URL convert(String s); @Override String toString(URL value); @Override String toSafeString(URL value); static final ValueConverter<URL> INSTANCE; }