ProjDbBuildConfig¶
- class geodetic_engine.projdb.ProjDbBuildConfig[source]¶
Bases:
objectResolved configuration for one custom proj.db build.
- georepository¶
Connection settings for the source register.
- authorities¶
Authority names whose objects are imported. Only rows whose
auth_nameis in this set may be written to the database.
- output_db¶
Path the enriched database is written to.
- base_proj_db¶
Official proj.db used as the starting point.
- naming_systems¶
Naming systems whose aliases are imported. Defaults to
authorities.
- include_deprecated¶
Import deprecated objects, flagged as deprecated and linked to their replacements. Enabled by default so that callers can answer “this code is deprecated, superseded by X” rather than “unknown code”.
- unsupported_method_codes¶
EPSG method codes to skip.
- authority_preference¶
How custom authorities enter operation selection.
- annotate_foreign_objects¶
Import this authority’s aliases and usages for objects owned by another authority, such as a local name for an EPSG CRS. Requires enumerating every CRS in the register rather than only this authority’s, so it is the slowest part of a build; the objects themselves are never rewritten.
- fallback_authorities¶
Authorities listed after the custom ones in every generated preference row.
- append¶
Add to the database already at
output_dbinstead of starting from a fresh copy ofbase_proj_db, so a second source can extend what a first one built. Has no effect when the output does not exist yet. Disabled by default: a build that silently added to whatever happened to be at the output path could not be reproduced from its configuration alone.
- replace¶
Publish over an output database built by authorities this build does not import, discarding it. Disabled by default, so running one source after another cannot silently drop the other’s import. Not read from the config file: discarding a built database is a decision for the run that does it.
- overwrite_rows¶
Replace a row this build collides with rather than aborting. Reaches only the configured
authorities, since the per-row authority guard runs first and every object table is keyed on(auth_name, code). Disabled by default, so a collision is a reported failure rather than a definition that changed underneath whoever was already using it.
- georepository_version¶
Optional Georepository version name to record.
- cache_mode¶
What to do with the local cache of register responses. Enabled by default, since a build is almost entirely network wait and nearly every object it fetches is unchanged since the last one.
- cache_db¶
Where that cache is kept. Defaults to a sidecar of
output_db, so each built database carries its own.
- source_file¶
The config file the settings were read from, if any.
- __init__(georepository, authorities, output_db, base_proj_db, naming_systems=frozenset({}), include_deprecated=True, unsupported_method_codes=frozenset({1044, 1108}), authority_preference=AuthorityPreference.CUSTOM_FIRST, annotate_foreign_objects=True, fallback_authorities=('PROJ', 'EPSG'), append=False, replace=False, overwrite_rows=False, georepository_version=None, cache_mode=CacheMode.USE, cache_db=None, source_file=None)¶