aboutsummaryrefslogtreecommitdiff
path: root/src/iso19111/io.cpp
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2019-03-24 20:01:45 +0100
committerEven Rouault <even.rouault@spatialys.com>2019-03-24 20:40:09 +0100
commit8763ea7f01bd349df29c5c4ce3b4edd6252eff37 (patch)
treea105baa2bb96e9474d618af3e4dba54f05338f7d /src/iso19111/io.cpp
parent3e37b354194b4d42acd247c32ca97e45ac40af1e (diff)
downloadPROJ-8763ea7f01bd349df29c5c4ce3b4edd6252eff37.tar.gz
PROJ-8763ea7f01bd349df29c5c4ce3b4edd6252eff37.zip
WKT2 parser: update to OGC 18-010r6
- Allow ID[] in base CRS of Derived CRS - Allow VERSION[] in non-conversion coordinate operations - Use VERSION[] to set operationVersion member of CoordinateOperation - Export operationVersion in WKT2:2018
Diffstat (limited to 'src/iso19111/io.cpp')
-rw-r--r--src/iso19111/io.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/iso19111/io.cpp b/src/iso19111/io.cpp
index a160a4e3..220ee967 100644
--- a/src/iso19111/io.cpp
+++ b/src/iso19111/io.cpp
@@ -1581,6 +1581,17 @@ PropertyMap &WKTParser::Private::buildProperties(const WKTNodeNNPtr &node,
}
}
+ auto &versionNode = nodeP->lookForChild(WKTConstants::VERSION);
+ if (!isNull(versionNode)) {
+ const auto &versionChildren = versionNode->GP()->children();
+ if (versionChildren.size() == 1) {
+ properties->set(CoordinateOperation::OPERATION_VERSION_KEY,
+ stripQuotes(versionChildren[0]));
+ } else {
+ ThrowNotRequiredNumberOfChildren(versionNode->GP()->value());
+ }
+ }
+
return *properties;
}