PROJ C++ API
Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
osgeo::proj::common::IdentifiedObject Class Reference

Identifications of a CRS-related object. More...

#include <common.hpp>

Inheritance diagram for osgeo::proj::common::IdentifiedObject:
Inheritance graph
[legend]
Collaboration diagram for osgeo::proj::common::IdentifiedObject:
Collaboration graph
[legend]

Public Member Functions

const metadata::IdentifierNNPtrname () PROJ_CONST_DECL
 Return the name of the object. More...
 
const std::string & nameStr () PROJ_CONST_DECL
 Return the name of the object. More...
 
const std::vector< metadata::IdentifierNNPtr > & identifiers () PROJ_CONST_DECL
 Return the identifier(s) of the object. More...
 
const std::vector< util::GenericNameNNPtr > & aliases () PROJ_CONST_DECL
 Return the alias(es) of the object.
 
const std::string & remarks () PROJ_CONST_DECL
 Return the remarks.
 
bool isDeprecated () PROJ_CONST_DECL
 Return whether the object is deprecated. More...
 
std::string alias () PROJ_CONST_DECL
 Return the (first) alias of the object as a string. More...
 
int getEPSGCode () PROJ_CONST_DECL
 Return the EPSG code. More...
 
bool isEPSG (int code) PROJ_CONST_DECL
 Return whether the object has a identifiers() in the EPSG code space.
 
- Public Member Functions inherited from osgeo::proj::util::IComparable
virtual bool isEquivalentTo (const IComparable *other, Criterion criterion=Criterion::STRICT) const =0
 Returns whether an object is equivalent to another one. More...
 

Static Public Member Functions

static IdentifiedObjectNNPtr create (const util::PropertyMap &properties)
 Instanciate a new IdentifiedObject. More...
 

Static Public Attributes

static const std::string NAME_KEY
 Key to set the name of a common::IdentifiedObject. More...
 
static const std::string IDENTIFIERS_KEY
 Key to set the identifier(s) of a common::IdentifiedObject. More...
 
static const std::string ALIAS_KEY
 Key to set the alias(es) of a common::IdentifiedObject. More...
 
static const std::string REMARKS_KEY
 Key to set the remarks of a common::IdentifiedObject. More...
 
static const std::string DEPRECATED_KEY
 Key to set the deprecation flag of a common::IdentifiedObject. More...
 

Additional Inherited Members

- Public Types inherited from osgeo::proj::util::IComparable
enum  Criterion { Criterion::STRICT, Criterion::EQUIVALENT }
 Comparison criterion. More...
 

Detailed Description

Identifications of a CRS-related object.

Remarks
Implements IdentifiedObject from ISO 19111:2018

Member Function Documentation

std::string osgeo::proj::common::IdentifiedObject::alias ( )

Return the (first) alias of the object as a string.

Shortcut for aliases()[0]->toFullyQualifiedName()->toString()

IdentifiedObjectNNPtr osgeo::proj::common::IdentifiedObject::create ( const util::PropertyMap properties)
static

Instanciate a new IdentifiedObject.

Parameters
propertiesSee General properties.
int osgeo::proj::common::IdentifiedObject::getEPSGCode ( )

Return the EPSG code.

Returns
code, or 0 if not found
const std::vector< IdentifierNNPtr > & osgeo::proj::common::IdentifiedObject::identifiers ( )

Return the identifier(s) of the object.

Generally, those will have Identifier::code() and Identifier::codeSpace() filled.

bool osgeo::proj::common::IdentifiedObject::isDeprecated ( )

Return whether the object is deprecated.

Remarks
Extension of ISO 19111:2018
const IdentifierNNPtr & osgeo::proj::common::IdentifiedObject::name ( )

Return the name of the object.

Generally, the only interesting field of the name will be name()->description().

const std::string & osgeo::proj::common::IdentifiedObject::nameStr ( )

Return the name of the object.

Return *(name()->description())

Member Data Documentation

const std::string osgeo::proj::common::IdentifiedObject::ALIAS_KEY
static

Key to set the alias(es) of a common::IdentifiedObject.

The value is to be provided as string, a util::GenericNameNNPtr or a util::ArrayOfBaseObjectNNPtr of util::GenericNameNNPtr.

const std::string osgeo::proj::common::IdentifiedObject::DEPRECATED_KEY
static

Key to set the deprecation flag of a common::IdentifiedObject.

The value is to be provided as a boolean.

const std::string osgeo::proj::common::IdentifiedObject::IDENTIFIERS_KEY
static

Key to set the identifier(s) of a common::IdentifiedObject.

The value is to be provided as a common::IdentifierNNPtr or a util::ArrayOfBaseObjectNNPtr of common::IdentifierNNPtr.

const std::string osgeo::proj::common::IdentifiedObject::NAME_KEY
static

Key to set the name of a common::IdentifiedObject.

The value is to be provided as a string or metadata::IdentifierNNPtr.

const std::string osgeo::proj::common::IdentifiedObject::REMARKS_KEY
static

Key to set the remarks of a common::IdentifiedObject.

The value is to be provided as a string.


The documentation for this class was generated from the following files: