@Test public void testValidateBaseUrl() { OsmLayerParam params = new OsmLayerParam(); params.baseURL = "http: assertTrue(params.validateBaseUrl()); params.baseURL = "http: assertTrue(params.validateBaseUrl()); params.baseURL = "http: assertTrue(params.validateBaseUrl()); params.baseURL = "http: assertTrue(params.validateBaseUrl()); params.baseURL = "http: assertFalse(params.validateBaseUrl()); params.baseURL = "http: assertFalse(params.validateBaseUrl()); params.baseURL = "http: assertFalse(params.validateBaseUrl()); }
@Override public boolean validateBaseUrl() { String url = getBaseUrl(); if (StringUtils.isEmpty(url)) { return false; } url = url .replace("{z}", "0") .replace("{x}", "0") .replace("{y}", "0") .replace("{-y}", "0"); try { new URI(url); return true; } catch (URISyntaxException exc) { return false; } }
OsmLayerParam extends AbstractTiledLayerParams { @Override public boolean validateBaseUrl() { String url = getBaseUrl(); if (StringUtils.isEmpty(url)) { return false; } url = url .replace("{z}", "0") .replace("{x}", "0") .replace("{y}", "0") .replace("{-y}", "0"); try { new URI(url); return true; } catch (URISyntaxException exc) { return false; } } }
OsmLayerParam extends AbstractTiledLayerParams { @Override public boolean validateBaseUrl() { String url = getBaseUrl(); if (StringUtils.isEmpty(url)) { return false; } url = url .replace("{z}", "0") .replace("{x}", "0") .replace("{y}", "0") .replace("{-y}", "0"); try { new URI(url); return true; } catch (URISyntaxException exc) { return false; } }  }
OsmLayerParam extends AbstractTiledLayerParams { @Override public boolean validateBaseUrl() { String url = getBaseUrl(); if (StringUtils.isEmpty(url)) { return false; } url = url .replace("{z}", "0") .replace("{x}", "0") .replace("{y}", "0") .replace("{-y}", "0"); try { new URI(url); return true; } catch (URISyntaxException exc) { return false; } }  static Multimap<String, String> convertToMultiMap(final PObject objectParams); Multimap<String, String> getCustomParams(); void setCustomParam(final String name, final String value); void postConstruct(); Envelope getMaxExtent(); @Override String getBaseUrl(); Dimension getTileSize(); @Override String createCommonUrl(); @Override boolean validateBaseUrl(); }
OsmLayerParam extends AbstractTiledLayerParams { @Override public boolean validateBaseUrl() { String url = getBaseUrl(); if (StringUtils.isEmpty(url)) { return false; } url = url .replace("{z}", "0") .replace("{x}", "0") .replace("{y}", "0") .replace("{-y}", "0"); try { new URI(url); return true; } catch (URISyntaxException exc) { return false; } }  static Multimap<String, String> convertToMultiMap(final PObject objectParams); Multimap<String, String> getCustomParams(); void setCustomParam(final String name, final String value); void postConstruct(); Envelope getMaxExtent(); @Override String getBaseUrl(); Dimension getTileSize(); @Override String createCommonUrl(); @Override boolean validateBaseUrl(); public String baseURL; @HasDefaultValue
    public double[] maxExtent; @HasDefaultValue
    public int[] tileSize; @HasDefaultValue
    public Double[] resolutions; @HasDefaultValue
    public double resolutionTolerance; @HasDefaultValue
    public Double dpi; @HasDefaultValue
    public String imageExtension; @HasDefaultValue
    public PObject customParams; }