mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#1693 Remove and move stuff away from RimReservoirCellResultsStorage
To make its sole responsibility to store/restore generated results to/from cache file
This commit is contained in:
@@ -440,6 +440,22 @@ bool RigCaseCellResultsData::hasFlowDiagUsableFluxes() const
|
||||
return hasFlowFluxes;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
std::vector<QDateTime> RigCaseCellResultsData::allTimeStepDatesFromEclipseReader() const
|
||||
{
|
||||
const RifReaderEclipseOutput* rifReaderOutput = dynamic_cast<const RifReaderEclipseOutput*>(m_readerInterface.p());
|
||||
if (rifReaderOutput)
|
||||
{
|
||||
return rifReaderOutput->allTimeSteps();
|
||||
}
|
||||
else
|
||||
{
|
||||
return std::vector<QDateTime>();
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -597,14 +613,14 @@ QString RigCaseCellResultsData::makeResultNameUnique(const QString& resultNamePr
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RigCaseCellResultsData::removeResult(const QString& resultName)
|
||||
void RigCaseCellResultsData::clearScalarResult(RiaDefines::ResultCatType type, const QString & resultName)
|
||||
{
|
||||
size_t resultIdx = findScalarResultIndex(resultName);
|
||||
if (resultIdx == cvf::UNDEFINED_SIZE_T) return;
|
||||
size_t scalarResultIndex = this->findScalarResultIndex(type, resultName);
|
||||
if (scalarResultIndex == cvf::UNDEFINED_SIZE_T) return;
|
||||
|
||||
m_cellScalarResults[resultIdx].clear();
|
||||
m_cellScalarResults[scalarResultIndex].clear();
|
||||
|
||||
m_resultInfos[resultIdx].m_resultType = RiaDefines::REMOVED;
|
||||
//m_resultInfos[scalarResultIndex].m_resultType = RiaDefines::REMOVED;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -2124,6 +2140,18 @@ void RigCaseCellResultsData::setReaderInterface(RifReaderInterface* readerInterf
|
||||
}
|
||||
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RigCaseCellResultsData::setHdf5Filename(const QString& hdf5SourSimFilename)
|
||||
{
|
||||
RifReaderEclipseOutput* rifReaderOutput = dynamic_cast<RifReaderEclipseOutput*>(m_readerInterface.p());
|
||||
if (rifReaderOutput)
|
||||
{
|
||||
rifReaderOutput->setHdf5FileName(hdf5SourSimFilename);
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
/// If we have any results on any time step, assume we have loaded results
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user