MCPcopy Create free account
hub / github.com/OSGeo/PROJ / getUnitDatabaseType

Function getUnitDatabaseType

src/iso19111/factory.cpp:1753–1771  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1751// ---------------------------------------------------------------------------
1752
1753static const char *getUnitDatabaseType(const common::UnitOfMeasure &unit) {
1754 switch (unit.type()) {
1755 case common::UnitOfMeasure::Type::LINEAR:
1756 return "length";
1757
1758 case common::UnitOfMeasure::Type::ANGULAR:
1759 return "angle";
1760
1761 case common::UnitOfMeasure::Type::SCALE:
1762 return "scale";
1763
1764 case common::UnitOfMeasure::Type::TIME:
1765 return "time";
1766
1767 default:
1768 break;
1769 }
1770 return nullptr;
1771}
1772
1773// ---------------------------------------------------------------------------
1774

Callers 2

identifyMethod · 0.85
identifyOrInsertMethod · 0.85

Calls 1

typeMethod · 0.80

Tested by

no test coverage detected