diff --git a/ApplicationCode/Application/RIApplication.cpp b/ApplicationCode/Application/RIApplication.cpp index dc2e5ba83a..c3737622d2 100644 --- a/ApplicationCode/Application/RIApplication.cpp +++ b/ApplicationCode/Application/RIApplication.cpp @@ -273,7 +273,7 @@ bool RIApplication::loadProject(const QString& projectFileName) // Now load the ReservoirViews for the cases - std::vector casesToLoad; + std::vector casesToLoad; // Add all "native" cases in the project for (size_t cIdx = 0; cIdx < m_project->reservoirs().size(); ++cIdx) @@ -286,7 +286,7 @@ bool RIApplication::loadProject(const QString& projectFileName) { if (m_project->caseGroups[cgIdx]->statisticsCaseCollection()) { - caf::PdmPointersField & statCases = m_project->caseGroups[cgIdx]->statisticsCaseCollection()->reservoirs(); + caf::PdmPointersField & statCases = m_project->caseGroups[cgIdx]->statisticsCaseCollection()->reservoirs(); for (size_t scIdx = 0; scIdx < statCases.size(); ++scIdx) { casesToLoad.push_back(statCases[scIdx]); @@ -298,7 +298,7 @@ bool RIApplication::loadProject(const QString& projectFileName) for (size_t cIdx = 0; cIdx < casesToLoad.size(); ++cIdx) { - RimReservoir* ri = casesToLoad[cIdx]; + RimCase* ri = casesToLoad[cIdx]; CVF_ASSERT(ri); caseProgress.setProgressDescription(ri->caseName()); @@ -494,7 +494,7 @@ bool RIApplication::openEclipseCase(const QString& caseName, const QString& case QFileInfo gridFileName(caseFileName); QString casePath = gridFileName.absolutePath(); - RimResultReservoir* rimResultReservoir = new RimResultReservoir(); + RimResultCase* rimResultReservoir = new RimResultCase(); rimResultReservoir->caseName = caseName; rimResultReservoir->caseFileName = caseFileName; rimResultReservoir->caseDirectory = casePath; @@ -529,7 +529,7 @@ bool RIApplication::openEclipseCase(const QString& caseName, const QString& case //-------------------------------------------------------------------------------------------------- bool RIApplication::openInputEclipseCase(const QString& caseName, const QStringList& caseFileNames) { - RimInputReservoir* rimInputReservoir = new RimInputReservoir(); + RimInputCase* rimInputReservoir = new RimInputCase(); rimInputReservoir->caseName = caseName; rimInputReservoir->openDataFileSet(caseFileNames); @@ -1189,7 +1189,7 @@ void RIApplication::saveSnapshotForAllViews(const QString& snapshotFolderName) for (size_t i = 0; i < m_project->reservoirs().size(); ++i) { - RimReservoir* ri = m_project->reservoirs()[i]; + RimCase* ri = m_project->reservoirs()[i]; if (!ri) continue; for (size_t j = 0; j < ri->reservoirViews().size(); j++) @@ -1360,7 +1360,7 @@ bool RIApplication::addEclipseCases(const QStringList& fileNames) // First file is read completely including grid. // The main grid from the first case is reused directly in for the other cases. // When reading active cell info, only the total cell count is tested for consistency - RigEclipseCase* mainEclipseCase = NULL; + RigCaseData* mainEclipseCase = NULL; { QString firstFileName = fileNames[0]; @@ -1369,7 +1369,7 @@ bool RIApplication::addEclipseCases(const QStringList& fileNames) QString caseName = gridFileName.completeBaseName(); QString casePath = gridFileName.absolutePath(); - RimResultReservoir* rimResultReservoir = new RimResultReservoir(); + RimResultCase* rimResultReservoir = new RimResultCase(); rimResultReservoir->caseName = caseName; rimResultReservoir->caseFileName = firstFileName; rimResultReservoir->caseDirectory = casePath; @@ -1396,7 +1396,7 @@ bool RIApplication::addEclipseCases(const QStringList& fileNames) QString caseName = gridFileName.completeBaseName(); QString casePath = gridFileName.absolutePath(); - RimResultReservoir* rimResultReservoir = new RimResultReservoir(); + RimResultCase* rimResultReservoir = new RimResultCase(); rimResultReservoir->caseName = caseName; rimResultReservoir->caseFileName = fileName; rimResultReservoir->caseDirectory = casePath; diff --git a/ApplicationCode/Application/RIApplication.h b/ApplicationCode/Application/RIApplication.h index 4073593ad7..29992ec3d6 100644 --- a/ApplicationCode/Application/RIApplication.h +++ b/ApplicationCode/Application/RIApplication.h @@ -30,8 +30,8 @@ #include "RimProject.h" class RIProcess; -class RigEclipseCase; -class RimReservoir; +class RigCaseData; +class RimCase; class Drawable; class RiaSocketServer; class RIPreferences; diff --git a/ApplicationCode/FileInterface/FileInterface_UnitTests/RifReaderEclipseOutput-Test.cpp b/ApplicationCode/FileInterface/FileInterface_UnitTests/RifReaderEclipseOutput-Test.cpp index bb81b1f16d..797507e7af 100644 --- a/ApplicationCode/FileInterface/FileInterface_UnitTests/RifReaderEclipseOutput-Test.cpp +++ b/ApplicationCode/FileInterface/FileInterface_UnitTests/RifReaderEclipseOutput-Test.cpp @@ -247,7 +247,7 @@ TEST(RigReservoirTest, BasicTest) TEST(RigReservoirTest, WellTest) { cvf::ref readerInterfaceEcl = new RifReaderEclipseOutput; - cvf::ref reservoir = new RigEclipseCase; + cvf::ref reservoir = new RigCaseData; // Location of test dataset received from Håkon Høgstøl in July 2011 with 10k active cells #ifdef WIN32 diff --git a/ApplicationCode/FileInterface/RifEclipseInputFileTools.cpp b/ApplicationCode/FileInterface/RifEclipseInputFileTools.cpp index bcb4c98d57..482f55456e 100644 --- a/ApplicationCode/FileInterface/RifEclipseInputFileTools.cpp +++ b/ApplicationCode/FileInterface/RifEclipseInputFileTools.cpp @@ -61,7 +61,7 @@ RifEclipseInputFileTools::~RifEclipseInputFileTools() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RifEclipseInputFileTools::openGridFile(const QString& fileName, RigEclipseCase* eclipseCase) +bool RifEclipseInputFileTools::openGridFile(const QString& fileName, RigCaseData* eclipseCase) { CVF_ASSERT(eclipseCase); @@ -176,7 +176,7 @@ bool RifEclipseInputFileTools::openGridFile(const QString& fileName, RigEclipseC //-------------------------------------------------------------------------------------------------- /// Read known properties from the input file //-------------------------------------------------------------------------------------------------- -std::map RifEclipseInputFileTools::readProperties(const QString &fileName, RigEclipseCase *reservoir) +std::map RifEclipseInputFileTools::readProperties(const QString &fileName, RigCaseData *reservoir) { CVF_ASSERT(reservoir); @@ -282,7 +282,7 @@ std::vector< RifKeywordAndFilePos > RifEclipseInputFileTools::findKeywordsOnFile /// Reads the property data requested into the \a reservoir, overwriting any previous /// propeties with the same name. //-------------------------------------------------------------------------------------------------- -bool RifEclipseInputFileTools::readProperty(const QString& fileName, RigEclipseCase* eclipseCase, const QString& eclipseKeyWord, const QString& resultName) +bool RifEclipseInputFileTools::readProperty(const QString& fileName, RigCaseData* eclipseCase, const QString& eclipseKeyWord, const QString& resultName) { CVF_ASSERT(eclipseCase); @@ -370,7 +370,7 @@ const std::vector& RifEclipseInputFileTools::knownPropertyKeywords() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RifEclipseInputFileTools::writePropertyToTextFile(const QString& fileName, RigEclipseCase* eclipseCase, size_t timeStep, const QString& resultName, const QString& eclipseKeyWord) +bool RifEclipseInputFileTools::writePropertyToTextFile(const QString& fileName, RigCaseData* eclipseCase, size_t timeStep, const QString& resultName, const QString& eclipseKeyWord) { CVF_ASSERT(eclipseCase); @@ -402,7 +402,7 @@ bool RifEclipseInputFileTools::writePropertyToTextFile(const QString& fileName, /// Create and write a result vector with values for all cells. /// undefinedValue is used for cells with no result //-------------------------------------------------------------------------------------------------- -bool RifEclipseInputFileTools::writeBinaryResultToTextFile(const QString& fileName, RigEclipseCase* eclipseCase, RifReaderInterface::PorosityModelResultType porosityModel, size_t timeStep, const QString& resultName, const QString& eclipseKeyWord, const double undefinedValue) +bool RifEclipseInputFileTools::writeBinaryResultToTextFile(const QString& fileName, RigCaseData* eclipseCase, RifReaderInterface::PorosityModelResultType porosityModel, size_t timeStep, const QString& resultName, const QString& eclipseKeyWord, const double undefinedValue) { CVF_ASSERT(eclipseCase); @@ -519,7 +519,7 @@ void RifEclipseInputFileTools::findGridKeywordPositions(const QString& filename, //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RifEclipseInputFileTools::readPropertyAtFilePosition(const QString& fileName, RigEclipseCase* eclipseCase, const QString& eclipseKeyWord, qint64 filePos, const QString& resultName) +bool RifEclipseInputFileTools::readPropertyAtFilePosition(const QString& fileName, RigCaseData* eclipseCase, const QString& eclipseKeyWord, qint64 filePos, const QString& resultName) { CVF_ASSERT(eclipseCase); diff --git a/ApplicationCode/FileInterface/RifEclipseInputFileTools.h b/ApplicationCode/FileInterface/RifEclipseInputFileTools.h index f78c29c734..7d0116a29b 100644 --- a/ApplicationCode/FileInterface/RifEclipseInputFileTools.h +++ b/ApplicationCode/FileInterface/RifEclipseInputFileTools.h @@ -27,7 +27,7 @@ #include "RifReaderInterface.h" -class RigEclipseCase; +class RigCaseData; class QFile; @@ -52,19 +52,19 @@ public: RifEclipseInputFileTools(); virtual ~RifEclipseInputFileTools(); - static bool openGridFile(const QString& fileName, RigEclipseCase* eclipseCase); + static bool openGridFile(const QString& fileName, RigCaseData* eclipseCase); // Returns map of assigned resultName and Eclipse Keyword. - static std::map readProperties(const QString& fileName, RigEclipseCase* eclipseCase); - static bool readProperty (const QString& fileName, RigEclipseCase* eclipseCase, const QString& eclipseKeyWord, const QString& resultName ); - static bool readPropertyAtFilePosition (const QString& fileName, RigEclipseCase* eclipseCase, const QString& eclipseKeyWord, qint64 filePos, const QString& resultName ); + static std::map readProperties(const QString& fileName, RigCaseData* eclipseCase); + static bool readProperty (const QString& fileName, RigCaseData* eclipseCase, const QString& eclipseKeyWord, const QString& resultName ); + static bool readPropertyAtFilePosition (const QString& fileName, RigCaseData* eclipseCase, const QString& eclipseKeyWord, qint64 filePos, const QString& resultName ); static std::vector< RifKeywordAndFilePos > findKeywordsOnFile(const QString &fileName); static const std::vector& knownPropertyKeywords(); - static bool writePropertyToTextFile(const QString& fileName, RigEclipseCase* eclipseCase, size_t timeStep, const QString& resultName, const QString& eclipseKeyWord); - static bool writeBinaryResultToTextFile(const QString& fileName, RigEclipseCase* eclipseCase, RifReaderInterface::PorosityModelResultType porosityModel, size_t timeStep, const QString& resultName, const QString& eclipseKeyWord, const double undefinedValue); + static bool writePropertyToTextFile(const QString& fileName, RigCaseData* eclipseCase, size_t timeStep, const QString& resultName, const QString& eclipseKeyWord); + static bool writeBinaryResultToTextFile(const QString& fileName, RigCaseData* eclipseCase, RifReaderInterface::PorosityModelResultType porosityModel, size_t timeStep, const QString& resultName, const QString& eclipseKeyWord, const double undefinedValue); private: static void writeDataToTextFile(QFile* file, const QString& eclipseKeyWord, const std::vector& resultData); diff --git a/ApplicationCode/FileInterface/RifReaderEclipseInput.cpp b/ApplicationCode/FileInterface/RifReaderEclipseInput.cpp index 11fb5512e5..41cd834951 100644 --- a/ApplicationCode/FileInterface/RifReaderEclipseInput.cpp +++ b/ApplicationCode/FileInterface/RifReaderEclipseInput.cpp @@ -57,7 +57,7 @@ RifReaderEclipseInput::~RifReaderEclipseInput() //-------------------------------------------------------------------------------------------------- /// Open file and read geometry into given reservoir object //-------------------------------------------------------------------------------------------------- -bool RifReaderEclipseInput::open(const QString& fileName, RigEclipseCase* eclipseCase) +bool RifReaderEclipseInput::open(const QString& fileName, RigCaseData* eclipseCase) { CVF_ASSERT(eclipseCase); diff --git a/ApplicationCode/FileInterface/RifReaderEclipseInput.h b/ApplicationCode/FileInterface/RifReaderEclipseInput.h index 840dba0b96..32499507e4 100644 --- a/ApplicationCode/FileInterface/RifReaderEclipseInput.h +++ b/ApplicationCode/FileInterface/RifReaderEclipseInput.h @@ -32,7 +32,7 @@ public: virtual ~RifReaderEclipseInput(); // Virtual interface implementation - virtual bool open(const QString& fileName, RigEclipseCase* eclipseCase); + virtual bool open(const QString& fileName, RigCaseData* eclipseCase); diff --git a/ApplicationCode/FileInterface/RifReaderEclipseOutput.cpp b/ApplicationCode/FileInterface/RifReaderEclipseOutput.cpp index c15f589038..5f3153b794 100644 --- a/ApplicationCode/FileInterface/RifReaderEclipseOutput.cpp +++ b/ApplicationCode/FileInterface/RifReaderEclipseOutput.cpp @@ -231,7 +231,7 @@ void RifReaderEclipseOutput::close() //-------------------------------------------------------------------------------------------------- /// Read geometry from file given by name into given reservoir object //-------------------------------------------------------------------------------------------------- -bool RifReaderEclipseOutput::transferGeometry(const ecl_grid_type* mainEclGrid, RigEclipseCase* eclipseCase) +bool RifReaderEclipseOutput::transferGeometry(const ecl_grid_type* mainEclGrid, RigCaseData* eclipseCase) { CVF_ASSERT(eclipseCase); @@ -337,7 +337,7 @@ bool RifReaderEclipseOutput::transferGeometry(const ecl_grid_type* mainEclGrid, //-------------------------------------------------------------------------------------------------- /// Open file and read geometry into given reservoir object //-------------------------------------------------------------------------------------------------- -bool RifReaderEclipseOutput::open(const QString& fileName, RigEclipseCase* eclipseCase) +bool RifReaderEclipseOutput::open(const QString& fileName, RigCaseData* eclipseCase) { CVF_ASSERT(eclipseCase); caf::ProgressInfo progInfo(100, ""); @@ -394,7 +394,7 @@ bool RifReaderEclipseOutput::open(const QString& fileName, RigEclipseCase* eclip //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RifReaderEclipseOutput::openAndReadActiveCellData(const QString& fileName, const std::vector& mainCaseTimeSteps, RigEclipseCase* eclipseCase) +bool RifReaderEclipseOutput::openAndReadActiveCellData(const QString& fileName, const std::vector& mainCaseTimeSteps, RigCaseData* eclipseCase) { CVF_ASSERT(eclipseCase); @@ -544,8 +544,8 @@ bool RifReaderEclipseOutput::buildMetaData() progInfo.incrementProgress(); - RigReservoirCellResults* matrixModelResults = m_eclipseCase->results(RifReaderInterface::MATRIX_RESULTS); - RigReservoirCellResults* fractureModelResults = m_eclipseCase->results(RifReaderInterface::FRACTURE_RESULTS); + RigCaseCellResultsData* matrixModelResults = m_eclipseCase->results(RifReaderInterface::MATRIX_RESULTS); + RigCaseCellResultsData* fractureModelResults = m_eclipseCase->results(RifReaderInterface::FRACTURE_RESULTS); if (m_dynamicResultsAccess.notNull()) { @@ -741,7 +741,7 @@ void RifReaderEclipseOutput::readWellCells() std::vector grids; m_eclipseCase->allGrids(&grids); - cvf::Collection wells; + cvf::Collection wells; caf::ProgressInfo progress(well_info_get_num_wells(ert_well_info), ""); int wellIdx; @@ -750,7 +750,7 @@ void RifReaderEclipseOutput::readWellCells() const char* wellName = well_info_iget_well_name(ert_well_info, wellIdx); CVF_ASSERT(wellName); - cvf::ref wellResults = new RigWellResults; + cvf::ref wellResults = new RigSingleWellResultsData; wellResults->m_wellName = wellName; well_ts_type* ert_well_time_series = well_info_get_ts(ert_well_info , wellName); diff --git a/ApplicationCode/FileInterface/RifReaderEclipseOutput.h b/ApplicationCode/FileInterface/RifReaderEclipseOutput.h index d902795935..8217b58ca5 100644 --- a/ApplicationCode/FileInterface/RifReaderEclipseOutput.h +++ b/ApplicationCode/FileInterface/RifReaderEclipseOutput.h @@ -43,14 +43,14 @@ public: RifReaderEclipseOutput(); virtual ~RifReaderEclipseOutput(); - bool open(const QString& fileName, RigEclipseCase* eclipseCase); - virtual bool openAndReadActiveCellData(const QString& fileName, const std::vector& mainCaseTimeSteps, RigEclipseCase* eclipseCase); + bool open(const QString& fileName, RigCaseData* eclipseCase); + virtual bool openAndReadActiveCellData(const QString& fileName, const std::vector& mainCaseTimeSteps, RigCaseData* eclipseCase); void close(); bool staticResult(const QString& result, PorosityModelResultType matrixOrFracture, std::vector* values); bool dynamicResult(const QString& result, PorosityModelResultType matrixOrFracture, size_t stepIndex, std::vector* values); - static bool transferGeometry(const ecl_grid_type* mainEclGrid, RigEclipseCase* eclipseCase); + static bool transferGeometry(const ecl_grid_type* mainEclGrid, RigCaseData* eclipseCase); private: bool readActiveCellInfo(); @@ -71,7 +71,7 @@ private: QString m_fileName; // Name of file used to start accessing Eclipse output files QStringList m_fileSet; // Set of files in filename's path with same base name as filename - RigEclipseCase* m_eclipseCase; + RigCaseData* m_eclipseCase; std::vector m_timeSteps; diff --git a/ApplicationCode/FileInterface/RifReaderInterface.h b/ApplicationCode/FileInterface/RifReaderInterface.h index 0ad153db1f..7b947f9468 100644 --- a/ApplicationCode/FileInterface/RifReaderInterface.h +++ b/ApplicationCode/FileInterface/RifReaderInterface.h @@ -27,7 +27,7 @@ #include -class RigEclipseCase; +class RigCaseData; //================================================================================================== // @@ -47,7 +47,7 @@ public: RifReaderInterface() {} virtual ~RifReaderInterface() {} - virtual bool open(const QString& fileName, RigEclipseCase* eclipseCase) = 0; + virtual bool open(const QString& fileName, RigCaseData* eclipseCase) = 0; virtual void close() = 0; virtual bool staticResult(const QString& result, PorosityModelResultType matrixOrFracture, std::vector* values) = 0; diff --git a/ApplicationCode/FileInterface/RifReaderMockModel.cpp b/ApplicationCode/FileInterface/RifReaderMockModel.cpp index 49de1cb07b..1fe0b2d44b 100644 --- a/ApplicationCode/FileInterface/RifReaderMockModel.cpp +++ b/ApplicationCode/FileInterface/RifReaderMockModel.cpp @@ -25,13 +25,13 @@ //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RifReaderMockModel::open(const QString& fileName, RigEclipseCase* eclipseCase) +bool RifReaderMockModel::open(const QString& fileName, RigCaseData* eclipseCase) { m_reservoirBuilder.populateReservoir(eclipseCase); m_reservoir = eclipseCase; - RigReservoirCellResults* cellResults = eclipseCase->results(RifReaderInterface::MATRIX_RESULTS); + RigCaseCellResultsData* cellResults = eclipseCase->results(RifReaderInterface::MATRIX_RESULTS); std::vector dates; @@ -170,7 +170,7 @@ void RifReaderMockModel::addLocalGridRefinement(const cvf::Vec3st& minCellPositi //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RifReaderMockModel::populateReservoir(RigEclipseCase* eclipseCase) +void RifReaderMockModel::populateReservoir(RigCaseData* eclipseCase) { m_reservoirBuilder.populateReservoir(eclipseCase); } diff --git a/ApplicationCode/FileInterface/RifReaderMockModel.h b/ApplicationCode/FileInterface/RifReaderMockModel.h index b2e4f1cbd4..0237381bbe 100644 --- a/ApplicationCode/FileInterface/RifReaderMockModel.h +++ b/ApplicationCode/FileInterface/RifReaderMockModel.h @@ -33,17 +33,17 @@ public: void addLocalGridRefinement(const cvf::Vec3st& minCellPosition, const cvf::Vec3st& maxCellPosition, const cvf::Vec3st& singleCellRefinementFactors); - virtual bool open( const QString& fileName, RigEclipseCase* eclipseCase ); + virtual bool open( const QString& fileName, RigCaseData* eclipseCase ); virtual void close(); virtual bool staticResult( const QString& result, RifReaderInterface::PorosityModelResultType matrixOrFracture, std::vector* values ); virtual bool dynamicResult( const QString& result, RifReaderInterface::PorosityModelResultType matrixOrFracture, size_t stepIndex, std::vector* values ); private: - void populateReservoir(RigEclipseCase* eclipseCase); + void populateReservoir(RigCaseData* eclipseCase); bool inputProperty( const QString& propertyName, std::vector* values ); RigReservoirBuilderMock m_reservoirBuilder; - RigEclipseCase* m_reservoir; + RigCaseData* m_reservoir; }; diff --git a/ApplicationCode/ModelVisualization/RivCellEdgeEffectGenerator.cpp b/ApplicationCode/ModelVisualization/RivCellEdgeEffectGenerator.cpp index fc640b69ab..3ffce80792 100644 --- a/ApplicationCode/ModelVisualization/RivCellEdgeEffectGenerator.cpp +++ b/ApplicationCode/ModelVisualization/RivCellEdgeEffectGenerator.cpp @@ -96,7 +96,7 @@ void RivCellEdgeGeometryGenerator::addCellEdgeResultsToDrawableGeo( const RigGridBase* grid = dynamic_cast(generator->activeGrid()); CVF_ASSERT(grid != NULL); - RigEclipseCase* eclipseCase = cellResultSlot->reservoirView()->eclipseCase()->reservoirData(); + RigCaseData* eclipseCase = cellResultSlot->reservoirView()->eclipseCase()->reservoirData(); CVF_ASSERT(eclipseCase != NULL); cvf::ref cellCenterDataAccessObject = NULL; @@ -108,7 +108,7 @@ void RivCellEdgeGeometryGenerator::addCellEdgeResultsToDrawableGeo( timeStepIndex = 0; } - RifReaderInterface::PorosityModelResultType porosityModel = RigReservoirCellResults::convertFromProjectModelPorosityModel(cellResultSlot->porosityModel()); + RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResultSlot->porosityModel()); cellCenterDataAccessObject = eclipseCase->dataAccessObject(grid, porosityModel, timeStepIndex, cellResultSlot->gridScalarIndex()); } diff --git a/ApplicationCode/ModelVisualization/RivGridPartMgr.cpp b/ApplicationCode/ModelVisualization/RivGridPartMgr.cpp index bed02b5a73..52fc9a050f 100644 --- a/ApplicationCode/ModelVisualization/RivGridPartMgr.cpp +++ b/ApplicationCode/ModelVisualization/RivGridPartMgr.cpp @@ -221,9 +221,9 @@ void RivGridPartMgr::updateCellResultColor(size_t timeStepIndex, RimResultSlot* size_t resTimeStepIdx = timeStepIndex; if (cellResultSlot->hasStaticResult()) resTimeStepIdx = 0; - RifReaderInterface::PorosityModelResultType porosityModel = RigReservoirCellResults::convertFromProjectModelPorosityModel(cellResultSlot->porosityModel()); + RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResultSlot->porosityModel()); - RigEclipseCase* eclipseCase = cellResultSlot->reservoirView()->eclipseCase()->reservoirData(); + RigCaseData* eclipseCase = cellResultSlot->reservoirView()->eclipseCase()->reservoirData(); cvf::ref dataAccessObject = eclipseCase->dataAccessObject(m_grid.p(), porosityModel, resTimeStepIdx, scalarSetIndex); if (dataAccessObject.isNull()) return; diff --git a/ApplicationCode/ModelVisualization/RivReservoirPartMgr.cpp b/ApplicationCode/ModelVisualization/RivReservoirPartMgr.cpp index 9d6be7e290..a7c48f705b 100644 --- a/ApplicationCode/ModelVisualization/RivReservoirPartMgr.cpp +++ b/ApplicationCode/ModelVisualization/RivReservoirPartMgr.cpp @@ -26,7 +26,7 @@ //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RivReservoirPartMgr::clearAndSetReservoir(const RigEclipseCase* eclipseCase) +void RivReservoirPartMgr::clearAndSetReservoir(const RigCaseData* eclipseCase) { m_allGrids.clear(); if (eclipseCase) diff --git a/ApplicationCode/ModelVisualization/RivReservoirPartMgr.h b/ApplicationCode/ModelVisualization/RivReservoirPartMgr.h index 601558216f..58d4dc08f6 100644 --- a/ApplicationCode/ModelVisualization/RivReservoirPartMgr.h +++ b/ApplicationCode/ModelVisualization/RivReservoirPartMgr.h @@ -30,7 +30,7 @@ namespace cvf class RimResultSlot; class RimCellEdgeResultSlot; class RivGridPartMgr; -class RigEclipseCase; +class RigCaseData; //================================================================================================== @@ -43,7 +43,7 @@ class RigEclipseCase; class RivReservoirPartMgr: public cvf::Object { public: - void clearAndSetReservoir(const RigEclipseCase* eclipseCase); + void clearAndSetReservoir(const RigCaseData* eclipseCase); void setTransform(cvf::Transform* scaleTransform); void setCellVisibility(size_t gridIndex, cvf::UByteArray* cellVisibilities ); diff --git a/ApplicationCode/ModelVisualization/RivReservoirViewPartMgr.cpp b/ApplicationCode/ModelVisualization/RivReservoirViewPartMgr.cpp index a0ddb2ac74..95020a38bd 100644 --- a/ApplicationCode/ModelVisualization/RivReservoirViewPartMgr.cpp +++ b/ApplicationCode/ModelVisualization/RivReservoirViewPartMgr.cpp @@ -125,7 +125,7 @@ void RivReservoirViewPartMgr::scheduleGeometryRegen(ReservoirGeometryCacheType g //-------------------------------------------------------------------------------------------------- void RivReservoirViewPartMgr::clearGeometryCache(ReservoirGeometryCacheType geomType) { - RigEclipseCase* eclipseCase = NULL; + RigCaseData* eclipseCase = NULL; if (m_reservoirView != NULL && m_reservoirView->eclipseCase()) { eclipseCase = m_reservoirView->eclipseCase()->reservoirData(); @@ -224,7 +224,7 @@ void RivReservoirViewPartMgr::appendDynamicGeometryPartsToModel(cvf::ModelBasicL //-------------------------------------------------------------------------------------------------- void RivReservoirViewPartMgr::createGeometry(ReservoirGeometryCacheType geometryType) { - RigEclipseCase* res = m_reservoirView->eclipseCase()->reservoirData(); + RigCaseData* res = m_reservoirView->eclipseCase()->reservoirData(); m_geometries[geometryType].clearAndSetReservoir(res); m_geometries[geometryType].setTransform(m_scaleTransform.p()); std::vector grids; @@ -246,7 +246,7 @@ void RivReservoirViewPartMgr::createGeometry(ReservoirGeometryCacheType geometry //-------------------------------------------------------------------------------------------------- void RivReservoirViewPartMgr::computeVisibility(cvf::UByteArray* cellVisibility, ReservoirGeometryCacheType geometryType, RigGridBase* grid, size_t gridIdx) { - RigEclipseCase* eclipseCase = m_reservoirView->eclipseCase()->reservoirData(); + RigCaseData* eclipseCase = m_reservoirView->eclipseCase()->reservoirData(); RigActiveCellInfo* activeCellInfo = m_reservoirView->currentActiveCellInfo(); switch (geometryType) @@ -370,7 +370,7 @@ void RivReservoirViewPartMgr::computeVisibility(cvf::UByteArray* cellVisibility, //-------------------------------------------------------------------------------------------------- void RivReservoirViewPartMgr::createPropertyFilteredGeometry(size_t frameIndex) { - RigEclipseCase* res = m_reservoirView->eclipseCase()->reservoirData(); + RigCaseData* res = m_reservoirView->eclipseCase()->reservoirData(); if ( frameIndex >= m_propFilteredGeometryFrames.size()) { @@ -418,7 +418,7 @@ void RivReservoirViewPartMgr::createPropertyFilteredGeometry(size_t frameIndex) //-------------------------------------------------------------------------------------------------- void RivReservoirViewPartMgr::createPropertyFilteredWellGeometry(size_t frameIndex) { - RigEclipseCase* res = m_reservoirView->eclipseCase()->reservoirData(); + RigCaseData* res = m_reservoirView->eclipseCase()->reservoirData(); if ( frameIndex >= m_propFilteredWellGeometryFrames.size()) { @@ -606,8 +606,8 @@ void RivReservoirViewPartMgr::computePropertyVisibility(cvf::UByteArray* cellVis const RimCellFilter::FilterModeType filterType = (*pfIt)->filterMode(); - RifReaderInterface::PorosityModelResultType porosityModel = RigReservoirCellResults::convertFromProjectModelPorosityModel((*pfIt)->resultDefinition()->porosityModel()); - RigEclipseCase* eclipseCase = propFilterColl->reservoirView()->eclipseCase()->reservoirData(); + RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel((*pfIt)->resultDefinition()->porosityModel()); + RigCaseData* eclipseCase = propFilterColl->reservoirView()->eclipseCase()->reservoirData(); cvf::ref dataAccessObject = eclipseCase->dataAccessObject(grid, porosityModel, timeStepIndex, scalarResultIndex); CVF_ASSERT(dataAccessObject.notNull()); diff --git a/ApplicationCode/ModelVisualization/RivWellHeadPartMgr.cpp b/ApplicationCode/ModelVisualization/RivWellHeadPartMgr.cpp index a78833582f..1d721e24e7 100644 --- a/ApplicationCode/ModelVisualization/RivWellHeadPartMgr.cpp +++ b/ApplicationCode/ModelVisualization/RivWellHeadPartMgr.cpp @@ -72,11 +72,11 @@ void RivWellHeadPartMgr::buildWellHeadParts(size_t frameIndex) if (m_rimReservoirView.isNull()) return; - RigEclipseCase* rigReservoir = m_rimReservoirView->eclipseCase()->reservoirData(); + RigCaseData* rigReservoir = m_rimReservoirView->eclipseCase()->reservoirData(); RimWell* well = m_rimWell; - RigWellResults* wellResults = well->wellResults(); + RigSingleWellResultsData* wellResults = well->wellResults(); if (wellResults->m_staticWellCells.m_wellResultBranches.size() == 0) { diff --git a/ApplicationCode/ModelVisualization/RivWellPipesPartMgr.cpp b/ApplicationCode/ModelVisualization/RivWellPipesPartMgr.cpp index c091f1a4a2..f45e79a32b 100644 --- a/ApplicationCode/ModelVisualization/RivWellPipesPartMgr.cpp +++ b/ApplicationCode/ModelVisualization/RivWellPipesPartMgr.cpp @@ -158,8 +158,8 @@ void RivWellPipesPartMgr::calculateWellPipeCenterline( std::vector< std::vector bool isAutoDetectBranches = m_rimReservoirView->wellCollection()->isAutoDetectingBranches(); - RigEclipseCase* rigReservoir = m_rimReservoirView->eclipseCase()->reservoirData(); - RigWellResults* wellResults = m_rimWell->wellResults(); + RigCaseData* rigReservoir = m_rimReservoirView->eclipseCase()->reservoirData(); + RigSingleWellResultsData* wellResults = m_rimWell->wellResults(); const RigWellResultFrame& staticWellFrame = m_rimWell->wellResults()->m_staticWellCells; @@ -357,7 +357,7 @@ void RivWellPipesPartMgr::updatePipeResultColor(size_t frameIndex) { if (m_rimWell == NULL) return; - RigWellResults* wRes = m_rimWell->wellResults(); + RigSingleWellResultsData* wRes = m_rimWell->wellResults(); if (wRes == NULL) return; if (frameIndex < wRes->firstResultTimeStep()) return; // Or reset colors or something diff --git a/ApplicationCode/ProjectDataModel/RimCaseCollection.h b/ApplicationCode/ProjectDataModel/RimCaseCollection.h index 814987a11f..bd1e1a48b2 100644 --- a/ApplicationCode/ProjectDataModel/RimCaseCollection.h +++ b/ApplicationCode/ProjectDataModel/RimCaseCollection.h @@ -39,7 +39,7 @@ public: RimCaseCollection(); virtual ~RimCaseCollection(); - caf::PdmPointersField reservoirs; + caf::PdmPointersField reservoirs; RimIdenticalGridCaseGroup* parentCaseGroup(); diff --git a/ApplicationCode/ProjectDataModel/RimCellEdgeResultSlot.h b/ApplicationCode/ProjectDataModel/RimCellEdgeResultSlot.h index c37bc7577d..8f4eb1eba9 100644 --- a/ApplicationCode/ProjectDataModel/RimCellEdgeResultSlot.h +++ b/ApplicationCode/ProjectDataModel/RimCellEdgeResultSlot.h @@ -23,7 +23,7 @@ #include "cafAppEnum.h" #include "RimDefines.h" -class RigReservoirCellResults; +class RigCaseCellResultsData; namespace caf { diff --git a/ApplicationCode/ProjectDataModel/RimCellPropertyFilter.h b/ApplicationCode/ProjectDataModel/RimCellPropertyFilter.h index 228826cb6b..344c2c5eb2 100644 --- a/ApplicationCode/ProjectDataModel/RimCellPropertyFilter.h +++ b/ApplicationCode/ProjectDataModel/RimCellPropertyFilter.h @@ -32,7 +32,7 @@ class RimCellPropertyFilterCollection; class RimResultDefinition; class RigGridBase; -class RigReservoirCellResults; +class RigCaseCellResultsData; namespace cvf { diff --git a/ApplicationCode/ProjectDataModel/RimIdenticalGridCaseGroup.cpp b/ApplicationCode/ProjectDataModel/RimIdenticalGridCaseGroup.cpp index 0440dc1bd9..2a52911820 100644 --- a/ApplicationCode/ProjectDataModel/RimIdenticalGridCaseGroup.cpp +++ b/ApplicationCode/ProjectDataModel/RimIdenticalGridCaseGroup.cpp @@ -72,7 +72,7 @@ RimIdenticalGridCaseGroup::~RimIdenticalGridCaseGroup() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimIdenticalGridCaseGroup::addCase(RimReservoir* reservoir) +void RimIdenticalGridCaseGroup::addCase(RimCase* reservoir) { CVF_ASSERT(reservoir); @@ -102,7 +102,7 @@ void RimIdenticalGridCaseGroup::addCase(RimReservoir* reservoir) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimIdenticalGridCaseGroup::removeCase(RimReservoir* reservoir) +void RimIdenticalGridCaseGroup::removeCase(RimCase* reservoir) { caseCollection()->reservoirs().removeChildObject(reservoir); @@ -148,9 +148,9 @@ void RimIdenticalGridCaseGroup::loadMainCaseAndActiveCellInfo() // The mainGrid from the first case is reused directly in for the other cases. // When reading active cell info, only the total cell count is tested for consistency - RimReservoir* mainCase = caseCollection()->reservoirs[0]; + RimCase* mainCase = caseCollection()->reservoirs[0]; mainCase->openEclipseGridFile(); - RigEclipseCase* mainEclipseCase = mainCase->reservoirData(); + RigCaseData* mainEclipseCase = mainCase->reservoirData(); CVF_ASSERT(mainEclipseCase); // Read active cell info from all source cases @@ -158,7 +158,7 @@ void RimIdenticalGridCaseGroup::loadMainCaseAndActiveCellInfo() caf::ProgressInfo info(caseCollection()->reservoirs.size(), "Case group - Reading Active Cell data"); for (size_t i = 1; i < caseCollection()->reservoirs.size(); i++) { - RimResultReservoir* rimReservoir = dynamic_cast(caseCollection()->reservoirs[i]); + RimResultCase* rimReservoir = dynamic_cast(caseCollection()->reservoirs[i]); if(!rimReservoir) continue; // Input reservoir if (!rimReservoir->openAndReadActiveCellData(mainEclipseCase)) @@ -176,7 +176,7 @@ void RimIdenticalGridCaseGroup::loadMainCaseAndActiveCellInfo() bool foundResultsInCache = false; for (size_t i = 0; i < statisticsCaseCollection()->reservoirs.size(); i++) { - RimReservoir* rimReservoir = statisticsCaseCollection()->reservoirs[i]; + RimCase* rimReservoir = statisticsCaseCollection()->reservoirs[i]; // Check if any results are stored in cache if (rimReservoir->results(RifReaderInterface::MATRIX_RESULTS)->storedResultsCount() > 0 || @@ -196,7 +196,7 @@ void RimIdenticalGridCaseGroup::loadMainCaseAndActiveCellInfo() for (size_t i = 0; i < statisticsCaseCollection()->reservoirs.size(); i++) { - RimReservoir* rimReservoir = statisticsCaseCollection()->reservoirs[i]; + RimCase* rimReservoir = statisticsCaseCollection()->reservoirs[i]; rimReservoir->openEclipseGridFile(); @@ -314,7 +314,7 @@ void RimIdenticalGridCaseGroup::updateMainGridAndActiveCellsForStatisticsCases() { for (size_t i = 0; i < statisticsCaseCollection->reservoirs().size(); i++) { - RimReservoir* rimStaticsCase = statisticsCaseCollection->reservoirs[i]; + RimCase* rimStaticsCase = statisticsCaseCollection->reservoirs[i]; rimStaticsCase->reservoirData()->setMainGrid(this->mainGrid()); @@ -332,7 +332,7 @@ void RimIdenticalGridCaseGroup::clearStatisticsResults() { for (size_t i = 0; i < statisticsCaseCollection->reservoirs().size(); i++) { - RimReservoir* rimStaticsCase = statisticsCaseCollection->reservoirs[i]; + RimCase* rimStaticsCase = statisticsCaseCollection->reservoirs[i]; if (!rimStaticsCase) continue; rimStaticsCase->results(RifReaderInterface::MATRIX_RESULTS)->cellResults()->clearAllResults(); @@ -360,13 +360,13 @@ void RimIdenticalGridCaseGroup::clearActiveCellUnions() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RimIdenticalGridCaseGroup::contains(RimReservoir* reservoir) const +bool RimIdenticalGridCaseGroup::contains(RimCase* reservoir) const { CVF_ASSERT(reservoir); for (size_t i = 0; i < caseCollection()->reservoirs().size(); i++) { - RimReservoir* rimReservoir = caseCollection()->reservoirs()[i]; + RimCase* rimReservoir = caseCollection()->reservoirs()[i]; if (reservoir->caseName == reservoir->caseName) { return true; diff --git a/ApplicationCode/ProjectDataModel/RimIdenticalGridCaseGroup.h b/ApplicationCode/ProjectDataModel/RimIdenticalGridCaseGroup.h index 3147f8c6a6..7e379b4a10 100644 --- a/ApplicationCode/ProjectDataModel/RimIdenticalGridCaseGroup.h +++ b/ApplicationCode/ProjectDataModel/RimIdenticalGridCaseGroup.h @@ -26,7 +26,7 @@ #include "RimStatisticsCaseCollection.h" #include "RimCaseCollection.h" -class RimReservoir; +class RimCase; class RigMainGrid; class RigActiveCellInfo; @@ -45,9 +45,9 @@ public: caf::PdmField name; - void addCase(RimReservoir* reservoir); - void removeCase(RimReservoir* reservoir); - bool contains(RimReservoir* reservoir) const; + void addCase(RimCase* reservoir); + void removeCase(RimCase* reservoir); + bool contains(RimCase* reservoir) const; RimStatisticsCase* createAndAppendStatisticsCase(); diff --git a/ApplicationCode/ProjectDataModel/RimInputReservoir.cpp b/ApplicationCode/ProjectDataModel/RimInputReservoir.cpp index d1c55cafb7..4237879b55 100644 --- a/ApplicationCode/ProjectDataModel/RimInputReservoir.cpp +++ b/ApplicationCode/ProjectDataModel/RimInputReservoir.cpp @@ -38,12 +38,12 @@ #include "RIPreferences.h" -CAF_PDM_SOURCE_INIT(RimInputReservoir, "RimInputReservoir"); +CAF_PDM_SOURCE_INIT(RimInputCase, "RimInputReservoir"); //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RimInputReservoir::RimInputReservoir() - : RimReservoir() +RimInputCase::RimInputCase() + : RimCase() { CAF_PDM_InitObject("RimInputReservoir", ":/EclipseInput48x48.png", "", ""); CAF_PDM_InitField(&m_gridFileName, "GridFileName", QString(), "Case grid filename", "", "" ,""); @@ -58,7 +58,7 @@ RimInputReservoir::RimInputReservoir() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RimInputReservoir::~RimInputReservoir() +RimInputCase::~RimInputCase() { delete m_inputPropertyCollection; } @@ -67,7 +67,7 @@ RimInputReservoir::~RimInputReservoir() /// Open the supplied file set. If no grid data has been read, it will first find the possible /// grid data among the files then read all supported properties from the files matching the grid //-------------------------------------------------------------------------------------------------- -void RimInputReservoir::openDataFileSet(const QStringList& filenames) +void RimInputCase::openDataFileSet(const QStringList& filenames) { if (caseName().contains("Input Mock Debug Model")) { @@ -83,7 +83,7 @@ void RimInputReservoir::openDataFileSet(const QStringList& filenames) if (this->reservoirData() == NULL) { - this->setReservoirData(new RigEclipseCase); + this->setReservoirData(new RigCaseData); } // First find and read the grid data @@ -154,7 +154,7 @@ void RimInputReservoir::openDataFileSet(const QStringList& filenames) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RimInputReservoir::openEclipseGridFile() +bool RimInputCase::openEclipseGridFile() { // Early exit if reservoir data is created if (this->reservoirData() == NULL) @@ -167,7 +167,7 @@ bool RimInputReservoir::openEclipseGridFile() } else { - cvf::ref eclipseCase = new RigEclipseCase; + cvf::ref eclipseCase = new RigCaseData; readerInterface = new RifReaderEclipseInput; if (!readerInterface->open(m_gridFileName, eclipseCase.p())) { @@ -206,7 +206,7 @@ bool RimInputReservoir::openEclipseGridFile() /// Loads input property data from the gridFile and additional files /// Creates new InputProperties if necessary, and flags the unused ones as obsolete //-------------------------------------------------------------------------------------------------- -void RimInputReservoir::loadAndSyncronizeInputProperties() +void RimInputCase::loadAndSyncronizeInputProperties() { // Make sure we actually have reservoir data @@ -313,7 +313,7 @@ void RimInputReservoir::loadAndSyncronizeInputProperties() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimInputReservoir::fieldChangedByUi(const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue) +void RimInputCase::fieldChangedByUi(const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue) { } @@ -321,7 +321,7 @@ void RimInputReservoir::fieldChangedByUi(const caf::PdmFieldHandle* changedField //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimInputReservoir::addFiles(const QStringList& newFileNames) +void RimInputCase::addFiles(const QStringList& newFileNames) { } @@ -330,7 +330,7 @@ void RimInputReservoir::addFiles(const QStringList& newFileNames) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimInputReservoir::removeFiles(const QStringList& obsoleteFileNames) +void RimInputCase::removeFiles(const QStringList& obsoleteFileNames) { } @@ -338,7 +338,7 @@ void RimInputReservoir::removeFiles(const QStringList& obsoleteFileNames) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimInputReservoir::removeProperty(RimInputProperty* inputProperty) +void RimInputCase::removeProperty(RimInputProperty* inputProperty) { bool isPropertyFileReferencedByOthers = false; @@ -359,7 +359,7 @@ void RimInputReservoir::removeProperty(RimInputProperty* inputProperty) } // Remove the results pointed to by this input property - RigReservoirCellResults* results = reservoirData()->results(RifReaderInterface::MATRIX_RESULTS); + RigCaseCellResultsData* results = reservoirData()->results(RifReaderInterface::MATRIX_RESULTS); results->removeResult(inputProperty->resultName); this->removeResult(inputProperty->resultName); @@ -368,9 +368,9 @@ void RimInputReservoir::removeProperty(RimInputProperty* inputProperty) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -cvf::ref RimInputReservoir::createMockModel(QString modelName) +cvf::ref RimInputCase::createMockModel(QString modelName) { - cvf::ref reservoir = new RigEclipseCase; + cvf::ref reservoir = new RigCaseData; cvf::ref mockFileInterface = new RifReaderMockModel; if (modelName == "Input Mock Debug Model Simple") @@ -412,7 +412,7 @@ cvf::ref RimInputReservoir::createMockModel(QString modelNam //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -QString RimInputReservoir::locationOnDisc() const +QString RimInputCase::locationOnDisc() const { if (m_gridFileName().isEmpty()) return QString(); diff --git a/ApplicationCode/ProjectDataModel/RimInputReservoir.h b/ApplicationCode/ProjectDataModel/RimInputReservoir.h index 45f06d8c7c..9e0a573b51 100644 --- a/ApplicationCode/ProjectDataModel/RimInputReservoir.h +++ b/ApplicationCode/ProjectDataModel/RimInputReservoir.h @@ -36,13 +36,13 @@ class RifReaderInterface; // // //================================================================================================== -class RimInputReservoir : public RimReservoir +class RimInputCase : public RimCase { CAF_PDM_HEADER_INIT; public: - RimInputReservoir(); - virtual ~RimInputReservoir(); + RimInputCase(); + virtual ~RimInputCase(); // Fields caf::PdmField > m_additionalFileNames; diff --git a/ApplicationCode/ProjectDataModel/RimProject.cpp b/ApplicationCode/ProjectDataModel/RimProject.cpp index 1395ec4e39..212978843f 100644 --- a/ApplicationCode/ProjectDataModel/RimProject.cpp +++ b/ApplicationCode/ProjectDataModel/RimProject.cpp @@ -44,7 +44,7 @@ RimProject::RimProject(void) scriptCollection = new RimScriptCollection(); scriptCollection->directory.setUiHidden(true); - m_gridCollection = new RigGridCollection; + m_gridCollection = new RigGridManager; initAfterRead(); } @@ -130,11 +130,11 @@ QString RimProject::projectFileVersionString() const //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimProject::moveEclipseCaseIntoCaseGroup(RimReservoir* rimReservoir) +void RimProject::moveEclipseCaseIntoCaseGroup(RimCase* rimReservoir) { CVF_ASSERT(rimReservoir); - RigEclipseCase* rigEclipseCase = rimReservoir->reservoirData(); + RigCaseData* rigEclipseCase = rimReservoir->reservoirData(); RigMainGrid* equalGrid = registerCaseInGridCollection(rigEclipseCase); CVF_ASSERT(equalGrid); @@ -167,7 +167,7 @@ void RimProject::moveEclipseCaseIntoCaseGroup(RimReservoir* rimReservoir) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimProject::removeCaseFromAllGroups(RimReservoir* reservoir) +void RimProject::removeCaseFromAllGroups(RimCase* reservoir) { m_gridCollection->removeCase(reservoir->reservoirData()); @@ -185,7 +185,7 @@ void RimProject::removeCaseFromAllGroups(RimReservoir* reservoir) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RigMainGrid* RimProject::registerCaseInGridCollection(RigEclipseCase* rigEclipseCase) +RigMainGrid* RimProject::registerCaseInGridCollection(RigCaseData* rigEclipseCase) { CVF_ASSERT(rigEclipseCase); @@ -221,11 +221,11 @@ RigMainGrid* RimProject::registerCaseInGridCollection(RigEclipseCase* rigEclipse //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimProject::insertCaseInCaseGroup(RimIdenticalGridCaseGroup* caseGroup, RimReservoir* rimReservoir) +void RimProject::insertCaseInCaseGroup(RimIdenticalGridCaseGroup* caseGroup, RimCase* rimReservoir) { CVF_ASSERT(rimReservoir); - RigEclipseCase* rigEclipseCase = rimReservoir->reservoirData(); + RigCaseData* rigEclipseCase = rimReservoir->reservoirData(); registerCaseInGridCollection(rigEclipseCase); caseGroup->addCase(rimReservoir); diff --git a/ApplicationCode/ProjectDataModel/RimProject.h b/ApplicationCode/ProjectDataModel/RimProject.h index 49e4d56ded..084e92dff2 100644 --- a/ApplicationCode/ProjectDataModel/RimProject.h +++ b/ApplicationCode/ProjectDataModel/RimProject.h @@ -22,8 +22,8 @@ #include "RimScriptCollection.h" #include "RimIdenticalGridCaseGroup.h" -class RimReservoir; -class RigGridCollection; +class RimCase; +class RigGridManager; //================================================================================================== /// @@ -34,7 +34,7 @@ class RimProject : public caf::PdmDocument CAF_PDM_HEADER_INIT; public: - caf::PdmPointersField reservoirs; + caf::PdmPointersField reservoirs; caf::PdmPointersField caseGroups; caf::PdmField scriptCollection; @@ -48,13 +48,13 @@ public: void close(); - void insertCaseInCaseGroup(RimIdenticalGridCaseGroup* caseGroup, RimReservoir* rimReservoir); + void insertCaseInCaseGroup(RimIdenticalGridCaseGroup* caseGroup, RimCase* rimReservoir); - void moveEclipseCaseIntoCaseGroup(RimReservoir* rimReservoir); - void removeCaseFromAllGroups(RimReservoir* rimReservoir); + void moveEclipseCaseIntoCaseGroup(RimCase* rimReservoir); + void removeCaseFromAllGroups(RimCase* rimReservoir); private: - RigMainGrid* registerCaseInGridCollection(RigEclipseCase* rigEclipseCase); + RigMainGrid* registerCaseInGridCollection(RigCaseData* rigEclipseCase); protected: // Overridden methods @@ -64,5 +64,5 @@ protected: private: caf::PdmField m_projectFileVersionString; - cvf::ref m_gridCollection; + cvf::ref m_gridCollection; }; diff --git a/ApplicationCode/ProjectDataModel/RimReservoir.cpp b/ApplicationCode/ProjectDataModel/RimReservoir.cpp index abd80217ef..6492c47818 100644 --- a/ApplicationCode/ProjectDataModel/RimReservoir.cpp +++ b/ApplicationCode/ProjectDataModel/RimReservoir.cpp @@ -36,12 +36,12 @@ #include "RimProject.h" #include "RimReservoirCellResultsCacher.h" -CAF_PDM_SOURCE_INIT(RimReservoir, "RimReservoir"); +CAF_PDM_SOURCE_INIT(RimCase, "RimReservoir"); //------------------------------------------------------------------------------------------------ /// //-------------------------------------------------------------------------------------------------- -RimReservoir::RimReservoir() +RimCase::RimCase() { CAF_PDM_InitField(&caseName, "CaseName", QString(), "Case name", "", "" ,""); CAF_PDM_InitFieldNoDefault(&reservoirViews, "ReservoirViews", "", "", "", ""); @@ -60,7 +60,7 @@ RimReservoir::RimReservoir() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RimReservoir::~RimReservoir() +RimCase::~RimCase() { reservoirViews.deleteAllChildObjects(); @@ -77,7 +77,7 @@ RimReservoir::~RimReservoir() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RigEclipseCase* RimReservoir::reservoirData() +RigCaseData* RimCase::reservoirData() { return m_rigEclipseCase.p(); } @@ -85,7 +85,7 @@ RigEclipseCase* RimReservoir::reservoirData() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -const RigEclipseCase* RimReservoir::reservoirData() const +const RigCaseData* RimCase::reservoirData() const { return m_rigEclipseCase.p(); } @@ -93,7 +93,7 @@ const RigEclipseCase* RimReservoir::reservoirData() const //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimReservoir::initAfterRead() +void RimCase::initAfterRead() { size_t j; for (j = 0; j < reservoirViews().size(); j++) @@ -108,7 +108,7 @@ void RimReservoir::initAfterRead() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RimReservoirView* RimReservoir::createAndAddReservoirView() +RimReservoirView* RimCase::createAndAddReservoirView() { // If parent is collection, and number of views is zero, make sure rig is set to NULL to initiate normal case loading if (parentCaseCollection() != NULL && reservoirViews().size() == 0) @@ -135,7 +135,7 @@ RimReservoirView* RimReservoir::createAndAddReservoirView() //-------------------------------------------------------------------------------------------------- /// TODO: Move this functionality to PdmPointersField //-------------------------------------------------------------------------------------------------- -void RimReservoir::removeReservoirView(RimReservoirView* reservoirView) +void RimCase::removeReservoirView(RimReservoirView* reservoirView) { std::vector indices; @@ -159,7 +159,7 @@ void RimReservoir::removeReservoirView(RimReservoirView* reservoirView) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimReservoir::removeResult(const QString& resultName) +void RimCase::removeResult(const QString& resultName) { size_t i; for (i = 0; i < reservoirViews().size(); i++) @@ -210,7 +210,7 @@ void RimReservoir::removeResult(const QString& resultName) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimReservoir::fieldChangedByUi(const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue) +void RimCase::fieldChangedByUi(const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue) { if (changedField == &releaseResultMemory) { @@ -236,13 +236,13 @@ void RimReservoir::fieldChangedByUi(const caf::PdmFieldHandle* changedField, con reservoirView->createDisplayModelAndRedraw(); } - RigReservoirCellResults* matrixModelResults = reservoirData()->results(RifReaderInterface::MATRIX_RESULTS); + RigCaseCellResultsData* matrixModelResults = reservoirData()->results(RifReaderInterface::MATRIX_RESULTS); if (matrixModelResults) { matrixModelResults->clearAllResults(); } - RigReservoirCellResults* fractureModelResults = reservoirData()->results(RifReaderInterface::FRACTURE_RESULTS); + RigCaseCellResultsData* fractureModelResults = reservoirData()->results(RifReaderInterface::FRACTURE_RESULTS); if (fractureModelResults) { fractureModelResults->clearAllResults(); @@ -256,9 +256,9 @@ void RimReservoir::fieldChangedByUi(const caf::PdmFieldHandle* changedField, con //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimReservoir::computeCachedData() +void RimCase::computeCachedData() { - RigEclipseCase* rigEclipseCase = reservoirData(); + RigCaseData* rigEclipseCase = reservoirData(); if (rigEclipseCase) { rigEclipseCase->computeActiveCellBoundingBoxes(); @@ -280,7 +280,7 @@ void RimReservoir::computeCachedData() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RimCaseCollection* RimReservoir::parentCaseCollection() +RimCaseCollection* RimCase::parentCaseCollection() { std::vector parentObjects; this->parentObjectsOfType(parentObjects); @@ -296,7 +296,7 @@ RimCaseCollection* RimReservoir::parentCaseCollection() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimReservoir::setReservoirData(RigEclipseCase* eclipseCase) +void RimCase::setReservoirData(RigCaseData* eclipseCase) { m_rigEclipseCase = eclipseCase; if (this->reservoirData()) @@ -318,7 +318,7 @@ void RimReservoir::setReservoirData(RigEclipseCase* eclipseCase) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RimReservoirCellResultsStorage* RimReservoir::results(RifReaderInterface::PorosityModelResultType porosityModel) +RimReservoirCellResultsStorage* RimCase::results(RifReaderInterface::PorosityModelResultType porosityModel) { if (porosityModel == RifReaderInterface::MATRIX_RESULTS) { diff --git a/ApplicationCode/ProjectDataModel/RimReservoir.h b/ApplicationCode/ProjectDataModel/RimReservoir.h index e9c422a366..12b1b6aaff 100644 --- a/ApplicationCode/ProjectDataModel/RimReservoir.h +++ b/ApplicationCode/ProjectDataModel/RimReservoir.h @@ -27,7 +27,7 @@ class QString; -class RigEclipseCase; +class RigCaseData; class RigGridBase; class RimReservoirView; class RimCaseCollection; @@ -38,12 +38,12 @@ class RimCaseCollection; // Interface for reservoirs. // //================================================================================================== -class RimReservoir : public caf::PdmObject +class RimCase : public caf::PdmObject { CAF_PDM_HEADER_INIT; public: - RimReservoir(); - virtual ~RimReservoir(); + RimCase(); + virtual ~RimCase(); // Fields: caf::PdmField caseName; @@ -52,8 +52,8 @@ public: virtual bool openEclipseGridFile() { return false;}; // Should be pure virtual but PDM does not allow that. - RigEclipseCase* reservoirData(); - const RigEclipseCase* reservoirData() const; + RigCaseData* reservoirData(); + const RigCaseData* reservoirData() const; RimReservoirCellResultsStorage* results(RifReaderInterface::PorosityModelResultType porosityModel); @@ -76,11 +76,11 @@ protected: // Internal methods protected: void computeCachedData(); - void setReservoirData(RigEclipseCase* eclipseCase); + void setReservoirData(RigCaseData* eclipseCase); private: - cvf::ref m_rigEclipseCase; + cvf::ref m_rigEclipseCase; private: caf::PdmField m_matrixModelResults; diff --git a/ApplicationCode/ProjectDataModel/RimReservoirCellResultsCacher.cpp b/ApplicationCode/ProjectDataModel/RimReservoirCellResultsCacher.cpp index 6cf8ec3a05..07e7ea5942 100644 --- a/ApplicationCode/ProjectDataModel/RimReservoirCellResultsCacher.cpp +++ b/ApplicationCode/ProjectDataModel/RimReservoirCellResultsCacher.cpp @@ -73,7 +73,7 @@ void RimReservoirCellResultsStorage::setupBeforeSave() if (!m_cellResults) return; - const std::vector& resInfo = m_cellResults->infoForEachResultIndex(); + const std::vector& resInfo = m_cellResults->infoForEachResultIndex(); bool hasResultsToStore = false; for (size_t rIdx = 0; rIdx < resInfo.size(); ++rIdx) @@ -574,7 +574,7 @@ size_t RimReservoirCellResultsStorage::findOrLoadScalarResult(const QString& res //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimReservoirCellResultsStorage::setCellResults(RigReservoirCellResults* cellResults) +void RimReservoirCellResultsStorage::setCellResults(RigCaseCellResultsData* cellResults) { m_cellResults = cellResults; diff --git a/ApplicationCode/ProjectDataModel/RimReservoirCellResultsCacher.h b/ApplicationCode/ProjectDataModel/RimReservoirCellResultsCacher.h index 2351e6c54d..dd0e154388 100644 --- a/ApplicationCode/ProjectDataModel/RimReservoirCellResultsCacher.h +++ b/ApplicationCode/ProjectDataModel/RimReservoirCellResultsCacher.h @@ -25,7 +25,7 @@ #include "RimDefines.h" class RimReservoirCellResultsStorageEntryInfo; -class RigReservoirCellResults; +class RigCaseCellResultsData; class RifReaderInterface; class RigMainGrid; @@ -36,9 +36,9 @@ public: RimReservoirCellResultsStorage(); virtual ~RimReservoirCellResultsStorage(); - void setCellResults(RigReservoirCellResults* cellResults); - RigReservoirCellResults* cellResults() { return m_cellResults; } - const RigReservoirCellResults* cellResults() const { return m_cellResults; } + void setCellResults(RigCaseCellResultsData* cellResults); + RigCaseCellResultsData* cellResults() { return m_cellResults; } + const RigCaseCellResultsData* cellResults() const { return m_cellResults; } size_t storedResultsCount(); @@ -70,7 +70,7 @@ private: m_resultCacheMetaData; cvf::ref m_readerInterface; - RigReservoirCellResults* m_cellResults; + RigCaseCellResultsData* m_cellResults; RigMainGrid* m_ownerMainGrid; }; diff --git a/ApplicationCode/ProjectDataModel/RimReservoirView.cpp b/ApplicationCode/ProjectDataModel/RimReservoirView.cpp index fedce7dfc8..8cb8eea24a 100644 --- a/ApplicationCode/ProjectDataModel/RimReservoirView.cpp +++ b/ApplicationCode/ProjectDataModel/RimReservoirView.cpp @@ -847,7 +847,7 @@ bool RimReservoirView::pickInfo(size_t gridIndex, size_t cellIndex, const cvf::V if (m_reservoir) { - const RigEclipseCase* eclipseCase = m_reservoir->reservoirData(); + const RigCaseData* eclipseCase = m_reservoir->reservoirData(); if (eclipseCase) { size_t i = 0; @@ -880,12 +880,12 @@ void RimReservoirView::appendCellResultInfo(size_t gridIndex, size_t cellIndex, if (m_reservoir && m_reservoir->reservoirData()) { - RigEclipseCase* eclipseCase = m_reservoir->reservoirData(); + RigCaseData* eclipseCase = m_reservoir->reservoirData(); RigGridBase* grid = eclipseCase->grid(gridIndex); if (this->cellResult()->hasResult()) { - RifReaderInterface::PorosityModelResultType porosityModel = RigReservoirCellResults::convertFromProjectModelPorosityModel(cellResult()->porosityModel()); + RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResult()->porosityModel()); cvf::ref dataAccessObject = eclipseCase->dataAccessObject(grid, porosityModel, m_currentTimeStep, this->cellResult()->gridScalarIndex()); if (dataAccessObject.notNull()) { @@ -906,7 +906,7 @@ void RimReservoirView::appendCellResultInfo(size_t gridIndex, size_t cellIndex, if (resultIndices[idx] == cvf::UNDEFINED_SIZE_T) continue; // Cell edge results are static, results are loaded for first time step only - RifReaderInterface::PorosityModelResultType porosityModel = RigReservoirCellResults::convertFromProjectModelPorosityModel(cellResult()->porosityModel()); + RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResult()->porosityModel()); cvf::ref dataAccessObject = eclipseCase->dataAccessObject(grid, porosityModel, 0, resultIndices[idx]); if (dataAccessObject.notNull()) { @@ -974,7 +974,7 @@ RimReservoirCellResultsStorage* RimReservoirView::currentGridCellResults() { if (m_reservoir) { - RifReaderInterface::PorosityModelResultType porosityModel = RigReservoirCellResults::convertFromProjectModelPorosityModel(cellResult->porosityModel()); + RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResult->porosityModel()); return m_reservoir->results(porosityModel); } @@ -991,7 +991,7 @@ RigActiveCellInfo* RimReservoirView::currentActiveCellInfo() m_reservoir->reservoirData() ) { - RifReaderInterface::PorosityModelResultType porosityModel = RigReservoirCellResults::convertFromProjectModelPorosityModel(cellResult->porosityModel()); + RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResult->porosityModel()); return m_reservoir->reservoirData()->activeCellInfo(porosityModel); } @@ -1059,11 +1059,11 @@ void RimReservoirView::updateLegends() return; } - RigEclipseCase* eclipseCase = m_reservoir->reservoirData(); + RigCaseData* eclipseCase = m_reservoir->reservoirData(); CVF_ASSERT(eclipseCase); - RifReaderInterface::PorosityModelResultType porosityModel = RigReservoirCellResults::convertFromProjectModelPorosityModel(cellResult()->porosityModel()); - RigReservoirCellResults* results = eclipseCase->results(porosityModel); + RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResult()->porosityModel()); + RigCaseCellResultsData* results = eclipseCase->results(porosityModel); CVF_ASSERT(results); if (this->cellResult()->hasResult()) @@ -1112,7 +1112,7 @@ void RimReservoirView::updateLegends() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimReservoirView::setEclipseCase(RimReservoir* reservoir) +void RimReservoirView::setEclipseCase(RimCase* reservoir) { m_reservoir = reservoir; } @@ -1120,7 +1120,7 @@ void RimReservoirView::setEclipseCase(RimReservoir* reservoir) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RimReservoir* RimReservoirView::eclipseCase() +RimCase* RimReservoirView::eclipseCase() { return m_reservoir; } @@ -1142,7 +1142,7 @@ void RimReservoirView::syncronizeWellsWithResults() { if (!(m_reservoir && m_reservoir->reservoirData()) ) return; - cvf::Collection wellResults = m_reservoir->reservoirData()->wellResults(); + cvf::Collection wellResults = m_reservoir->reservoirData()->wellResults(); // Find corresponding well from well result, or create a new size_t wIdx; @@ -1164,7 +1164,7 @@ void RimReservoirView::syncronizeWellsWithResults() for (wIdx = 0; wIdx < this->wellCollection()->wells().size(); ++wIdx) { RimWell* well = this->wellCollection()->wells()[wIdx]; - RigWellResults* wellRes = well->wellResults(); + RigSingleWellResultsData* wellRes = well->wellResults(); if (wellRes == NULL) { delete well; @@ -1208,7 +1208,7 @@ void RimReservoirView::calculateVisibleWellCellsIncFence(cvf::UByteArray* visibl RimWell* well = this->wellCollection()->wells()[wIdx]; if (this->wellCollection()->wellCellVisibility() == RimWellCollection::FORCE_ALL_ON || well->showWellCells()) { - RigWellResults* wres = well->wellResults(); + RigSingleWellResultsData* wres = well->wellResults(); if (!wres) continue; const std::vector< RigWellResultFrame >& wellResFrames = wres->m_wellCellsTimeSteps; diff --git a/ApplicationCode/ProjectDataModel/RimReservoirView.h b/ApplicationCode/ProjectDataModel/RimReservoirView.h index 75cbae54d1..c1125d47cf 100644 --- a/ApplicationCode/ProjectDataModel/RimReservoirView.h +++ b/ApplicationCode/ProjectDataModel/RimReservoirView.h @@ -120,8 +120,8 @@ public: RimReservoirCellResultsStorage* currentGridCellResults(); RigActiveCellInfo* currentActiveCellInfo(); - void setEclipseCase(RimReservoir* reservoir); - RimReservoir* eclipseCase(); + void setEclipseCase(RimCase* reservoir); + RimCase* eclipseCase(); // Animation int currentTimeStep() { return m_currentTimeStep;} @@ -179,7 +179,7 @@ private: private: caf::PdmField m_currentTimeStep; QPointer m_viewer; - caf::PdmPointer m_reservoir; + caf::PdmPointer m_reservoir; }; diff --git a/ApplicationCode/ProjectDataModel/RimResultDefinition.cpp b/ApplicationCode/ProjectDataModel/RimResultDefinition.cpp index 98e081ea12..cf741cd8a1 100644 --- a/ApplicationCode/ProjectDataModel/RimResultDefinition.cpp +++ b/ApplicationCode/ProjectDataModel/RimResultDefinition.cpp @@ -166,7 +166,7 @@ bool RimResultDefinition::hasResult() const { if (m_gridScalarResultIndex != cvf::UNDEFINED_SIZE_T) return true; - const RigReservoirCellResults* gridCellResults = m_reservoirView->currentGridCellResults()->cellResults(); + const RigCaseCellResultsData* gridCellResults = m_reservoirView->currentGridCellResults()->cellResults(); if (gridCellResults) { m_gridScalarResultIndex = gridCellResults->findScalarResultIndex(resultType(), resultVariable()); @@ -182,7 +182,7 @@ bool RimResultDefinition::hasResult() const //-------------------------------------------------------------------------------------------------- bool RimResultDefinition::hasDynamicResult() const { - const RigReservoirCellResults* gridCellResults = m_reservoirView->currentGridCellResults()->cellResults(); + const RigCaseCellResultsData* gridCellResults = m_reservoirView->currentGridCellResults()->cellResults(); if (hasResult() && gridCellResults->timeStepCount(m_gridScalarResultIndex) > 1 ) return true; else diff --git a/ApplicationCode/ProjectDataModel/RimResultDefinition.h b/ApplicationCode/ProjectDataModel/RimResultDefinition.h index a9a159935b..138ce0a5ab 100644 --- a/ApplicationCode/ProjectDataModel/RimResultDefinition.h +++ b/ApplicationCode/ProjectDataModel/RimResultDefinition.h @@ -26,7 +26,7 @@ class RimReservoirView; -class RigReservoirCellResults; +class RigCaseCellResultsData; //================================================================================================== /// diff --git a/ApplicationCode/ProjectDataModel/RimResultReservoir.cpp b/ApplicationCode/ProjectDataModel/RimResultReservoir.cpp index f2e9620587..5cffbd67f6 100644 --- a/ApplicationCode/ProjectDataModel/RimResultReservoir.cpp +++ b/ApplicationCode/ProjectDataModel/RimResultReservoir.cpp @@ -28,12 +28,12 @@ #include "RimProject.h" -CAF_PDM_SOURCE_INIT(RimResultReservoir, "EclipseCase"); +CAF_PDM_SOURCE_INIT(RimResultCase, "EclipseCase"); //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RimResultReservoir::RimResultReservoir() - : RimReservoir() +RimResultCase::RimResultCase() + : RimCase() { CAF_PDM_InitObject("Eclipse Case", ":/AppLogo48x48.png", "", ""); @@ -45,7 +45,7 @@ RimResultReservoir::RimResultReservoir() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RimResultReservoir::openEclipseGridFile() +bool RimResultCase::openEclipseGridFile() { caf::ProgressInfo progInfo(50, "Reading Eclipse Grid File"); @@ -69,7 +69,7 @@ bool RimResultReservoir::openEclipseGridFile() return false; } - cvf::ref eclipseCase = new RigEclipseCase; + cvf::ref eclipseCase = new RigCaseData; readerInterface = new RifReaderEclipseOutput; if (!readerInterface->open(fname, eclipseCase.p())) { @@ -96,7 +96,7 @@ bool RimResultReservoir::openEclipseGridFile() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RimResultReservoir::openAndReadActiveCellData(RigEclipseCase* mainEclipseCase) +bool RimResultCase::openAndReadActiveCellData(RigCaseData* mainEclipseCase) { cvf::ref readerInterface; @@ -112,7 +112,7 @@ bool RimResultReservoir::openAndReadActiveCellData(RigEclipseCase* mainEclipseCa return false; } - cvf::ref eclipseCase = new RigEclipseCase; + cvf::ref eclipseCase = new RigCaseData; CVF_ASSERT(mainEclipseCase && mainEclipseCase->mainGrid()); eclipseCase->setMainGrid(mainEclipseCase->mainGrid()); @@ -155,10 +155,10 @@ bool RimResultReservoir::openAndReadActiveCellData(RigEclipseCase* mainEclipseCa //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -cvf::ref RimResultReservoir::createMockModel(QString modelName) +cvf::ref RimResultCase::createMockModel(QString modelName) { cvf::ref mockFileInterface = new RifReaderMockModel; - cvf::ref reservoir = new RigEclipseCase; + cvf::ref reservoir = new RigCaseData; if (modelName == "Result Mock Debug Model Simple") { @@ -233,7 +233,7 @@ cvf::ref RimResultReservoir::createMockModel(QString modelNa //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RimResultReservoir::~RimResultReservoir() +RimResultCase::~RimResultCase() { reservoirViews.deleteAllChildObjects(); } @@ -241,7 +241,7 @@ RimResultReservoir::~RimResultReservoir() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -QString RimResultReservoir::locationOnDisc() const +QString RimResultCase::locationOnDisc() const { return caseDirectory; } @@ -249,7 +249,7 @@ QString RimResultReservoir::locationOnDisc() const //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -QString RimResultReservoir::createAbsoluteFilenameFromCase(const QString& caseName) +QString RimResultCase::createAbsoluteFilenameFromCase(const QString& caseName) { QString candidate; diff --git a/ApplicationCode/ProjectDataModel/RimResultReservoir.h b/ApplicationCode/ProjectDataModel/RimResultReservoir.h index a97f141e11..7824be7f63 100644 --- a/ApplicationCode/ProjectDataModel/RimResultReservoir.h +++ b/ApplicationCode/ProjectDataModel/RimResultReservoir.h @@ -32,13 +32,13 @@ class RigMainGrid; // // //================================================================================================== -class RimResultReservoir : public RimReservoir +class RimResultCase : public RimCase { CAF_PDM_HEADER_INIT; public: - RimResultReservoir(); - virtual ~RimResultReservoir(); + RimResultCase(); + virtual ~RimResultCase(); // Fields: @@ -46,7 +46,7 @@ public: caf::PdmField caseDirectory; virtual bool openEclipseGridFile(); - bool openAndReadActiveCellData(RigEclipseCase* mainEclipseCase); + bool openAndReadActiveCellData(RigCaseData* mainEclipseCase); //virtual caf::PdmFieldHandle* userDescriptionField() { return &caseName;} diff --git a/ApplicationCode/ProjectDataModel/RimStatisticsCase.cpp b/ApplicationCode/ProjectDataModel/RimStatisticsCase.cpp index 8534a57a22..8ccc043e15 100644 --- a/ApplicationCode/ProjectDataModel/RimStatisticsCase.cpp +++ b/ApplicationCode/ProjectDataModel/RimStatisticsCase.cpp @@ -34,7 +34,7 @@ CAF_PDM_SOURCE_INIT(RimStatisticsCase, "RimStatisticalCalculation"); /// //-------------------------------------------------------------------------------------------------- RimStatisticsCase::RimStatisticsCase() - : RimReservoir() + : RimCase() { CAF_PDM_InitObject("Case Group Statistics", ":/Histogram16x16.png", "", ""); CAF_PDM_InitField(&m_resultName, "ResultName", QString("PRESSURE"), "ResultName", "", "", ""); @@ -68,7 +68,7 @@ bool RimStatisticsCase::openEclipseGridFile() { if (this->reservoirData()) return true; - cvf::ref eclipseCase = new RigEclipseCase; + cvf::ref eclipseCase = new RigCaseData; CVF_ASSERT(parentStatisticsCaseCollection()); @@ -125,7 +125,7 @@ void RimStatisticsCase::computeStatistics() CVF_ASSERT(gridCaseGroup); gridCaseGroup->computeUnionOfActiveCells(); - std::vector sourceCases; + std::vector sourceCases; getSourceCases(sourceCases); @@ -146,7 +146,7 @@ void RimStatisticsCase::computeStatistics() timeStepIndices.push_back(i); } - RigEclipseCase* resultCase = reservoirData(); + RigCaseData* resultCase = reservoirData(); QList > resultSpecification; @@ -187,7 +187,7 @@ void RimStatisticsCase::computeStatistics() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimStatisticsCase::getSourceCases(std::vector& sourceCases) +void RimStatisticsCase::getSourceCases(std::vector& sourceCases) { RimIdenticalGridCaseGroup* gridCaseGroup = caseGroup(); if (gridCaseGroup) @@ -199,7 +199,7 @@ void RimStatisticsCase::getSourceCases(std::vector& sourceCases) CVF_ASSERT(gridCaseGroup->caseCollection->reservoirs[i]); CVF_ASSERT(gridCaseGroup->caseCollection->reservoirs[i]->reservoirData()); - RimReservoir* sourceCase = gridCaseGroup->caseCollection->reservoirs[i]; + RimCase* sourceCase = gridCaseGroup->caseCollection->reservoirs[i]; sourceCases.push_back(sourceCase); } } diff --git a/ApplicationCode/ProjectDataModel/RimStatisticsCase.h b/ApplicationCode/ProjectDataModel/RimStatisticsCase.h index df9dd0f022..86d424b02d 100644 --- a/ApplicationCode/ProjectDataModel/RimStatisticsCase.h +++ b/ApplicationCode/ProjectDataModel/RimStatisticsCase.h @@ -36,7 +36,7 @@ class RigMainGrid; // // //================================================================================================== -class RimStatisticsCase : public RimReservoir +class RimStatisticsCase : public RimCase { CAF_PDM_HEADER_INIT; @@ -58,6 +58,6 @@ public: private: RimIdenticalGridCaseGroup* caseGroup(); - void getSourceCases(std::vector& sourceCases); + void getSourceCases(std::vector& sourceCases); }; diff --git a/ApplicationCode/ProjectDataModel/RimStatisticsCaseEvaluator.cpp b/ApplicationCode/ProjectDataModel/RimStatisticsCaseEvaluator.cpp index f170e30e4e..b42379e4b4 100644 --- a/ApplicationCode/ProjectDataModel/RimStatisticsCaseEvaluator.cpp +++ b/ApplicationCode/ProjectDataModel/RimStatisticsCaseEvaluator.cpp @@ -107,7 +107,7 @@ private: //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimStatisticsCaseEvaluator::addNamedResult(RigReservoirCellResults* destinationCellResults, RimDefines::ResultCatType resultType, const QString& resultName, size_t activeUnionCellCount) +void RimStatisticsCaseEvaluator::addNamedResult(RigCaseCellResultsData* destinationCellResults, RimDefines::ResultCatType resultType, const QString& resultName, size_t activeUnionCellCount) { // Use time step dates from first result in first source case CVF_ASSERT(m_sourceCases.size() > 0); @@ -148,7 +148,7 @@ void RimStatisticsCaseEvaluator::buildSourceMetaData(RimDefines::ResultCatType r for (size_t caseIdx = 1; caseIdx < m_sourceCases.size(); caseIdx++) { - RigEclipseCase* eclipseCase = m_sourceCases.at(caseIdx)->reservoirData(); + RigCaseData* eclipseCase = m_sourceCases.at(caseIdx)->reservoirData(); RimReservoirCellResultsStorage* matrixResults = m_sourceCases[caseIdx]->results(RifReaderInterface::MATRIX_RESULTS); size_t scalarResultIndex = matrixResults->findOrLoadScalarResult(resultType, resultName); @@ -171,7 +171,7 @@ void RimStatisticsCaseEvaluator::evaluateForResults(const QListactiveCellInfo(RifReaderInterface::MATRIX_RESULTS)->globalActiveCellCount(); - RigReservoirCellResults* matrixResults = m_destinationCase->results(RifReaderInterface::MATRIX_RESULTS); + RigCaseCellResultsData* matrixResults = m_destinationCase->results(RifReaderInterface::MATRIX_RESULTS); for (int i = 0; i < resultSpecification.size(); i++) { @@ -249,7 +249,7 @@ void RimStatisticsCaseEvaluator::evaluateForResults(const QList dataAccesObjectList; for (size_t caseIdx = 0; caseIdx < m_sourceCases.size(); caseIdx++) { - RimReservoir* eclipseCase = m_sourceCases.at(caseIdx); + RimCase* eclipseCase = m_sourceCases.at(caseIdx); size_t scalarResultIndex = eclipseCase->results(RifReaderInterface::MATRIX_RESULTS)->findOrLoadScalarResultForTimeStep(resultType, resultName, dataAccessTimeStepIndex); @@ -371,7 +371,7 @@ void RimStatisticsCaseEvaluator::evaluateForResults(const QList& sourceCases, const std::vector& timeStepIndices, const RimStatisticsConfig& statisticsConfig, RigEclipseCase* destinationCase) +RimStatisticsCaseEvaluator::RimStatisticsCaseEvaluator(const std::vector& sourceCases, const std::vector& timeStepIndices, const RimStatisticsConfig& statisticsConfig, RigCaseData* destinationCase) : m_sourceCases(sourceCases), m_statisticsConfig(statisticsConfig), m_destinationCase(destinationCase), diff --git a/ApplicationCode/ProjectDataModel/RimStatisticsCaseEvaluator.h b/ApplicationCode/ProjectDataModel/RimStatisticsCaseEvaluator.h index f34fd76bd8..14a80a6b0d 100644 --- a/ApplicationCode/ProjectDataModel/RimStatisticsCaseEvaluator.h +++ b/ApplicationCode/ProjectDataModel/RimStatisticsCaseEvaluator.h @@ -27,9 +27,9 @@ #include #include "RimDefines.h" -class RimReservoir; -class RigEclipseCase; -class RigReservoirCellResults; +class RimCase; +class RigCaseData; +class RigCaseCellResultsData; class RimStatisticsConfig @@ -54,10 +54,10 @@ public: class RimStatisticsCaseEvaluator { public: - RimStatisticsCaseEvaluator(const std::vector& sourceCases, + RimStatisticsCaseEvaluator(const std::vector& sourceCases, const std::vector& timeStepIndices, const RimStatisticsConfig& statisticsConfig, - RigEclipseCase* destinationCase); + RigCaseData* destinationCase); void evaluateForResults(const QList >& resultSpecification); @@ -65,15 +65,15 @@ public: void debugOutput(RimDefines::ResultCatType resultType, const QString& resultName, size_t timeStepIdx); private: - void addNamedResult(RigReservoirCellResults* cellResults, RimDefines::ResultCatType resultType, const QString& resultName, size_t activeCellCount); + void addNamedResult(RigCaseCellResultsData* cellResults, RimDefines::ResultCatType resultType, const QString& resultName, size_t activeCellCount); void buildSourceMetaData(RimDefines::ResultCatType resultType, const QString& resultName); private: - std::vector m_sourceCases; + std::vector m_sourceCases; std::vector m_timeStepIndices; size_t m_globalCellCount; RimStatisticsConfig m_statisticsConfig; - RigEclipseCase* m_destinationCase; + RigCaseData* m_destinationCase; }; diff --git a/ApplicationCode/ProjectDataModel/RimUiTreeModelPdm.cpp b/ApplicationCode/ProjectDataModel/RimUiTreeModelPdm.cpp index 6debf187d7..a1395c0234 100644 --- a/ApplicationCode/ProjectDataModel/RimUiTreeModelPdm.cpp +++ b/ApplicationCode/ProjectDataModel/RimUiTreeModelPdm.cpp @@ -213,7 +213,7 @@ bool RimUiTreeModelPdm::deleteReservoirView(const QModelIndex& itemIndex) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimUiTreeModelPdm::deleteReservoir(RimReservoir* reservoir) +void RimUiTreeModelPdm::deleteReservoir(RimCase* reservoir) { RimCaseCollection* caseCollection = reservoir->parentCaseCollection(); QModelIndex caseCollectionModelIndex = getModelIndexFromPdmObject(caseCollection); @@ -355,7 +355,7 @@ RimReservoirView* RimUiTreeModelPdm::addReservoirView(const QModelIndex& itemInd collectionItem = currentItem->parent(); collectionIndex = itemIndex.parent(); } - else if (dynamic_cast(currentItem->dataObject().p())) + else if (dynamic_cast(currentItem->dataObject().p())) { collectionItem = currentItem; collectionIndex = itemIndex; @@ -363,7 +363,7 @@ RimReservoirView* RimUiTreeModelPdm::addReservoirView(const QModelIndex& itemInd if (collectionItem) { - RimReservoir* rimReservoir = dynamic_cast(collectionItem->dataObject().p()); + RimCase* rimReservoir = dynamic_cast(collectionItem->dataObject().p()); RimReservoirView* insertedView = rimReservoir->createAndAddReservoirView(); int viewCount = rowCount(collectionIndex); @@ -430,11 +430,11 @@ void RimUiTreeModelPdm::addInputProperty(const QModelIndex& itemIndex, const QSt RimInputPropertyCollection* inputPropertyCollection = dynamic_cast(currentItem->dataObject().p()); CVF_ASSERT(inputPropertyCollection); - std::vector parentObjects; + std::vector parentObjects; inputPropertyCollection->parentObjectsOfType(parentObjects); CVF_ASSERT(parentObjects.size() == 1); - RimInputReservoir* inputReservoir = parentObjects[0]; + RimInputCase* inputReservoir = parentObjects[0]; CVF_ASSERT(inputReservoir); if (inputReservoir) { @@ -468,11 +468,11 @@ void RimUiTreeModelPdm::deleteInputProperty(const QModelIndex& itemIndex) RimInputPropertyCollection* inputPropertyCollection = parentObjects[0]; if (!inputPropertyCollection) return; - std::vector parentObjects2; + std::vector parentObjects2; inputPropertyCollection->parentObjectsOfType(parentObjects2); CVF_ASSERT(parentObjects2.size() == 1); - RimInputReservoir* inputReservoir = parentObjects2[0]; + RimInputCase* inputReservoir = parentObjects2[0]; if (!inputReservoir) return; inputReservoir->removeProperty(inputProperty); @@ -541,7 +541,7 @@ RimIdenticalGridCaseGroup* RimUiTreeModelPdm::addCaseGroup(const QModelIndex& it caf::PdmUiTreeItem* currentItem = getTreeItemFromIndex(itemIndex); if (dynamic_cast(currentItem->dataObject().p()) || - dynamic_cast(currentItem->dataObject().p())) + dynamic_cast(currentItem->dataObject().p())) { QModelIndex rootIndex = itemIndex.parent(); caf::PdmUiTreeItem* rootTreeItem = currentItem->parent(); @@ -590,9 +590,9 @@ void RimUiTreeModelPdm::addObjects(const QModelIndex& itemIndex, caf::PdmObjectG gridCaseGroup = caseCollection->parentCaseGroup(); } - else if (dynamic_cast(currentItem->dataObject().p())) + else if (dynamic_cast(currentItem->dataObject().p())) { - RimReservoir* rimReservoir = dynamic_cast(currentItem->dataObject().p()); + RimCase* rimReservoir = dynamic_cast(currentItem->dataObject().p()); CVF_ASSERT(rimReservoir); caseCollection = rimReservoir->parentCaseCollection(); @@ -608,19 +608,19 @@ void RimUiTreeModelPdm::addObjects(const QModelIndex& itemIndex, caf::PdmObjectG if (gridCaseGroup) { - std::vector > typedObjects; + std::vector > typedObjects; pdmObjects.createCopyByType(&typedObjects); - RigEclipseCase* mainEclipseCase = NULL; + RigCaseData* mainEclipseCase = NULL; if (gridCaseGroup->caseCollection()->reservoirs().size() > 0) { - RimReservoir* mainReservoir = gridCaseGroup->caseCollection()->reservoirs()[0];; + RimCase* mainReservoir = gridCaseGroup->caseCollection()->reservoirs()[0];; mainEclipseCase = mainReservoir->reservoirData(); } for (size_t i = 0; i < typedObjects.size(); i++) { - RimResultReservoir* rimResultReservoir = typedObjects[i]; + RimResultCase* rimResultReservoir = typedObjects[i]; if (gridCaseGroup->contains(rimResultReservoir)) { @@ -748,7 +748,7 @@ Qt::ItemFlags RimUiTreeModelPdm::flags(const QModelIndex &index) const { return Qt::ItemIsDropEnabled | defaultFlags; } - else if (dynamic_cast(currentItem->dataObject().p())) + else if (dynamic_cast(currentItem->dataObject().p())) { // TODO: Remember to handle reservoir holding the main grid return Qt::ItemIsDragEnabled | defaultFlags; @@ -781,12 +781,12 @@ bool RimUiTreeModelPdm::dropMimeData(const QMimeData *data, Qt::DropAction actio if (action == Qt::MoveAction) { - std::vector > typedObjects; + std::vector > typedObjects; pog.objectsByType(&typedObjects); for (size_t i = 0; i < typedObjects.size(); i++) { - RimReservoir* rimReservoir = typedObjects[i]; + RimCase* rimReservoir = typedObjects[i]; deleteReservoir(rimReservoir); } } diff --git a/ApplicationCode/ProjectDataModel/RimUiTreeModelPdm.h b/ApplicationCode/ProjectDataModel/RimUiTreeModelPdm.h index 2201c7e090..af0372e21f 100644 --- a/ApplicationCode/ProjectDataModel/RimUiTreeModelPdm.h +++ b/ApplicationCode/ProjectDataModel/RimUiTreeModelPdm.h @@ -29,7 +29,7 @@ class QFileSystemWatcher; class RimCellPropertyFilter; class RimCellRangeFilter; -class RimReservoir; +class RimCase; class RimReservoirView; class RimInputProperty; class RimStatisticsCase; @@ -105,7 +105,7 @@ public: bool deletePropertyFilter(const QModelIndex& itemIndex); bool deleteReservoirView(const QModelIndex& itemIndex); void deleteInputProperty(const QModelIndex& itemIndex); - void deleteReservoir(RimReservoir* reservoir); + void deleteReservoir(RimCase* reservoir); RimCellPropertyFilter* addPropertyFilter(const QModelIndex& itemIndex, QModelIndex& insertedModelIndex); RimCellRangeFilter* addRangeFilter(const QModelIndex& itemIndex, QModelIndex& insertedModelIndex); diff --git a/ApplicationCode/ProjectDataModel/RimUiTreeView.cpp b/ApplicationCode/ProjectDataModel/RimUiTreeView.cpp index 65ae72d80a..db0db569b6 100644 --- a/ApplicationCode/ProjectDataModel/RimUiTreeView.cpp +++ b/ApplicationCode/ProjectDataModel/RimUiTreeView.cpp @@ -174,7 +174,7 @@ void RimUiTreeView::contextMenuEvent(QContextMenuEvent* event) menu.addAction(QString("Close"), this, SLOT(slotCloseCase())); menu.exec(event->globalPos()); } - else if (dynamic_cast(uiItem->dataObject().p())) + else if (dynamic_cast(uiItem->dataObject().p())) { QMenu menu; menu.addAction(QString("Copy"), this, SLOT(slotCopyPdmObjectToClipboard())); @@ -686,7 +686,7 @@ void RimUiTreeView::slotWriteInputProperty() exportSettings.eclipseKeyword = inputProperty->eclipseKeyword; // Find input reservoir for this property - RimInputReservoir* inputReservoir = NULL; + RimInputCase* inputReservoir = NULL; { std::vector parentObjects; inputProperty->parentObjectsOfType(parentObjects); @@ -695,7 +695,7 @@ void RimUiTreeView::slotWriteInputProperty() RimInputPropertyCollection* inputPropertyCollection = parentObjects[0]; if (!inputPropertyCollection) return; - std::vector parentObjects2; + std::vector parentObjects2; inputPropertyCollection->parentObjectsOfType(parentObjects2); CVF_ASSERT(parentObjects2.size() == 1); @@ -781,7 +781,7 @@ void RimUiTreeView::slotWriteBinaryResultAsInputProperty() if (preferencesDialog.exec() == QDialog::Accepted) { size_t timeStep = resultSlot->reservoirView()->currentTimeStep(); - RifReaderInterface::PorosityModelResultType porosityModel = RigReservoirCellResults::convertFromProjectModelPorosityModel(resultSlot->porosityModel()); + RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(resultSlot->porosityModel()); bool isOk = RifEclipseInputFileTools::writeBinaryResultToTextFile(exportSettings.fileName, resultSlot->reservoirView()->eclipseCase()->reservoirData(), porosityModel, timeStep, resultSlot->resultVariable, exportSettings.eclipseKeyword, exportSettings.undefinedValue); if (!isOk) @@ -811,12 +811,12 @@ void RimUiTreeView::slotCloseCase() group.addObject(uiItem->dataObject().p()); } - std::vector > typedObjects; + std::vector > typedObjects; group.objectsByType(&typedObjects); for (size_t i = 0; i < typedObjects.size(); i++) { - RimReservoir* rimReservoir = typedObjects[i]; + RimCase* rimReservoir = typedObjects[i]; myModel->deleteReservoir(rimReservoir); } } @@ -955,7 +955,7 @@ void RimUiTreeView::keyPressEvent(QKeyEvent* keyEvent) RimUiTreeModelPdm* myModel = dynamic_cast(model()); caf::PdmUiTreeItem* uiItem = myModel->getTreeItemFromIndex(currentIndex()); - if (dynamic_cast(uiItem->dataObject().p())) + if (dynamic_cast(uiItem->dataObject().p())) { if (keyEvent->matches(QKeySequence::Copy)) { @@ -968,7 +968,7 @@ void RimUiTreeView::keyPressEvent(QKeyEvent* keyEvent) if (dynamic_cast(uiItem->dataObject().p()) || dynamic_cast(uiItem->dataObject().p()) - || dynamic_cast(uiItem->dataObject().p())) + || dynamic_cast(uiItem->dataObject().p())) { if (keyEvent->matches(QKeySequence::Paste)) { diff --git a/ApplicationCode/ProjectDataModel/RimWell.h b/ApplicationCode/ProjectDataModel/RimWell.h index 56e405fe77..d2b136cff4 100644 --- a/ApplicationCode/ProjectDataModel/RimWell.h +++ b/ApplicationCode/ProjectDataModel/RimWell.h @@ -41,8 +41,8 @@ public: void setReservoirView(RimReservoirView* ownerReservoirView); - void setWellResults(RigWellResults* wellResults) { m_wellResults = wellResults;} - RigWellResults* wellResults() { return m_wellResults.p();} + void setWellResults(RigSingleWellResultsData* wellResults) { m_wellResults = wellResults;} + RigSingleWellResultsData* wellResults() { return m_wellResults.p();} virtual caf::PdmFieldHandle* userDescriptionField(); @@ -61,7 +61,7 @@ public: caf::PdmField pipeRadiusScaleFactor; private: - cvf::ref m_wellResults; + cvf::ref m_wellResults; RimReservoirView* m_reservoirView; }; diff --git a/ApplicationCode/ReservoirDataModel/ReservoirDataModel_UnitTests/RigReservoir-Test.cpp b/ApplicationCode/ReservoirDataModel/ReservoirDataModel_UnitTests/RigReservoir-Test.cpp index 80689eb35f..b6abc6c47e 100644 --- a/ApplicationCode/ReservoirDataModel/ReservoirDataModel_UnitTests/RigReservoir-Test.cpp +++ b/ApplicationCode/ReservoirDataModel/ReservoirDataModel_UnitTests/RigReservoir-Test.cpp @@ -28,17 +28,17 @@ //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -TEST(RigGridCollection, BasicTest) +TEST(RigGridManager, BasicTest) { cvf::ref mainGridA = new RigMainGrid; - cvf::ref eclipseCase = new RigEclipseCase; + cvf::ref eclipseCase = new RigCaseData; eclipseCase->setMainGrid(mainGridA.p()); int count = mainGridA->refCount(); EXPECT_EQ(mainGridA->refCount(), 2); - RigGridCollection gridCollection; + RigGridManager gridCollection; gridCollection.addCase(eclipseCase.p()); EXPECT_EQ(mainGridA->refCount(), 2); @@ -52,18 +52,18 @@ TEST(RigGridCollection, BasicTest) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -TEST(RigGridCollection, EqualTests) +TEST(RigGridManager, EqualTests) { cvf::ref mainGridA = new RigMainGrid; mainGridA->nodes().push_back(cvf::Vec3d(0, 0, 0)); mainGridA->nodes().push_back(cvf::Vec3d(0, 0, 1)); mainGridA->nodes().push_back(cvf::Vec3d(0, 0, 2)); - cvf::ref eclipseCase = new RigEclipseCase; + cvf::ref eclipseCase = new RigCaseData; eclipseCase->setMainGrid(mainGridA.p()); - RigGridCollection gridCollection; + RigGridManager gridCollection; gridCollection.addCase(eclipseCase.p()); diff --git a/ApplicationCode/ReservoirDataModel/RigEclipseCase.cpp b/ApplicationCode/ReservoirDataModel/RigEclipseCase.cpp index 292d26fd9c..76b3617dd0 100644 --- a/ApplicationCode/ReservoirDataModel/RigEclipseCase.cpp +++ b/ApplicationCode/ReservoirDataModel/RigEclipseCase.cpp @@ -24,12 +24,12 @@ //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RigEclipseCase::RigEclipseCase() +RigCaseData::RigCaseData() { m_mainGrid = new RigMainGrid(); - m_matrixModelResults = new RigReservoirCellResults(m_mainGrid.p()); - m_fractureModelResults = new RigReservoirCellResults(m_mainGrid.p()); + m_matrixModelResults = new RigCaseCellResultsData(m_mainGrid.p()); + m_fractureModelResults = new RigCaseCellResultsData(m_mainGrid.p()); m_activeCellInfo = new RigActiveCellInfo; m_fractureActiveCellInfo = new RigActiveCellInfo; @@ -38,7 +38,7 @@ RigEclipseCase::RigEclipseCase() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RigEclipseCase::~RigEclipseCase() +RigCaseData::~RigCaseData() { } @@ -46,7 +46,7 @@ RigEclipseCase::~RigEclipseCase() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigEclipseCase::setMainGrid(RigMainGrid* mainGrid) +void RigCaseData::setMainGrid(RigMainGrid* mainGrid) { m_mainGrid = mainGrid; @@ -57,7 +57,7 @@ void RigEclipseCase::setMainGrid(RigMainGrid* mainGrid) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigEclipseCase::allGrids(std::vector* grids) +void RigCaseData::allGrids(std::vector* grids) { CVF_ASSERT(grids); @@ -76,7 +76,7 @@ void RigEclipseCase::allGrids(std::vector* grids) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigEclipseCase::allGrids(std::vector* grids) const +void RigCaseData::allGrids(std::vector* grids) const { CVF_ASSERT(grids); @@ -95,7 +95,7 @@ void RigEclipseCase::allGrids(std::vector* grids) const //-------------------------------------------------------------------------------------------------- /// Get grid by index. The main grid has index 0, so the first lgr has index 1 //-------------------------------------------------------------------------------------------------- -const RigGridBase* RigEclipseCase::grid(size_t index) const +const RigGridBase* RigCaseData::grid(size_t index) const { CVF_ASSERT(m_mainGrid.notNull()); return m_mainGrid->gridByIndex(index); @@ -105,7 +105,7 @@ const RigGridBase* RigEclipseCase::grid(size_t index) const //-------------------------------------------------------------------------------------------------- /// Get grid by index. The main grid has index 0, so the first lgr has index 1 //-------------------------------------------------------------------------------------------------- -RigGridBase* RigEclipseCase::grid(size_t index) +RigGridBase* RigCaseData::grid(size_t index) { CVF_ASSERT(m_mainGrid.notNull()); return m_mainGrid->gridByIndex(index); @@ -114,7 +114,7 @@ RigGridBase* RigEclipseCase::grid(size_t index) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -size_t RigEclipseCase::gridCount() const +size_t RigCaseData::gridCount() const { CVF_ASSERT(m_mainGrid.notNull()); return m_mainGrid->gridCount(); @@ -124,7 +124,7 @@ size_t RigEclipseCase::gridCount() const //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigEclipseCase::computeWellCellsPrGrid() +void RigCaseData::computeWellCellsPrGrid() { // If we have computed this already, return if (m_wellCellsInGrid.size()) return; @@ -185,7 +185,7 @@ void RigEclipseCase::computeWellCellsPrGrid() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigEclipseCase::setWellResults(const cvf::Collection& data) +void RigCaseData::setWellResults(const cvf::Collection& data) { m_wellResults = data; m_wellCellsInGrid.clear(); @@ -195,7 +195,7 @@ void RigEclipseCase::setWellResults(const cvf::Collection& data) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -cvf::UByteArray* RigEclipseCase::wellCellsInGrid(size_t gridIndex) +cvf::UByteArray* RigCaseData::wellCellsInGrid(size_t gridIndex) { computeWellCellsPrGrid(); CVF_ASSERT(gridIndex < m_wellCellsInGrid.size()); @@ -206,7 +206,7 @@ cvf::UByteArray* RigEclipseCase::wellCellsInGrid(size_t gridIndex) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RigCell& RigEclipseCase::cellFromWellResultCell(const RigWellResultCell& wellResultCell) +RigCell& RigCaseData::cellFromWellResultCell(const RigWellResultCell& wellResultCell) { size_t gridIndex = wellResultCell.m_gridIndex; size_t gridCellIndex = wellResultCell.m_gridCellIndex; @@ -220,7 +220,7 @@ RigCell& RigEclipseCase::cellFromWellResultCell(const RigWellResultCell& wellRes //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RigEclipseCase::findSharedSourceFace(cvf::StructGridInterface::FaceType& sharedSourceFace,const RigWellResultCell& sourceWellCellResult, const RigWellResultCell& otherWellCellResult) const +bool RigCaseData::findSharedSourceFace(cvf::StructGridInterface::FaceType& sharedSourceFace,const RigWellResultCell& sourceWellCellResult, const RigWellResultCell& otherWellCellResult) const { size_t gridIndex = sourceWellCellResult.m_gridIndex; size_t gridCellIndex = sourceWellCellResult.m_gridCellIndex; @@ -291,7 +291,7 @@ public: //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigEclipseCase::computeActiveCellIJKBBox() +void RigCaseData::computeActiveCellIJKBBox() { if (m_mainGrid.notNull() && m_activeCellInfo.notNull() && m_fractureActiveCellInfo.notNull()) { @@ -322,7 +322,7 @@ void RigEclipseCase::computeActiveCellIJKBBox() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigEclipseCase::computeActiveCellBoundingBoxes() +void RigCaseData::computeActiveCellBoundingBoxes() { computeActiveCellIJKBBox(); computeActiveCellsGeometryBoundingBox(); @@ -331,7 +331,7 @@ void RigEclipseCase::computeActiveCellBoundingBoxes() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RigActiveCellInfo* RigEclipseCase::activeCellInfo(RifReaderInterface::PorosityModelResultType porosityModel) +RigActiveCellInfo* RigCaseData::activeCellInfo(RifReaderInterface::PorosityModelResultType porosityModel) { if (porosityModel == RifReaderInterface::MATRIX_RESULTS) { @@ -344,7 +344,7 @@ RigActiveCellInfo* RigEclipseCase::activeCellInfo(RifReaderInterface::PorosityMo //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -const RigActiveCellInfo* RigEclipseCase::activeCellInfo(RifReaderInterface::PorosityModelResultType porosityModel) const +const RigActiveCellInfo* RigCaseData::activeCellInfo(RifReaderInterface::PorosityModelResultType porosityModel) const { if (porosityModel == RifReaderInterface::MATRIX_RESULTS) { @@ -357,7 +357,7 @@ const RigActiveCellInfo* RigEclipseCase::activeCellInfo(RifReaderInterface::Poro //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigEclipseCase::setActiveCellInfo(RifReaderInterface::PorosityModelResultType porosityModel, RigActiveCellInfo* activeCellInfo) +void RigCaseData::setActiveCellInfo(RifReaderInterface::PorosityModelResultType porosityModel, RigActiveCellInfo* activeCellInfo) { if (porosityModel == RifReaderInterface::MATRIX_RESULTS) { @@ -373,7 +373,7 @@ void RigEclipseCase::setActiveCellInfo(RifReaderInterface::PorosityModelResultTy //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigEclipseCase::computeActiveCellsGeometryBoundingBox() +void RigCaseData::computeActiveCellsGeometryBoundingBox() { if (m_activeCellInfo.notNull() || m_fractureActiveCellInfo.notNull()) { @@ -427,7 +427,7 @@ void RigEclipseCase::computeActiveCellsGeometryBoundingBox() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RigReservoirCellResults* RigEclipseCase::results(RifReaderInterface::PorosityModelResultType porosityModel) +RigCaseCellResultsData* RigCaseData::results(RifReaderInterface::PorosityModelResultType porosityModel) { if (porosityModel == RifReaderInterface::MATRIX_RESULTS) { @@ -440,7 +440,7 @@ RigReservoirCellResults* RigEclipseCase::results(RifReaderInterface::PorosityMod //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -const RigReservoirCellResults* RigEclipseCase::results(RifReaderInterface::PorosityModelResultType porosityModel) const +const RigCaseCellResultsData* RigCaseData::results(RifReaderInterface::PorosityModelResultType porosityModel) const { if (porosityModel == RifReaderInterface::MATRIX_RESULTS) { @@ -453,7 +453,7 @@ const RigReservoirCellResults* RigEclipseCase::results(RifReaderInterface::Poros //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -cvf::ref RigEclipseCase::dataAccessObject(const RigGridBase* grid, +cvf::ref RigCaseData::dataAccessObject(const RigGridBase* grid, RifReaderInterface::PorosityModelResultType porosityModel, size_t timeStepIndex, size_t scalarSetIndex) diff --git a/ApplicationCode/ReservoirDataModel/RigEclipseCase.h b/ApplicationCode/ReservoirDataModel/RigEclipseCase.h index 5063111cb4..04900460a8 100644 --- a/ApplicationCode/ReservoirDataModel/RigEclipseCase.h +++ b/ApplicationCode/ReservoirDataModel/RigEclipseCase.h @@ -27,14 +27,14 @@ #include "RigWellResults.h" #include "RigActiveCellInfo.h" -class RigReservoirCellResults; +class RigCaseCellResultsData; -class RigEclipseCase: public cvf::Object +class RigCaseData: public cvf::Object { public: - RigEclipseCase(); - ~RigEclipseCase(); + RigCaseData(); + ~RigCaseData(); RigMainGrid* mainGrid() { return m_mainGrid.p(); } const RigMainGrid* mainGrid() const { return m_mainGrid.p(); } @@ -46,8 +46,8 @@ public: RigGridBase* grid(size_t index); size_t gridCount() const; - RigReservoirCellResults* results(RifReaderInterface::PorosityModelResultType porosityModel); - const RigReservoirCellResults* results(RifReaderInterface::PorosityModelResultType porosityModel) const; + RigCaseCellResultsData* results(RifReaderInterface::PorosityModelResultType porosityModel); + const RigCaseCellResultsData* results(RifReaderInterface::PorosityModelResultType porosityModel) const; RigActiveCellInfo* activeCellInfo(RifReaderInterface::PorosityModelResultType porosityModel); const RigActiveCellInfo* activeCellInfo(RifReaderInterface::PorosityModelResultType porosityModel) const; @@ -59,8 +59,8 @@ public: size_t timeStepIndex, size_t scalarSetIndex); - void setWellResults(const cvf::Collection& data); - const cvf::Collection& wellResults() { return m_wellResults; } + void setWellResults(const cvf::Collection& data); + const cvf::Collection& wellResults() { return m_wellResults; } cvf::UByteArray* wellCellsInGrid(size_t gridIndex); @@ -80,9 +80,9 @@ private: cvf::ref m_activeCellInfo; cvf::ref m_fractureActiveCellInfo; - cvf::ref m_matrixModelResults; - cvf::ref m_fractureModelResults; + cvf::ref m_matrixModelResults; + cvf::ref m_fractureModelResults; - cvf::Collection m_wellResults; //< A WellResults object for each well in the reservoir + cvf::Collection m_wellResults; //< A WellResults object for each well in the reservoir cvf::Collection m_wellCellsInGrid; //< A bool array pr grid with one bool pr cell telling wether the cell is a well cell or not }; diff --git a/ApplicationCode/ReservoirDataModel/RigGridCollection.cpp b/ApplicationCode/ReservoirDataModel/RigGridCollection.cpp index 0bd0a98a6b..61812211a6 100644 --- a/ApplicationCode/ReservoirDataModel/RigGridCollection.cpp +++ b/ApplicationCode/ReservoirDataModel/RigGridCollection.cpp @@ -24,7 +24,7 @@ //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigGridCollection::addCase(RigEclipseCase* eclipseCase) +void RigGridManager::addCase(RigCaseData* eclipseCase) { cvf::ref caseAndGrid = new CaseToGridMap(eclipseCase, eclipseCase->mainGrid()); m_caseToGrid.push_back(caseAndGrid.p()); @@ -33,7 +33,7 @@ void RigGridCollection::addCase(RigEclipseCase* eclipseCase) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigGridCollection::removeCase(RigEclipseCase* eclipseCase) +void RigGridManager::removeCase(RigCaseData* eclipseCase) { size_t indexToErase = cvf::UNDEFINED_SIZE_T; @@ -50,12 +50,12 @@ void RigGridCollection::removeCase(RigEclipseCase* eclipseCase) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RigMainGrid* RigGridCollection::findEqualGrid(RigMainGrid* candidateGrid) +RigMainGrid* RigGridManager::findEqualGrid(RigMainGrid* candidateGrid) { for (size_t i = 0; i < m_caseToGrid.size(); i++) { RigMainGrid* mainGrid = m_caseToGrid.at(i)->m_mainGrid; - if (RigGridCollection::isEqual(mainGrid, candidateGrid)) + if (RigGridManager::isEqual(mainGrid, candidateGrid)) { return mainGrid; } @@ -67,7 +67,7 @@ RigMainGrid* RigGridCollection::findEqualGrid(RigMainGrid* candidateGrid) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RigGridCollection::isEqual(RigMainGrid* gridA, RigMainGrid* gridB) +bool RigGridManager::isEqual(RigMainGrid* gridA, RigMainGrid* gridB) { if (gridA == NULL || gridB == NULL) return false; @@ -91,7 +91,7 @@ bool RigGridCollection::isEqual(RigMainGrid* gridA, RigMainGrid* gridB) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigGridCollection::clear() +void RigGridManager::clear() { m_caseToGrid.clear(); } @@ -99,7 +99,7 @@ void RigGridCollection::clear() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RigGridCollection::CaseToGridMap::CaseToGridMap(RigEclipseCase* eclipseCase, RigMainGrid* mainGrid) : +RigGridManager::CaseToGridMap::CaseToGridMap(RigCaseData* eclipseCase, RigMainGrid* mainGrid) : m_eclipseCase(eclipseCase), m_mainGrid(mainGrid) { diff --git a/ApplicationCode/ReservoirDataModel/RigGridCollection.h b/ApplicationCode/ReservoirDataModel/RigGridCollection.h index caa6476703..3d6dada127 100644 --- a/ApplicationCode/ReservoirDataModel/RigGridCollection.h +++ b/ApplicationCode/ReservoirDataModel/RigGridCollection.h @@ -25,14 +25,14 @@ #include class RigMainGrid; -class RigEclipseCase; +class RigCaseData; -class RigGridCollection : public cvf::Object +class RigGridManager : public cvf::Object { public: - void addCase(RigEclipseCase* eclipseCase); + void addCase(RigCaseData* eclipseCase); - void removeCase(RigEclipseCase* eclipseCase); + void removeCase(RigCaseData* eclipseCase); RigMainGrid* findEqualGrid(RigMainGrid* candidateGrid); @@ -45,9 +45,9 @@ private: class CaseToGridMap : public cvf::Object { public: - CaseToGridMap(RigEclipseCase* eclipseCase, RigMainGrid* mainGrid); + CaseToGridMap(RigCaseData* eclipseCase, RigMainGrid* mainGrid); - RigEclipseCase* m_eclipseCase; + RigCaseData* m_eclipseCase; RigMainGrid* m_mainGrid; }; diff --git a/ApplicationCode/ReservoirDataModel/RigGridScalarDataAccess.cpp b/ApplicationCode/ReservoirDataModel/RigGridScalarDataAccess.cpp index 0cf3407102..8377a35c67 100644 --- a/ApplicationCode/ReservoirDataModel/RigGridScalarDataAccess.cpp +++ b/ApplicationCode/ReservoirDataModel/RigGridScalarDataAccess.cpp @@ -133,7 +133,7 @@ private: //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -cvf::ref RigGridScalarDataAccessFactory::createPerGridDataAccessObject(RigEclipseCase* eclipseCase, +cvf::ref RigGridScalarDataAccessFactory::createPerGridDataAccessObject(RigCaseData* eclipseCase, size_t gridIndex, RifReaderInterface::PorosityModelResultType porosityModel, size_t timeStepIndex, diff --git a/ApplicationCode/ReservoirDataModel/RigGridScalarDataAccess.h b/ApplicationCode/ReservoirDataModel/RigGridScalarDataAccess.h index ce0bd96b0b..4757bf5d39 100644 --- a/ApplicationCode/ReservoirDataModel/RigGridScalarDataAccess.h +++ b/ApplicationCode/ReservoirDataModel/RigGridScalarDataAccess.h @@ -30,7 +30,7 @@ class RigGridScalarDataAccessFactory { public: static cvf::ref - createPerGridDataAccessObject(RigEclipseCase* eclipseCase, + createPerGridDataAccessObject(RigCaseData* eclipseCase, size_t gridIndex, RifReaderInterface::PorosityModelResultType porosityModel, size_t timeStepIndex, diff --git a/ApplicationCode/ReservoirDataModel/RigReservoirBuilderMock.cpp b/ApplicationCode/ReservoirDataModel/RigReservoirBuilderMock.cpp index 0ad79539ee..6f2dfccfb5 100644 --- a/ApplicationCode/ReservoirDataModel/RigReservoirBuilderMock.cpp +++ b/ApplicationCode/ReservoirDataModel/RigReservoirBuilderMock.cpp @@ -172,7 +172,7 @@ void RigReservoirBuilderMock::appendCells(size_t nodeStartIndex, size_t cellCoun //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigReservoirBuilderMock::populateReservoir(RigEclipseCase* eclipseCase) +void RigReservoirBuilderMock::populateReservoir(RigCaseData* eclipseCase) { std::vector& mainGridNodes = eclipseCase->mainGrid()->nodes(); appendNodes(m_minWorldCoordinate, m_maxWorldCoordinate, cellDimension(), mainGridNodes); @@ -278,7 +278,7 @@ void RigReservoirBuilderMock::setWorldCoordinates(cvf::Vec3d minWorldCoordinate, //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RigReservoirBuilderMock::inputProperty(RigEclipseCase* eclipseCase, const QString& propertyName, std::vector* values) +bool RigReservoirBuilderMock::inputProperty(RigCaseData* eclipseCase, const QString& propertyName, std::vector* values) { size_t k; @@ -299,7 +299,7 @@ bool RigReservoirBuilderMock::inputProperty(RigEclipseCase* eclipseCase, const Q //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RigReservoirBuilderMock::staticResult(RigEclipseCase* eclipseCase, const QString& result, std::vector* values) +bool RigReservoirBuilderMock::staticResult(RigCaseData* eclipseCase, const QString& result, std::vector* values) { size_t k; @@ -316,7 +316,7 @@ bool RigReservoirBuilderMock::staticResult(RigEclipseCase* eclipseCase, const QS //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RigReservoirBuilderMock::dynamicResult(RigEclipseCase* eclipseCase, const QString& result, size_t stepIndex, std::vector* values) +bool RigReservoirBuilderMock::dynamicResult(RigCaseData* eclipseCase, const QString& result, size_t stepIndex, std::vector* values) { int resultIndex = 1; @@ -352,19 +352,19 @@ bool RigReservoirBuilderMock::dynamicResult(RigEclipseCase* eclipseCase, const Q //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigReservoirBuilderMock::addWellData(RigEclipseCase* eclipseCase, RigGridBase* grid) +void RigReservoirBuilderMock::addWellData(RigCaseData* eclipseCase, RigGridBase* grid) { CVF_ASSERT(eclipseCase); CVF_ASSERT(grid); cvf::Vec3st dim = grid->gridPointDimensions(); - cvf::Collection wells; + cvf::Collection wells; int wellIdx; for (wellIdx = 0; wellIdx < 1; wellIdx++) { - cvf::ref wellCellsTimeHistory = new RigWellResults; + cvf::ref wellCellsTimeHistory = new RigSingleWellResultsData; wellCellsTimeHistory->m_wellName = QString("Well %1").arg(wellIdx); wellCellsTimeHistory->m_wellCellsTimeSteps.resize(m_timeStepCount); diff --git a/ApplicationCode/ReservoirDataModel/RigReservoirBuilderMock.h b/ApplicationCode/ReservoirDataModel/RigReservoirBuilderMock.h index 9ea0149b1d..c22bfbd926 100644 --- a/ApplicationCode/ReservoirDataModel/RigReservoirBuilderMock.h +++ b/ApplicationCode/ReservoirDataModel/RigReservoirBuilderMock.h @@ -55,14 +55,14 @@ public: void addLocalGridRefinement(const cvf::Vec3st& minCellPosition, const cvf::Vec3st& maxCellPosition, const cvf::Vec3st& singleCellRefinementFactors); - void populateReservoir(RigEclipseCase* eclipseCase); + void populateReservoir(RigCaseData* eclipseCase); - bool inputProperty(RigEclipseCase* eclipseCase, const QString& propertyName, std::vector* values ); - bool staticResult(RigEclipseCase* eclipseCase, const QString& result, std::vector* values ); - bool dynamicResult(RigEclipseCase* eclipseCase, const QString& result, size_t stepIndex, std::vector* values ); + bool inputProperty(RigCaseData* eclipseCase, const QString& propertyName, std::vector* values ); + bool staticResult(RigCaseData* eclipseCase, const QString& result, std::vector* values ); + bool dynamicResult(RigCaseData* eclipseCase, const QString& result, size_t stepIndex, std::vector* values ); private: - void addWellData(RigEclipseCase* eclipseCase, RigGridBase* grid); + void addWellData(RigCaseData* eclipseCase, RigGridBase* grid); static void appendCells(size_t nodeStartIndex, size_t cellCount, RigGridBase* hostGrid, std::vector& cells); static void appendNodes(const cvf::Vec3d& min, const cvf::Vec3d& max, const cvf::Vec3st& cubeDimension, std::vector& nodes); diff --git a/ApplicationCode/ReservoirDataModel/RigReservoirCellResults.cpp b/ApplicationCode/ReservoirDataModel/RigReservoirCellResults.cpp index 4ee9d29606..115ad0a66a 100644 --- a/ApplicationCode/ReservoirDataModel/RigReservoirCellResults.cpp +++ b/ApplicationCode/ReservoirDataModel/RigReservoirCellResults.cpp @@ -27,7 +27,7 @@ //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RigReservoirCellResults::RigReservoirCellResults(RigMainGrid* ownerGrid) +RigCaseCellResultsData::RigCaseCellResultsData(RigMainGrid* ownerGrid) { CVF_ASSERT(ownerGrid != NULL); m_ownerMainGrid = ownerGrid; @@ -37,7 +37,7 @@ RigReservoirCellResults::RigReservoirCellResults(RigMainGrid* ownerGrid) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigReservoirCellResults::setMainGrid(RigMainGrid* ownerGrid) +void RigCaseCellResultsData::setMainGrid(RigMainGrid* ownerGrid) { m_ownerMainGrid = ownerGrid; } @@ -45,7 +45,7 @@ void RigReservoirCellResults::setMainGrid(RigMainGrid* ownerGrid) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigReservoirCellResults::minMaxCellScalarValues( size_t scalarResultIndex, double& min, double& max ) +void RigCaseCellResultsData::minMaxCellScalarValues( size_t scalarResultIndex, double& min, double& max ) { min = HUGE_VAL; max = -HUGE_VAL; @@ -83,7 +83,7 @@ void RigReservoirCellResults::minMaxCellScalarValues( size_t scalarResultIndex, //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigReservoirCellResults::minMaxCellScalarValues(size_t scalarResultIndex, size_t timeStepIndex, double& min, double& max) +void RigCaseCellResultsData::minMaxCellScalarValues(size_t scalarResultIndex, size_t timeStepIndex, double& min, double& max) { min = HUGE_VAL; max = -HUGE_VAL; @@ -137,7 +137,7 @@ void RigReservoirCellResults::minMaxCellScalarValues(size_t scalarResultIndex, s //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -const std::vector& RigReservoirCellResults::cellScalarValuesHistogram(size_t scalarResultIndex) +const std::vector& RigCaseCellResultsData::cellScalarValuesHistogram(size_t scalarResultIndex) { CVF_ASSERT(scalarResultIndex < resultCount()); @@ -178,7 +178,7 @@ const std::vector& RigReservoirCellResults::cellScalarValuesHistogram(si //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigReservoirCellResults::p10p90CellScalarValues(size_t scalarResultIndex, double& p10, double& p90) +void RigCaseCellResultsData::p10p90CellScalarValues(size_t scalarResultIndex, double& p10, double& p90) { const std::vector& histogr = cellScalarValuesHistogram( scalarResultIndex); p10 = m_p10p90[scalarResultIndex].first; @@ -188,7 +188,7 @@ void RigReservoirCellResults::p10p90CellScalarValues(size_t scalarResultIndex, d //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigReservoirCellResults::meanCellScalarValues(size_t scalarResultIndex, double& meanValue) +void RigCaseCellResultsData::meanCellScalarValues(size_t scalarResultIndex, double& meanValue) { CVF_ASSERT(scalarResultIndex < resultCount()); @@ -224,7 +224,7 @@ void RigReservoirCellResults::meanCellScalarValues(size_t scalarResultIndex, dou //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -size_t RigReservoirCellResults::resultCount() const +size_t RigCaseCellResultsData::resultCount() const { return m_cellScalarResults.size(); } @@ -232,7 +232,7 @@ size_t RigReservoirCellResults::resultCount() const //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -size_t RigReservoirCellResults::timeStepCount(size_t scalarResultIndex) const +size_t RigCaseCellResultsData::timeStepCount(size_t scalarResultIndex) const { CVF_TIGHT_ASSERT(scalarResultIndex < resultCount()); @@ -242,7 +242,7 @@ size_t RigReservoirCellResults::timeStepCount(size_t scalarResultIndex) const //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -const std::vector< std::vector > & RigReservoirCellResults::cellScalarResults( size_t scalarResultIndex ) const +const std::vector< std::vector > & RigCaseCellResultsData::cellScalarResults( size_t scalarResultIndex ) const { CVF_TIGHT_ASSERT(scalarResultIndex < resultCount()); @@ -252,7 +252,7 @@ const std::vector< std::vector > & RigReservoirCellResults::cellScalarRe //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -std::vector< std::vector > & RigReservoirCellResults::cellScalarResults( size_t scalarResultIndex ) +std::vector< std::vector > & RigCaseCellResultsData::cellScalarResults( size_t scalarResultIndex ) { CVF_TIGHT_ASSERT(scalarResultIndex < resultCount()); @@ -262,7 +262,7 @@ std::vector< std::vector > & RigReservoirCellResults::cellScalarResults( //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -std::vector& RigReservoirCellResults::cellScalarResults(size_t scalarResultIndex, size_t timeStepIndex) +std::vector& RigCaseCellResultsData::cellScalarResults(size_t scalarResultIndex, size_t timeStepIndex) { CVF_TIGHT_ASSERT(scalarResultIndex < resultCount()); CVF_TIGHT_ASSERT(timeStepIndex < m_cellScalarResults[scalarResultIndex].size()); @@ -273,7 +273,7 @@ std::vector& RigReservoirCellResults::cellScalarResults(size_t scalarRes //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -double RigReservoirCellResults::cellScalarResult( size_t scalarResultIndex, size_t timeStepIndex, size_t resultValueIndex) +double RigCaseCellResultsData::cellScalarResult( size_t scalarResultIndex, size_t timeStepIndex, size_t resultValueIndex) { if (scalarResultIndex < resultCount() && timeStepIndex < m_cellScalarResults[scalarResultIndex].size() && @@ -292,7 +292,7 @@ double RigReservoirCellResults::cellScalarResult( size_t scalarResultIndex, size //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -size_t RigReservoirCellResults::findScalarResultIndex(RimDefines::ResultCatType type, const QString& resultName) const +size_t RigCaseCellResultsData::findScalarResultIndex(RimDefines::ResultCatType type, const QString& resultName) const { std::vector::const_iterator it; for (it = m_resultInfos.begin(); it != m_resultInfos.end(); it++) @@ -309,7 +309,7 @@ size_t RigReservoirCellResults::findScalarResultIndex(RimDefines::ResultCatType //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -size_t RigReservoirCellResults::findScalarResultIndex(const QString& resultName) const +size_t RigCaseCellResultsData::findScalarResultIndex(const QString& resultName) const { size_t scalarResultIndex = cvf::UNDEFINED_SIZE_T; @@ -337,7 +337,7 @@ size_t RigReservoirCellResults::findScalarResultIndex(const QString& resultName) /// Adds an empty scalar set, and returns the scalarResultIndex to it. /// if resultName already exists, it returns the scalarResultIndex to the existing result. //-------------------------------------------------------------------------------------------------- -size_t RigReservoirCellResults::addEmptyScalarResult(RimDefines::ResultCatType type, const QString& resultName, bool needsToBeStored) +size_t RigCaseCellResultsData::addEmptyScalarResult(RimDefines::ResultCatType type, const QString& resultName, bool needsToBeStored) { size_t scalarResultIndex = cvf::UNDEFINED_SIZE_T; @@ -356,7 +356,7 @@ size_t RigReservoirCellResults::addEmptyScalarResult(RimDefines::ResultCatType t //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -QStringList RigReservoirCellResults::resultNames(RimDefines::ResultCatType resType) const +QStringList RigCaseCellResultsData::resultNames(RimDefines::ResultCatType resType) const { QStringList varList; std::vector::const_iterator it; @@ -373,7 +373,7 @@ QStringList RigReservoirCellResults::resultNames(RimDefines::ResultCatType resTy //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigReservoirCellResults::recalculateMinMax(size_t scalarResultIndex) +void RigCaseCellResultsData::recalculateMinMax(size_t scalarResultIndex) { // Make sure cached max min values are recalculated next time asked for, since // the data could be changed. @@ -392,7 +392,7 @@ void RigReservoirCellResults::recalculateMinMax(size_t scalarResultIndex) //-------------------------------------------------------------------------------------------------- /// Returns whether the result data in question is addressed by Active Cell Index //-------------------------------------------------------------------------------------------------- -bool RigReservoirCellResults::isUsingGlobalActiveIndex(size_t scalarResultIndex) const +bool RigCaseCellResultsData::isUsingGlobalActiveIndex(size_t scalarResultIndex) const { CVF_TIGHT_ASSERT(scalarResultIndex < m_cellScalarResults.size()); @@ -407,7 +407,7 @@ bool RigReservoirCellResults::isUsingGlobalActiveIndex(size_t scalarResultIndex) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -QDateTime RigReservoirCellResults::timeStepDate(size_t scalarResultIndex, size_t timeStepIndex) const +QDateTime RigCaseCellResultsData::timeStepDate(size_t scalarResultIndex, size_t timeStepIndex) const { if (scalarResultIndex < m_resultInfos.size() && (size_t)(m_resultInfos[scalarResultIndex].m_timeStepDates.size()) > timeStepIndex) return m_resultInfos[scalarResultIndex].m_timeStepDates[static_cast(timeStepIndex)]; @@ -418,7 +418,7 @@ QDateTime RigReservoirCellResults::timeStepDate(size_t scalarResultIndex, size_t //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -std::vector RigReservoirCellResults::timeStepDates(size_t scalarResultIndex) const +std::vector RigCaseCellResultsData::timeStepDates(size_t scalarResultIndex) const { if (scalarResultIndex < m_resultInfos.size() ) return m_resultInfos[scalarResultIndex].m_timeStepDates; @@ -429,7 +429,7 @@ std::vector RigReservoirCellResults::timeStepDates(size_t scalarResul //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigReservoirCellResults::setTimeStepDates(size_t scalarResultIndex, const std::vector& dates) +void RigCaseCellResultsData::setTimeStepDates(size_t scalarResultIndex, const std::vector& dates) { CVF_ASSERT(scalarResultIndex < m_resultInfos.size() ); @@ -442,7 +442,7 @@ void RigReservoirCellResults::setTimeStepDates(size_t scalarResultIndex, const s //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -size_t RigReservoirCellResults::maxTimeStepCount(size_t* scalarResultIndexWithMostTimeSteps) const +size_t RigCaseCellResultsData::maxTimeStepCount(size_t* scalarResultIndexWithMostTimeSteps) const { size_t maxTsCount = 0; size_t scalarResultIndexWithMaxTsCount = cvf::UNDEFINED_SIZE_T; @@ -467,7 +467,7 @@ size_t RigReservoirCellResults::maxTimeStepCount(size_t* scalarResultIndexWithMo //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -QString RigReservoirCellResults::makeResultNameUnique(const QString& resultNameProposal) const +QString RigCaseCellResultsData::makeResultNameUnique(const QString& resultNameProposal) const { QString newResultName = resultNameProposal; size_t resultIndex = cvf::UNDEFINED_SIZE_T; @@ -489,7 +489,7 @@ QString RigReservoirCellResults::makeResultNameUnique(const QString& resultNameP //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigReservoirCellResults::removeResult(const QString& resultName) +void RigCaseCellResultsData::removeResult(const QString& resultName) { size_t resultIdx = findScalarResultIndex(resultName); if (resultIdx == cvf::UNDEFINED_SIZE_T) return; @@ -502,7 +502,7 @@ void RigReservoirCellResults::removeResult(const QString& resultName) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigReservoirCellResults::clearAllResults() +void RigCaseCellResultsData::clearAllResults() { m_cellScalarResults.clear(); m_maxMinValues.clear(); @@ -516,7 +516,7 @@ void RigReservoirCellResults::clearAllResults() //-------------------------------------------------------------------------------------------------- /// Add a result with given type and name, and allocate one result vector for the static result values //-------------------------------------------------------------------------------------------------- -size_t RigReservoirCellResults::addStaticScalarResult(RimDefines::ResultCatType type, const QString& resultName, bool needsToBeStored, size_t resultValueCount) +size_t RigCaseCellResultsData::addStaticScalarResult(RimDefines::ResultCatType type, const QString& resultName, bool needsToBeStored, size_t resultValueCount) { size_t resultIdx = addEmptyScalarResult(type, resultName, needsToBeStored); @@ -529,7 +529,7 @@ size_t RigReservoirCellResults::addStaticScalarResult(RimDefines::ResultCatType //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RifReaderInterface::PorosityModelResultType RigReservoirCellResults::convertFromProjectModelPorosityModel(RimDefines::PorosityModelType porosityModel) +RifReaderInterface::PorosityModelResultType RigCaseCellResultsData::convertFromProjectModelPorosityModel(RimDefines::PorosityModelType porosityModel) { if (porosityModel == RimDefines::MATRIX_MODEL) return RifReaderInterface::MATRIX_RESULTS; diff --git a/ApplicationCode/ReservoirDataModel/RigReservoirCellResults.h b/ApplicationCode/ReservoirDataModel/RigReservoirCellResults.h index 6fa3caca61..31ec57dae4 100644 --- a/ApplicationCode/ReservoirDataModel/RigReservoirCellResults.h +++ b/ApplicationCode/ReservoirDataModel/RigReservoirCellResults.h @@ -30,10 +30,10 @@ class RigMainGrid; //================================================================================================== /// Class containing the results for the complete number of active cells. Both main grid and LGR's //================================================================================================== -class RigReservoirCellResults : public cvf::Object +class RigCaseCellResultsData : public cvf::Object { public: - RigReservoirCellResults(RigMainGrid* ownerGrid); + RigCaseCellResultsData(RigMainGrid* ownerGrid); void setMainGrid(RigMainGrid* ownerGrid); diff --git a/ApplicationCode/ReservoirDataModel/RigWellResults.cpp b/ApplicationCode/ReservoirDataModel/RigWellResults.cpp index b1080e2bac..a52fea4430 100644 --- a/ApplicationCode/ReservoirDataModel/RigWellResults.cpp +++ b/ApplicationCode/ReservoirDataModel/RigWellResults.cpp @@ -24,7 +24,7 @@ //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -const RigWellResultFrame& RigWellResults::wellResultFrame(size_t resultTimeStepIndex) const +const RigWellResultFrame& RigSingleWellResultsData::wellResultFrame(size_t resultTimeStepIndex) const { CVF_ASSERT(resultTimeStepIndex < m_resultTimeStepIndexToWellTimeStepIndex.size()); @@ -37,7 +37,7 @@ const RigWellResultFrame& RigWellResults::wellResultFrame(size_t resultTimeStepI //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigWellResults::computeMappingFromResultTimeIndicesToWellTimeIndices(const std::vector& resultTimes) +void RigSingleWellResultsData::computeMappingFromResultTimeIndicesToWellTimeIndices(const std::vector& resultTimes) { m_resultTimeStepIndexToWellTimeStepIndex.clear(); if (m_wellCellsTimeSteps.size() == 0) return; @@ -83,7 +83,7 @@ void RigWellResults::computeMappingFromResultTimeIndicesToWellTimeIndices(const //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RigWellResults::hasWellResult(size_t resultTimeStepIndex) const +bool RigSingleWellResultsData::hasWellResult(size_t resultTimeStepIndex) const { size_t wellTimeStepIndex = m_resultTimeStepIndexToWellTimeStepIndex[resultTimeStepIndex]; @@ -93,7 +93,7 @@ bool RigWellResults::hasWellResult(size_t resultTimeStepIndex) const //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -size_t RigWellResults::firstResultTimeStep() const +size_t RigSingleWellResultsData::firstResultTimeStep() const { size_t i = 0; for(i = 0; i < m_resultTimeStepIndexToWellTimeStepIndex.size(); ++i) @@ -108,7 +108,7 @@ size_t RigWellResults::firstResultTimeStep() const //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RigWellResults::computeStaticWellCellPath() +void RigSingleWellResultsData::computeStaticWellCellPath() { if (m_wellCellsTimeSteps.size() == 0) return; diff --git a/ApplicationCode/ReservoirDataModel/RigWellResults.h b/ApplicationCode/ReservoirDataModel/RigWellResults.h index dce4c4c7ec..7e27f23073 100644 --- a/ApplicationCode/ReservoirDataModel/RigWellResults.h +++ b/ApplicationCode/ReservoirDataModel/RigWellResults.h @@ -99,7 +99,7 @@ public: //================================================================================================== /// //================================================================================================== -class RigWellResults : public cvf::Object +class RigSingleWellResultsData : public cvf::Object { public: bool hasWellResult(size_t resultTimeStepIndex) const; diff --git a/ApplicationCode/SocketInterface/RiaSocketServer.cpp b/ApplicationCode/SocketInterface/RiaSocketServer.cpp index 9a1aac8d00..092aece862 100644 --- a/ApplicationCode/SocketInterface/RiaSocketServer.cpp +++ b/ApplicationCode/SocketInterface/RiaSocketServer.cpp @@ -151,7 +151,7 @@ void RiaSocketServer::handleClientConnection(QTcpSocket* clientToHandle) //-------------------------------------------------------------------------------------------------- /// Find the requested reservoir: Current, by index or by name //-------------------------------------------------------------------------------------------------- -RimReservoir* RiaSocketServer::findReservoir(const QString& caseName) +RimCase* RiaSocketServer::findReservoir(const QString& caseName) { if (caseName.isEmpty()) { @@ -241,7 +241,7 @@ void RiaSocketServer::readCommandFromOctave() QString caseName; QString propertyName; - RimReservoir* reservoir = NULL; + RimCase* reservoir = NULL; // Find the correct arguments @@ -502,7 +502,7 @@ void RiaSocketServer::readPropertyDataFromOctave() if (m_currentReservoir != NULL) { // Create a new input property if we have an input reservoir - RimInputReservoir* inputRes = dynamic_cast(m_currentReservoir); + RimInputCase* inputRes = dynamic_cast(m_currentReservoir); if (inputRes) { RimInputProperty* inputProperty = NULL; diff --git a/ApplicationCode/SocketInterface/RiaSocketServer.h b/ApplicationCode/SocketInterface/RiaSocketServer.h index 8a6f2e7e4e..6e19a1bb74 100644 --- a/ApplicationCode/SocketInterface/RiaSocketServer.h +++ b/ApplicationCode/SocketInterface/RiaSocketServer.h @@ -27,7 +27,7 @@ class QTcpServer; class QTcpSocket; class QNetworkSession; class QErrorMessage; -class RimReservoir; +class RimCase; class RiaSocketServer : public QObject @@ -53,7 +53,7 @@ private: void handleClientConnection( QTcpSocket* clientToHandle); - RimReservoir* findReservoir(const QString &casename); + RimCase* findReservoir(const QString &casename); void terminateCurrentConnection(); void calculateMatrixModelActiveCellInfo(std::vector& gridNumber, @@ -80,7 +80,7 @@ private: quint64 m_bytesPerTimeStepToRead; size_t m_currentTimeStepToRead; std::vector< std::vector >* m_scalarResultsToAdd; - RimReservoir* m_currentReservoir; + RimCase* m_currentReservoir; size_t m_currentScalarIndex; QString m_currentPropertyName; bool m_invalidActiveCellCountDetected; diff --git a/ApplicationCode/UserInterface/RIMainWindow.cpp b/ApplicationCode/UserInterface/RIMainWindow.cpp index d391e3e0dc..5073f1b446 100644 --- a/ApplicationCode/UserInterface/RIMainWindow.cpp +++ b/ApplicationCode/UserInterface/RIMainWindow.cpp @@ -976,7 +976,7 @@ void RIMainWindow::slotSubWindowActivated(QMdiSubWindow* subWindow) size_t i; for (i = 0; i < proj->reservoirs().size(); ++i) { - RimReservoir* ri = proj->reservoirs()[i]; + RimCase* ri = proj->reservoirs()[i]; if (!ri) continue; size_t j;