mirror of
https://github.com/OPM/ResInsight.git
synced 2026-10-26 15:10:22 -05:00
Modernize well pick reader and RigWellPathFormations, add tests
Return values instead of out-parameters, and move the error dialog from the reader to the importer so the reader can be unit tested. Fix crash in level detection when erasing while iterating.
This commit is contained in:
1 parent
91e2e4d575
commit
cf36012cd2
9 files changed
+589
-622
No files matched your search
@@ -20,9 +20,8 @@
|
||||
|
||||
#include "Well/RigWellPathFormations.h"
|
||||
|
||||
#include <expected>
|
||||
#include <map>
|
||||
#include <utility>
|
||||
#include <vector>
|
||||
|
||||
#include <QString>
|
||||
|
||||
@@ -32,14 +31,8 @@
|
||||
class RifWellPathFormationReader
|
||||
{
|
||||
public:
|
||||
static std::map<QString, RigWellPathFormations> readWellFormationsToGeometry( const QString& filePath );
|
||||
using WellFormations = std::map<QString /*wellName*/, RigWellPathFormations>;
|
||||
|
||||
private:
|
||||
static void readFile( const QString& filePath,
|
||||
std::vector<QString>* wellNames,
|
||||
std::vector<QString>* formationNames,
|
||||
std::vector<double>* mdTop,
|
||||
std::vector<double>* mdBase,
|
||||
std::vector<double>* tvdTop,
|
||||
std::vector<double>* tvdBase );
|
||||
static std::expected<WellFormations, QString> readWellFormations( const QString& filePath );
|
||||
static std::expected<WellFormations, QString> parseWellFormations( const QString& content, const QString& filePath );
|
||||
};
|
||||
Reference in new issue
Block a user