aboutsummaryrefslogtreecommitdiff
path: root/src/iso19111/io.cpp
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2019-03-24 19:01:45 +0000
committerEven Rouault <even.rouault@spatialys.com>2019-03-24 19:40:09 +0000
commit032c5efca97389eb49ab0b7fa729d80b995ef428 (patch)
tree78a562880431d4a487ea85994dbffafeb62518fd /src/iso19111/io.cpp
parent128421dd503bc89ec13fb151d8db4e06606d04da (diff)
downloadPROJ-032c5efca97389eb49ab0b7fa729d80b995ef428.tar.gz
PROJ-032c5efca97389eb49ab0b7fa729d80b995ef428.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 ef5c1589..c046f9de 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;
}