[PROJ] CRS aliases
Martin Desruisseaux
martin.desruisseaux at geomatys.com
Fri Jul 21 07:29:59 PDT 2023
Hello
Le 21/07/2023 à 15:34, Even Rouault a écrit :
> If I remember well, this part of the API was something I coded early
> in the PROJ 6 work, taking inspiration (and strugling to understand)
> from GeoAPI classes. Various classes GenericName, LocalName,
> NameFactory etc to deal with basically a string. So the API is there,
> there's minimum testing for it in test/unit/test_common.cpp, but it
> hasn't been really used for useful stuff.
The complexity come from the fact that aliases are defined in ISO 19111
as instances of GenericName, which is a class defined a bit succinctly
in ISO 19103. The main idea is that they are like file paths. For
example using ":" as a separator, a generic name could be
"IOGP:EPSG:SomeAlias", meaning that "SomeAlias" is a name defined in the
"EPSG" scope, which is itself defined in the "IOGP" scope. This is only
an example, actually I found few examples of scoped names (including in
EPSG database), so it is difficult to said what the established practice
is. Added to the fact that ISO 19103 makes a distinction between "scope"
and "namespace" but I found few guidance about what the distinction
should be, it makes GenericName a bit open to interpretation.
If desired, PROJ could use LocalName (a specialization of GenericName
containing only the "SomeAlias" tip of above example) and forget the
other classes for now. If PROJ is willing to do a little bit more
advanced implementation, they could declare "EPSG" (or other relevant
authority) as the scope of that LocalName.
Note: above discussion should not be confused with URN in OGC name
space, for example "urn:ogc:def:crs:EPSG::4326". Despite their
similarity, they are different objects in ISO models: GenericName for
the former, versus Identifier for the latter.
Martin
More information about the PROJ
mailing list