WCSUtil { public static boolean isOGC(String crs) { Matcher matcher = PATTERN_OGC_URN.matcher(crs); return matcher.matches(); }  static URI extractWCSBaseURI(URI wcsURI); static File generateTIFFFile(URI wcsURI, String wcsIdentifier, ReferencedEnvelope featureBounds, boolean requireFullCoverage, String outputFileDir); static boolean isOGC(String crs); static String convertCRSToNonOGC(String crs); final static Logger LOGGER; }
@Test public void testIsOGC_URN() { assertTrue(WCSUtil.isOGC("urn:ogc:def:crs:EPSG::4326")); assertTrue(WCSUtil.isOGC("urn:ogc-x:def:crs:EPSG::4326")); assertTrue(WCSUtil.isOGC("urn:x-ogc:def:crs:EPSG::4326")); assertTrue(WCSUtil.isOGC("urn:ogc:def:crs:EPSG::4326")); assertTrue(WCSUtil.isOGC("urn:ogc-x:def:crs:EPSG:6.9:4326")); assertTrue(WCSUtil.isOGC("urn:x-ogc:def:crs:EPSG:6.9:4326")); assertTrue(WCSUtil.isOGC("urn:ogc:def:crs:EPSG:6.9:4326")); assertFalse(WCSUtil.isOGC("EPSG:4326")); assertFalse(WCSUtil.isOGC("urn:ogc:def:crs:EPSG::4326:")); assertFalse(WCSUtil.isOGC("urn:y-ogc:def:crs:EPSG:6.9:4326")); assertFalse(WCSUtil.isOGC("urn:ogc-y:def:crs:EPSG:6.9:4326")); assertFalse(WCSUtil.isOGC("urn:cida:def:crs:EPSG::4326")); assertFalse(WCSUtil.isOGC("urn:cida-x:def:crs:EPSG::4326")); assertFalse(WCSUtil.isOGC("urn:x-cida:def:crs:EPSG::4326")); }