From 6b2359cb3911b675bdad2bbf0b1780f000f5c93b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B8rn=20Erik=20Jensen?= Date: Wed, 29 Aug 2018 13:36:33 +0200 Subject: [PATCH] #3091 Completion export. Add WELSPECS/WELSPECL to exported file --- .../Application/Tools/RiaFilePathTools.cpp | 17 + .../Application/Tools/RiaFilePathTools.h | 1 + ...ellPathExportCompletionDataFeatureImpl.cpp | 370 +++++++++++++++--- ...cWellPathExportCompletionDataFeatureImpl.h | 32 +- .../Completions/RimWellPathCompletions.cpp | 45 +++ .../Completions/RimWellPathCompletions.h | 11 + .../ReservoirDataModel/RigEclipseCaseData.cpp | 24 ++ .../ReservoirDataModel/RigEclipseCaseData.h | 1 + 8 files changed, 444 insertions(+), 57 deletions(-) diff --git a/ApplicationCode/Application/Tools/RiaFilePathTools.cpp b/ApplicationCode/Application/Tools/RiaFilePathTools.cpp index 2e844daf74..0a02e89387 100644 --- a/ApplicationCode/Application/Tools/RiaFilePathTools.cpp +++ b/ApplicationCode/Application/Tools/RiaFilePathTools.cpp @@ -128,3 +128,20 @@ QString RiaFilePathTools::commonRootPath(const QStringList& paths) return paths.front().left(iDir + 1); } + +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +std::pair RiaFilePathTools::toFolderAndFileName(const QString& absFileName) +{ + auto absFN = toInternalSeparator(absFileName); + int lastSep = absFN.lastIndexOf(SEPARATOR); + if (lastSep > 0) + { + return std::make_pair(absFN.left(lastSep), absFN.mid(lastSep+1)); + } + else + { + return std::make_pair("", absFN); + } +} diff --git a/ApplicationCode/Application/Tools/RiaFilePathTools.h b/ApplicationCode/Application/Tools/RiaFilePathTools.h index 255a93e6f6..835857b757 100644 --- a/ApplicationCode/Application/Tools/RiaFilePathTools.h +++ b/ApplicationCode/Application/Tools/RiaFilePathTools.h @@ -40,4 +40,5 @@ public: static bool equalPaths(const QString& path1, const QString& path2); static QString canonicalPath(const QString& path); static QString commonRootPath(const QStringList& paths); + static std::pair toFolderAndFileName(const QString& absFileName); }; diff --git a/ApplicationCode/Commands/CompletionExportCommands/RicWellPathExportCompletionDataFeatureImpl.cpp b/ApplicationCode/Commands/CompletionExportCommands/RicWellPathExportCompletionDataFeatureImpl.cpp index da6287decf..993075a61b 100644 --- a/ApplicationCode/Commands/CompletionExportCommands/RicWellPathExportCompletionDataFeatureImpl.cpp +++ b/ApplicationCode/Commands/CompletionExportCommands/RicWellPathExportCompletionDataFeatureImpl.cpp @@ -21,6 +21,7 @@ #include "RiaApplication.h" #include "RiaLogging.h" #include "RiaPreferences.h" +#include "RiaFilePathTools.h" #include "RicExportCompletionDataSettingsUi.h" #include "RicExportFeatureImpl.h" @@ -40,7 +41,8 @@ #include "RigWellLogExtractor.h" #include "RigWellPath.h" #include "RigWellPathIntersectionTools.h" - + +#include "RimFileWellPath.h" #include "RimFishbonesCollection.h" #include "RimFishbonesMultipleSubs.h" #include "RimFractureTemplate.h" @@ -52,6 +54,7 @@ #include "RimWellPathCompletions.h" #include "RimWellPathFracture.h" #include "RimWellPathFractureCollection.h" +#include "RimProject.h" #include "RiuMainWindow.h" @@ -65,6 +68,21 @@ #include "RigVirtualPerforationTransmissibilities.h" #include +//-------------------------------------------------------------------------------------------------- +/// Internal functions +//-------------------------------------------------------------------------------------------------- +const RimWellPath* findWellPathFromExportName(const QString& wellNameForExport); + +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +class OpenFileException +{ +public: + OpenFileException(const QString &message) : message(message) {} + QString message; +}; + //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- @@ -895,6 +913,214 @@ RigCompletionData return resultCompletion; } +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +QFilePtr RicWellPathExportCompletionDataFeatureImpl::openFileForExport(const QString& fullFileName) +{ + std::pair folderAndFileName = RiaFilePathTools::toFolderAndFileName(fullFileName); + return openFileForExport(folderAndFileName.first, folderAndFileName.second); +} + +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +QFilePtr RicWellPathExportCompletionDataFeatureImpl::openFileForExport(const QString& folderName, const QString& fileName) +{ + QDir exportFolder = QDir(folderName); + if (!exportFolder.exists()) + { + bool createdPath = exportFolder.mkpath("."); + if (createdPath) + RiaLogging::info("Created export folder " + folderName); + else + { + auto errorMessage = QString("Selected output folder does not exist, and could not be created."); + RiaLogging::error(errorMessage); + throw OpenFileException(errorMessage); + } + } + + QString filePath = exportFolder.filePath(fileName); + QFilePtr exportFile(new QFile(filePath)); + if (!exportFile->open(QIODevice::WriteOnly)) + { + auto errorMessage = QString("Export Completions Data: Could not open the file: %1").arg(filePath); + RiaLogging::error(errorMessage); + throw OpenFileException(errorMessage); + } + return exportFile; +} + +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +std::vector +RicWellPathExportCompletionDataFeatureImpl::mainGridCompletions(std::vector& allCompletions) +{ + std::vector completions; + + for (const auto& completion : allCompletions) + { + QString gridName = completion.completionDataGridCell().lgrName(); + if (gridName.isEmpty()) + { + completions.push_back(completion); + } + } + return completions; +} + +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +std::map> +RicWellPathExportCompletionDataFeatureImpl::subGridsCompletions(std::vector& allCompletions) +{ + std::map> completions; + + for (const auto& completion : allCompletions) + { + QString gridName = completion.completionDataGridCell().lgrName(); + if (!gridName.isEmpty()) + { + auto it = completions.find(gridName); + if (it == completions.end()) + { + completions.insert( + std::pair>(gridName, {completion})); + } + else + { + it->second.push_back(completion); + } + } + } + return completions; +} + +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +void RicWellPathExportCompletionDataFeatureImpl::exportWelspecsToFile(RimEclipseCase* gridCase, + QFilePtr exportFile, + const std::vector& completions) +{ + QTextStream stream(exportFile.get()); + + RifEclipseDataTableFormatter formatter(stream); + formatter.setColumnSpacing(3); + + std::vector header = { + RifEclipseOutputTableColumn("Well"), + RifEclipseOutputTableColumn("Grp"), + RifEclipseOutputTableColumn("I"), + RifEclipseOutputTableColumn("J"), + RifEclipseOutputTableColumn("RefDpth"), + RifEclipseOutputTableColumn("WellType") + }; + + formatter.keyword("WELSPEC"); + formatter.header(header); + + std::set wellPathSet; + + // Build list of unique RimWellPath + for (const auto completion : completions) + { + const auto wellPath = findWellPathFromExportName(completion.wellName()); + if (wellPath) + { + wellPathSet.insert(wellPath); + } + } + + // Export + for (const auto wellPath : wellPathSet) + { + auto completions = wellPath->completions(); + cvf::Vec2i ijIntersection = wellPathUpperGridIntersectionIJ(gridCase, wellPath); + + formatter + .add(completions->wellNameForExport()) + .add(completions->wellGroupName()) + .addOneBasedCellIndex(ijIntersection.x()) + .addOneBasedCellIndex(ijIntersection.y()) + .add(completions->referenceDepth()) + .add(completions->wellTypeName()) + .rowCompleted(); + } + + formatter.tableCompleted(); +} + +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +void RicWellPathExportCompletionDataFeatureImpl::exportWelspeclToFile(RimEclipseCase* gridCase, + QFilePtr exportFile, + const std::map>& completions) +{ + QTextStream stream(exportFile.get()); + + RifEclipseDataTableFormatter formatter(stream); + formatter.setColumnSpacing(3); + + std::vector header = { + RifEclipseOutputTableColumn("Well"), + RifEclipseOutputTableColumn("Grp"), + RifEclipseOutputTableColumn("LGR"), + RifEclipseOutputTableColumn("I"), + RifEclipseOutputTableColumn("J"), + RifEclipseOutputTableColumn("RefDpth"), + RifEclipseOutputTableColumn("WellType") + }; + + formatter.keyword("WELSPECL"); + formatter.header(header); + + std::map> wellPathMap; + + // Build list of unique RimWellPath for each LGR + for (const auto completionsForLgr : completions) + { + wellPathMap.insert(std::make_pair(completionsForLgr.first, std::set())); + + for (const auto completion : completionsForLgr.second) + { + const auto wellPath = findWellPathFromExportName(completion.wellName()); + if (wellPath) + { + wellPathMap[completionsForLgr.first].insert(wellPath); + } + } + } + + for (const auto wellPathsForLgr : wellPathMap) + { + QString lgrName = wellPathsForLgr.first; + + // Export + for (const auto wellPath : wellPathsForLgr.second) + { + auto completions = wellPath->completions(); + cvf::Vec2i ijIntersection = wellPathUpperGridIntersectionIJ(gridCase, wellPath, lgrName); + + formatter + .add(completions->wellNameForExport()) + .add(completions->wellGroupName()) + .add(lgrName) + .addOneBasedCellIndex(ijIntersection.x()) + .addOneBasedCellIndex(ijIntersection.y()) + .add(completions->referenceDepth()) + .add(completions->wellTypeName()) + .rowCompleted(); + } + } + + formatter.tableCompleted(); +} + //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- @@ -907,46 +1133,41 @@ void RicWellPathExportCompletionDataFeatureImpl::sortAndExportCompletionsToFile( RicExportCompletionDataSettingsUi::CompdatExportType exportType) { // Sort completions based on grid they belong to - std::vector completionsForMainGrid; - - std::map> completionsForSubGrids; - - for (const auto& completion : completions) - { - QString gridName = completion.completionDataGridCell().lgrName(); - if (gridName.isEmpty()) - { - completionsForMainGrid.push_back(completion); - } - else - { - auto it = completionsForSubGrids.find(gridName); - if (it == completionsForSubGrids.end()) - { - completionsForSubGrids.insert( - std::pair>(gridName, std::vector{completion})); - } - else - { - it->second.push_back(completion); - } - } - } + std::vector completionsForMainGrid = mainGridCompletions(completions); + std::map> completionsForSubGrids = subGridsCompletions(completions); if (!completionsForMainGrid.empty()) { - std::map> completionsForGrid; - completionsForGrid.insert(std::pair>("", completionsForMainGrid)); + try + { + QFilePtr exportFile = openFileForExport(folderName, fileName); - exportCompdatAndWpimultTables( - eclipseCase, folderName, fileName, completionsForGrid, wellPathFractureReportItems, exportType); + std::map> completionsForGrid; + completionsForGrid.insert(std::pair>("", completionsForMainGrid)); + + exportWelspecsToFile(eclipseCase, exportFile, completionsForMainGrid); + + exportCompdatAndWpimultTables( + eclipseCase, exportFile, completionsForGrid, wellPathFractureReportItems, exportType); + } + catch(OpenFileException) + { } } if (!completionsForSubGrids.empty()) { - QString lgrFileName = fileName + "_LGR"; - exportCompdatAndWpimultTables( - eclipseCase, folderName, lgrFileName, completionsForSubGrids, wellPathFractureReportItems, exportType); + try + { + QString lgrFileName = fileName + "_LGR"; + QFilePtr exportFile = openFileForExport(folderName, lgrFileName); + + exportWelspeclToFile(eclipseCase, exportFile, completionsForSubGrids); + + exportCompdatAndWpimultTables( + eclipseCase, exportFile, completionsForSubGrids, wellPathFractureReportItems, exportType); + } + catch(OpenFileException) + { } } } @@ -955,33 +1176,14 @@ void RicWellPathExportCompletionDataFeatureImpl::sortAndExportCompletionsToFile( //-------------------------------------------------------------------------------------------------- void RicWellPathExportCompletionDataFeatureImpl::exportCompdatAndWpimultTables( RimEclipseCase* sourceCase, - const QString& folderName, - const QString& fileName, + QFilePtr exportFile, const std::map>& completionsPerGrid, const std::vector& wellPathFractureReportItems, RicExportCompletionDataSettingsUi::CompdatExportType exportType) { if (completionsPerGrid.empty()) return; - QDir exportFolder(folderName); - if (!exportFolder.exists()) - { - bool createdPath = exportFolder.mkpath("."); - if (createdPath) - RiaLogging::info("Created export folder " + folderName); - else - RiaLogging::error("Selected output folder does not exist, and could not be created."); - } - - QString filePath = exportFolder.filePath(fileName); - QFile exportFile(filePath); - if (!exportFile.open(QIODevice::WriteOnly)) - { - RiaLogging::error(QString("Export Completions Data: Could not open the file: %1").arg(filePath)); - return; - } - - QTextStream stream(&exportFile); + QTextStream stream(exportFile.get()); if (!wellPathFractureReportItems.empty()) { @@ -1032,7 +1234,7 @@ void RicWellPathExportCompletionDataFeatureImpl::exportCompdatAndWpimultTables( } } - RiaLogging::info(QString("Successfully exported completion data to %1").arg(filePath)); + RiaLogging::info(QString("Successfully exported completion data to %1").arg(exportFile->fileName())); } //-------------------------------------------------------------------------------------------------- @@ -1904,3 +2106,61 @@ double RicWellPathExportCompletionDataFeatureImpl::calculateTransmissibilityAsEc return trans; } + +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +cvf::Vec2i RicWellPathExportCompletionDataFeatureImpl::wellPathUpperGridIntersectionIJ(const RimEclipseCase* gridCase, + const RimWellPath* wellPath, + const QString& gridName) +{ + const RigEclipseCaseData* caseData = gridCase->eclipseCaseData(); + const RigMainGrid* mainGrid = caseData->mainGrid(); + const RigActiveCellInfo* activeCellInfo = caseData->activeCellInfo(RiaDefines::MATRIX_MODEL); + const RigWellPath* wellPathGeometry = wellPath->wellPathGeometry(); + const std::vector& coords = wellPathGeometry->wellPathPoints(); + const std::vector& mds = wellPathGeometry->measureDepths(); + CVF_ASSERT(!coords.empty() && !mds.empty()); + + std::vector intersections = + RigWellPathIntersectionTools::findCellIntersectionInfosAlongPath(caseData, coords, mds); + + size_t gridId = 0; + + if (!gridName.isEmpty()) + { + const auto grid = caseData->grid(gridName); + if (grid) gridId = grid->gridId(); + } + + for (WellPathCellIntersectionInfo intersection : intersections) + { + size_t gridLocalCellIndex = 0; + const RigGridBase* grid = mainGrid->gridAndGridLocalIdxFromGlobalCellIdx(intersection.globCellIndex, &gridLocalCellIndex); + + if (grid->gridId() == gridId && activeCellInfo->isActive(intersection.globCellIndex)) + { + size_t i, j, k; + if (grid->ijkFromCellIndex(gridLocalCellIndex, &i, &j, &k)) + { + return cvf::Vec2i((int)i, (int)j); + } + } + } + return cvf::Vec2i(); +} + + +//-------------------------------------------------------------------------------------------------- +/// Internal function +//-------------------------------------------------------------------------------------------------- +const RimWellPath* findWellPathFromExportName(const QString& wellNameForExport) +{ + auto allWellPaths = RiaApplication::instance()->project()->allWellPaths(); + + for (const auto wellPath : allWellPaths) + { + if (wellPath->completions()->wellNameForExport() == wellNameForExport) return wellPath; + } + return nullptr; +} diff --git a/ApplicationCode/Commands/CompletionExportCommands/RicWellPathExportCompletionDataFeatureImpl.h b/ApplicationCode/Commands/CompletionExportCommands/RicWellPathExportCompletionDataFeatureImpl.h index 8b5f097c0b..a6f7f4840a 100644 --- a/ApplicationCode/Commands/CompletionExportCommands/RicWellPathExportCompletionDataFeatureImpl.h +++ b/ApplicationCode/Commands/CompletionExportCommands/RicWellPathExportCompletionDataFeatureImpl.h @@ -24,10 +24,13 @@ #include "RicMultiSegmentWellExportInfo.h" #include "RicWellPathFractureReportItem.h" +#include + #include "cvfBase.h" #include "cvfVector3.h" #include +#include class RigCell; class RigEclipseCaseData; @@ -40,6 +43,11 @@ class RimWellPathFracture; class RifEclipseDataTableFormatter; class RigVirtualPerforationTransmissibilities; +//================================================================================================== +/// +//================================================================================================== +typedef std::shared_ptr QFilePtr; + //================================================================================================== /// //================================================================================================== @@ -118,6 +126,23 @@ private: static RigCompletionData combineEclipseCellCompletions(const std::vector& completions, const RicExportCompletionDataSettingsUi& settings); + static QFilePtr openFileForExport(const QString& fullFileName); + + static QFilePtr openFileForExport(const QString& folderName, + const QString& fileName); + + static std::vector mainGridCompletions(std::vector& allCompletions); + + static std::map> subGridsCompletions(std::vector& allCompletions); + + static void exportWelspecsToFile(RimEclipseCase* gridCase, + QFilePtr exportFile, + const std::vector& completions); + + static void exportWelspeclToFile(RimEclipseCase* gridCase, + QFilePtr exportFile, + const std::map>& completions); + static void sortAndExportCompletionsToFile(RimEclipseCase* eclipseCase, const QString& exportFolder, const QString& fileName, @@ -126,8 +151,9 @@ private: RicExportCompletionDataSettingsUi::CompdatExportType exportType); static void exportCompdatAndWpimultTables(RimEclipseCase* sourceCase, - const QString& folderName, - const QString& fileName, + QFilePtr exportFile, + //const QString& folderName, + //const QString& fileName, const std::map>& completionsPerGrid, const std::vector& wellPathFractureReportItems, RicExportCompletionDataSettingsUi::CompdatExportType exportType); @@ -163,4 +189,6 @@ private: static void appendCompletionData(std::map>* completionData, const std::vector& data); + + static cvf::Vec2i wellPathUpperGridIntersectionIJ(const RimEclipseCase* gridCase, const RimWellPath* wellPath, const QString& gridName = ""); }; diff --git a/ApplicationCode/ProjectDataModel/Completions/RimWellPathCompletions.cpp b/ApplicationCode/ProjectDataModel/Completions/RimWellPathCompletions.cpp index a8c0103521..247eb9968a 100644 --- a/ApplicationCode/ProjectDataModel/Completions/RimWellPathCompletions.cpp +++ b/ApplicationCode/ProjectDataModel/Completions/RimWellPathCompletions.cpp @@ -28,6 +28,21 @@ #include "cafPdmUiTreeOrdering.h" +namespace caf { + + template<> + void RimWellPathCompletions::WellTypeEnum::setUp() + { + addItem(RimWellPathCompletions::OIL, "OIL", "Oil"); + addItem(RimWellPathCompletions::GAS, "GAS", "Gas"); + addItem(RimWellPathCompletions::WATER, "WATER", "Water"); + addItem(RimWellPathCompletions::LIQUID, "LIQUID", "Liquid"); + + setDefault(RimWellPathCompletions::OIL); + } +} + + CAF_PDM_SOURCE_INIT(RimWellPathCompletions, "WellPathCompletions"); //-------------------------------------------------------------------------------------------------- @@ -50,6 +65,12 @@ RimWellPathCompletions::RimWellPathCompletions() m_fractureCollection.uiCapability()->setUiHidden(true); CAF_PDM_InitField(&m_wellNameForExport, "WellNameForExport", QString(), "Well Name for Completion Export", "", "", ""); + + CAF_PDM_InitField(&m_wellGroupName, "WellGroupNameForExport", QString(), "Well Group Name for Completion Export", "", "", ""); + + CAF_PDM_InitField(&m_referenceDepth, "ReferenceDepthForExport", QString(), "Reference Depth for Completion Export", "", "", ""); + + CAF_PDM_InitField(&m_wellType, "WellTypeForExport", WellTypeEnum(), "Well Type for Completion Export", "", "", ""); } //-------------------------------------------------------------------------------------------------- @@ -88,6 +109,30 @@ QString RimWellPathCompletions::wellNameForExport() const return m_wellNameForExport(); } +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +QString RimWellPathCompletions::wellGroupName() const +{ + return m_wellGroupName; +} + +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +QString RimWellPathCompletions::referenceDepth() const +{ + return m_referenceDepth; +} + +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +QString RimWellPathCompletions::wellTypeName() const +{ + return WellTypeEnum(m_wellType).uiText(); +} + //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- diff --git a/ApplicationCode/ProjectDataModel/Completions/RimWellPathCompletions.h b/ApplicationCode/ProjectDataModel/Completions/RimWellPathCompletions.h index 04ec0c37fd..957038e15f 100644 --- a/ApplicationCode/ProjectDataModel/Completions/RimWellPathCompletions.h +++ b/ApplicationCode/ProjectDataModel/Completions/RimWellPathCompletions.h @@ -26,6 +26,7 @@ class RimFishbonesCollection; class RimPerforationCollection; class RimWellPathFractureCollection; + //================================================================================================== /// /// @@ -34,6 +35,9 @@ class RimWellPathCompletions : public caf::PdmObject { CAF_PDM_HEADER_INIT; + enum WellType {OIL, GAS, WATER, LIQUID}; + typedef caf::AppEnum WellTypeEnum; + public: RimWellPathCompletions(); @@ -43,6 +47,9 @@ public: void setWellNameForExport(const QString& name); QString wellNameForExport() const; + QString wellGroupName() const; + QString referenceDepth() const; + QString wellTypeName() const; bool hasCompletions() const; void setUnitSystemSpecificDefaults(); @@ -56,4 +63,8 @@ private: caf::PdmChildField m_fractureCollection; caf::PdmField m_wellNameForExport; + caf::PdmField m_wellGroupName; + + caf::PdmField m_referenceDepth; + caf::PdmField m_wellType; }; diff --git a/ApplicationCode/ReservoirDataModel/RigEclipseCaseData.cpp b/ApplicationCode/ReservoirDataModel/RigEclipseCaseData.cpp index 95fd8f54f1..c61253611d 100644 --- a/ApplicationCode/ReservoirDataModel/RigEclipseCaseData.cpp +++ b/ApplicationCode/ReservoirDataModel/RigEclipseCaseData.cpp @@ -151,6 +151,30 @@ RigGridBase* RigEclipseCaseData::grid(size_t index) return m_mainGrid->gridByIndex(index); } +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +const RigGridBase* RigEclipseCaseData::grid(const QString& gridName) const +{ + if (m_mainGrid.isNull()) + { + return nullptr; + } + + if (gridName.isEmpty()) + { + return m_mainGrid.p(); + } + + size_t i; + for (i = 0; i < m_mainGrid->gridCount(); i++) + { + const RigGridBase* grid = m_mainGrid->gridByIndex(i); + if (QString::fromStdString(grid->gridName()) == gridName) return grid; + } + return nullptr; +} + //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- diff --git a/ApplicationCode/ReservoirDataModel/RigEclipseCaseData.h b/ApplicationCode/ReservoirDataModel/RigEclipseCaseData.h index 1b760d8cd3..6ec7ae135d 100644 --- a/ApplicationCode/ReservoirDataModel/RigEclipseCaseData.h +++ b/ApplicationCode/ReservoirDataModel/RigEclipseCaseData.h @@ -71,6 +71,7 @@ public: const RigGridBase* grid(size_t index) const; RigGridBase* grid(size_t index); size_t gridCount() const; + const RigGridBase* grid(const QString& gridName) const; RigCaseCellResultsData* results(RiaDefines::PorosityModelType porosityModel); const RigCaseCellResultsData* results(RiaDefines::PorosityModelType porosityModel) const;