final Map<String, List<MultiDimensionalNumericData>> constraintsPerIndexId = new HashMap<>(); constraintsPerIndexId.put(index.getName(), constraints); return new CrsCache(queryGeometry, constraintsPerIndexId); } else { if (crs == null) { new HashMap<>(); constraintsPerIndexId.put(index.getName(), indexConstraints); return new CrsCache(indexCrsQueryGeometry, constraintsPerIndexId); } catch (final FactoryException e) { LOGGER.warn("Unable to create coordinate reference system transform", e); final Map<String, List<MultiDimensionalNumericData>> constraintsPerIndexId = new HashMap<>(); constraintsPerIndexId.put(index.getName(), constraints); return new CrsCache(queryGeometry, constraintsPerIndexId);