/** * Creates a cylindrical coordinate system from a code. * * @throws FactoryException if the object creation failed for all factories. */ @Override public CylindricalCS createCylindricalCS(final String code) throws FactoryException { try { return super.createCylindricalCS(code); } catch (FactoryException exception) { notifyFailure("createCylindricalCS", exception); try { return fallback.createCylindricalCS(code); } catch (NoSuchAuthorityCodeException ignore) { throw exception; } } }
/** Returns a cylindrical coordinate system from a code. */ @Override public synchronized CylindricalCS createCylindricalCS(final String code) throws FactoryException { final CylindricalCS cs; final String key = trimAuthority(code); final Object cached = objectCache.get(key); if (cached instanceof CylindricalCS) { cs = (CylindricalCS) cached; } else { cs = getBackingStore().createCylindricalCS(code); } objectCache.put(key, cs); return cs; }
/** * Returns a cylindrical coordinate system from a code. * * @throws FactoryException if the object creation failed. */ @Override public synchronized CylindricalCS createCylindricalCS(final String code) throws FactoryException { final CylindricalCS cs; final String key = trimAuthority(code); final Object cached = get(key); if (cached instanceof CylindricalCS) { cs = (CylindricalCS) cached; } else { cs = getBackingStore().createCylindricalCS(code); } put(key, cs); return cs; }