CatalogPersistableReference

class geodetic_engine.persistablereference.CatalogPersistableReference[source]

Bases: object

A persistableReference a catalogue publishes, as proj.db recorded it.

identifier

The OSDU id of the record that publishes it, without the data partition, for example reference-data--CoordinateReferenceSystem:Projected:EPSG::23031.

table_name

The table of the object the id names, in the vocabulary of PROJ’s object_view, for example "projected_crs".

auth_name

The object’s authority, for example "EPSG".

code

The object’s code.

deprecated

Whether the catalogue marks the record inactive.

kind

The kind of definition the reference states.

name

The name the reference states, which is ESRI’s or the catalogue’s, not necessarily the object’s name in proj.db.

stated_authority

The authCode the reference states. Provenance: it can disagree with auth_name and code, and the build reports where it does.

version

The producer version the reference states, such as "PE_10_9_1".

sha256

Hex SHA-256 of payload, encoded as UTF-8.

source

The catalogue the build read it from.

payload

The reference, exactly as the catalogue published it.

property authority_code: str

The object’s "AUTH:CODE", as PROJ resolves it.

property is_crs: bool

Whether the object is a coordinate reference system.

property is_operation: bool

Whether the object is a coordinate operation.

pretty(*, indent=2, wkt=False)[source]

The reference laid out for reading.

Parameters:
  • indent (int, default: 2) – Spaces per level of nesting.

  • wkt (bool, default: False) – Also lay the embedded ESRI WKT out over indented lines. The result is then for reading only and is not JSON.

Return type:

str

Returns:

See pretty_persistable_reference().

parse()[source]

Read the reference, to build the CRS or operation it states.

Return type:

AnyReference

Returns:

The reference, as parse_persistable_reference() reads it.

as_dict(*, pretty=False)[source]

The reference and what is recorded about it, as an export entry.

Parameters:

pretty (bool, default: False) – Give the reference as its decoded JSON object rather than the string, so a JSON document embedding it reads naturally.

Return type:

dict[str, Any]

Returns:

A JSON-serialisable mapping with the keys of a CSV export.

__init__(identifier, table_name, auth_name, code, deprecated, kind, name, stated_authority, version, sha256, source, payload)