class GeoPackageDataEnsurer {

    public void ensureData(Set<String> imports)
    {
        for (String importFile : imports)
        {
            LOGGER.info("Verifying geopackage file is cached for " + importFile);
            File theFile = new File(importFile);
            if (theFile.exists())
            {
                DataModelCategory category = new DataModelCategory(importFile, null, null);
                DefaultQuery layerQuery = new DefaultQuery(category, New.collection());
                long[] ids = myRegistry.performLocalQuery(layerQuery);
                if (ids == null || ids.length <= 0)
                {
                    LOGGER.info("Could not find geopackage file in cache reimporting " + importFile);
                    myRegistry.removeModels(category, false);
                    myImporter.importFile(theFile, null);
                }
                else
                {
                    LOGGER.info("Geopackage file is cached for " + importFile);
                }
            }
        }
    }

    public  GeoPackageDataEnsurer(FileOrURLImporter importer, DataRegistry registry);

}