aboutsummaryrefslogtreecommitdiff
path: root/src/iso19111/internal.cpp
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2019-05-07 11:39:48 +0200
committerGitHub <noreply@github.com>2019-05-07 11:39:48 +0200
commit850050693a25843d6ae69492cfad72f7753e39f7 (patch)
tree4d464df04190ae115e7f54259457286d22580eb9 /src/iso19111/internal.cpp
parent4636df33ed4d2a9bedf19973d58a42858fb816c0 (diff)
parentd4ffaca08a4f2ef3475165c2634561ee9bf01885 (diff)
downloadPROJ-850050693a25843d6ae69492cfad72f7753e39f7.tar.gz
PROJ-850050693a25843d6ae69492cfad72f7753e39f7.zip
Merge pull request #1454 from rouault/fix_ETRS89_3D_to_proj_string_with_geoidgrids_nadgrids
createOperations(): fix case of ETRS89 3D to proj string with nadgrids and geoidgrids
Diffstat (limited to 'src/iso19111/internal.cpp')
-rw-r--r--src/iso19111/internal.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/iso19111/internal.cpp b/src/iso19111/internal.cpp
index 240c98f4..4810202d 100644
--- a/src/iso19111/internal.cpp
+++ b/src/iso19111/internal.cpp
@@ -298,6 +298,21 @@ std::vector<std::string> split(const std::string &str, char separator) {
// ---------------------------------------------------------------------------
+std::vector<std::string> split(const std::string &str,
+ const std::string &separator) {
+ std::vector<std::string> res;
+ size_t lastPos = 0;
+ size_t newPos = 0;
+ while ((newPos = str.find(separator, lastPos)) != std::string::npos) {
+ res.push_back(str.substr(lastPos, newPos - lastPos));
+ lastPos = newPos + separator.size();
+ }
+ res.push_back(str.substr(lastPos));
+ return res;
+}
+
+// ---------------------------------------------------------------------------
+
#ifdef _WIN32
// For some reason, sqlite3_snprintf() in the sqlite3 builds used on AppVeyor