dicogis.georeaders.process_files module¶
- class dicogis.georeaders.process_files.DatasetToProcess(file_path, file_format, georeader, processed=False, process_error=None, exported=False, export_error=None)¶
Bases:
object
Model of a geofile to process.
- __init__(file_path, file_format, georeader, processed=False, process_error=None, exported=False, export_error=None)¶
- class dicogis.georeaders.process_files.ProcessingFiles(serializer, localized_strings, li_cdao, li_dxf, li_flat_geodatabase_esri_filegdb, li_flat_geodatabase_geopackage, li_flat_geodatabase_spatialite, li_geojson, li_geotiff, li_gxt, li_gml, li_kml, li_mapinfo_tab, li_shapefiles, li_vectors, li_rasters, li_file_databases, opt_analyze_esri_filegdb=True, opt_analyze_geojson=True, opt_analyze_geopackage=True, opt_analyze_geotiff=True, opt_analyze_gml=True, opt_analyze_gxt=True, opt_analyze_kml=True, opt_analyze_mapinfo_tab=True, opt_analyze_raster=True, opt_analyze_cdao=True, opt_analyze_shapefiles=True, opt_analyze_spatialite=True, progress_message_displayer=None, progress_counter=None, progress_callback_cmd=None, opt_quick_fail=False)¶
Bases:
object
Geofiles processor.
- MATRIX_FORMAT_GEOREADER = {'dxf': <class 'dicogis.georeaders.read_dxf.ReadCadDxf'>, 'esri_shapefile': <class 'dicogis.georeaders.read_vector_flat_dataset.ReadVectorFlatDataset'>, 'file_geodatabase_esri': <class 'dicogis.georeaders.read_vector_flat_geodatabase.ReadFlatDatabase'>, 'file_geodatabase_geopackage': <class 'dicogis.georeaders.read_vector_flat_geodatabase.ReadFlatDatabase'>, 'file_geodatabase_spatialite': <class 'dicogis.georeaders.read_vector_flat_geodatabase.ReadFlatDatabase'>, 'geojson': <class 'dicogis.georeaders.read_vector_flat_dataset.ReadVectorFlatDataset'>, 'geotiff': <class 'dicogis.georeaders.read_raster.ReadRasters'>, 'gml': <class 'dicogis.georeaders.read_vector_flat_dataset.ReadVectorFlatDataset'>, 'gxt': <class 'dicogis.georeaders.read_vector_flat_dataset.ReadVectorFlatDataset'>, 'kml': <class 'dicogis.georeaders.read_vector_flat_dataset.ReadVectorFlatDataset'>, 'mapinfo_tab': <class 'dicogis.georeaders.read_vector_flat_dataset.ReadVectorFlatDataset'>, 'raster': <class 'dicogis.georeaders.read_raster.ReadRasters'>}¶
- __init__(serializer, localized_strings, li_cdao, li_dxf, li_flat_geodatabase_esri_filegdb, li_flat_geodatabase_geopackage, li_flat_geodatabase_spatialite, li_geojson, li_geotiff, li_gxt, li_gml, li_kml, li_mapinfo_tab, li_shapefiles, li_vectors, li_rasters, li_file_databases, opt_analyze_esri_filegdb=True, opt_analyze_geojson=True, opt_analyze_geopackage=True, opt_analyze_geotiff=True, opt_analyze_gml=True, opt_analyze_gxt=True, opt_analyze_kml=True, opt_analyze_mapinfo_tab=True, opt_analyze_raster=True, opt_analyze_cdao=True, opt_analyze_shapefiles=True, opt_analyze_spatialite=True, progress_message_displayer=None, progress_counter=None, progress_callback_cmd=None, opt_quick_fail=False)¶
- add_files_to_process_queue(list_of_datasets, dataset_format)¶
Add dataset to the processing queue.
- Parameters:
- Return type:
- Returns:
list of files to process
- count_files_to_process()¶
Count number of files to process.
- Return type:
- Returns:
total of files to process
- export_metadataset(dataset_to_process, metadataset_to_serialize)¶
Serialize metadataset in a generic way.
- Parameters:
dataset_to_process (
DatasetToProcess
) – dataset to process used to store statusmetadataset_to_serialize (
MetaDataset
) – metadataset to serialize
- Return type:
- Returns:
dataset to process, metadataset or None if something went wrong
- process_datasets_in_queue()¶
Process datasets in queue.
- read_dataset(dataset_to_process)¶
Read dataset and store into metadataset.
- Parameters:
dataset_to_process (
DatasetToProcess
) – dataset path or URI to read- Return type:
- Returns:
dataset and metadataset, None if an error occurs