2013-03-18 05:40:39 -05:00
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
//
|
2014-09-24 00:14:52 -05:00
|
|
|
// Copyright (C) Statoil ASA
|
|
|
|
// Copyright (C) Ceetron Solutions AS
|
2013-03-18 05:40:39 -05:00
|
|
|
//
|
|
|
|
// ResInsight is free software: you can redistribute it and/or modify
|
|
|
|
// it under the terms of the GNU General Public License as published by
|
|
|
|
// the Free Software Foundation, either version 3 of the License, or
|
|
|
|
// (at your option) any later version.
|
|
|
|
//
|
|
|
|
// ResInsight is distributed in the hope that it will be useful, but WITHOUT ANY
|
|
|
|
// WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
|
|
// FITNESS FOR A PARTICULAR PURPOSE.
|
|
|
|
//
|
|
|
|
// See the GNU General Public License at <http://www.gnu.org/licenses/gpl.html>
|
|
|
|
// for more details.
|
|
|
|
//
|
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
2013-05-06 03:55:00 -05:00
|
|
|
|
2017-06-13 08:41:52 -05:00
|
|
|
#include "RiaDefines.h"
|
2015-07-31 11:58:23 -05:00
|
|
|
|
2014-07-24 03:11:43 -05:00
|
|
|
#include "cafAppEnum.h"
|
2015-07-31 11:58:23 -05:00
|
|
|
#include "cafPdmChildArrayField.h"
|
2013-03-18 05:40:39 -05:00
|
|
|
#include "cafPdmField.h"
|
|
|
|
#include "cafPdmObject.h"
|
2015-07-31 11:58:23 -05:00
|
|
|
|
2014-07-24 03:11:43 -05:00
|
|
|
#include "cvfBase.h"
|
|
|
|
#include "cvfObject.h"
|
|
|
|
|
2013-03-18 05:40:39 -05:00
|
|
|
|
2014-07-24 03:11:43 -05:00
|
|
|
#include <QDateTime>
|
|
|
|
|
2013-03-19 04:29:34 -05:00
|
|
|
class RimReservoirCellResultsStorageEntryInfo;
|
2013-03-22 09:43:42 -05:00
|
|
|
class RigCaseCellResultsData;
|
2013-03-18 08:34:29 -05:00
|
|
|
class RifReaderInterface;
|
|
|
|
class RigMainGrid;
|
2013-03-18 05:40:39 -05:00
|
|
|
|
2013-03-19 04:29:34 -05:00
|
|
|
class RimReservoirCellResultsStorage : public caf::PdmObject
|
2013-03-18 05:40:39 -05:00
|
|
|
{
|
|
|
|
CAF_PDM_HEADER_INIT;
|
|
|
|
public:
|
2013-03-19 04:29:34 -05:00
|
|
|
RimReservoirCellResultsStorage();
|
2018-10-18 12:45:57 -05:00
|
|
|
~RimReservoirCellResultsStorage() override;
|
2013-03-18 05:40:39 -05:00
|
|
|
|
2013-03-22 09:43:42 -05:00
|
|
|
void setCellResults(RigCaseCellResultsData* cellResults);
|
2013-03-18 05:40:39 -05:00
|
|
|
|
2013-03-21 09:31:47 -05:00
|
|
|
size_t storedResultsCount();
|
|
|
|
|
|
|
|
protected:
|
2013-03-18 08:34:29 -05:00
|
|
|
// Overridden methods from PdmObject
|
2018-10-18 12:45:57 -05:00
|
|
|
void setupBeforeSave() override;
|
2013-03-18 05:40:39 -05:00
|
|
|
|
2013-03-18 08:34:29 -05:00
|
|
|
private:
|
2013-03-19 03:08:37 -05:00
|
|
|
QString getValidCacheFileName();
|
|
|
|
QString getCacheDirectoryPath();
|
2013-03-21 09:31:47 -05:00
|
|
|
// Fields
|
|
|
|
caf::PdmField<QString> m_resultCacheFileName;
|
2015-07-31 11:58:23 -05:00
|
|
|
caf::PdmChildArrayField<RimReservoirCellResultsStorageEntryInfo*>
|
2013-06-26 16:26:01 -05:00
|
|
|
m_resultCacheMetaData;
|
2013-03-21 09:31:47 -05:00
|
|
|
|
2013-06-26 16:26:01 -05:00
|
|
|
RigCaseCellResultsData* m_cellResults;
|
2013-03-18 05:40:39 -05:00
|
|
|
};
|
|
|
|
|
2013-03-19 04:29:34 -05:00
|
|
|
class RimReservoirCellResultsStorageEntryInfo : public caf::PdmObject
|
2013-03-18 05:40:39 -05:00
|
|
|
{
|
|
|
|
CAF_PDM_HEADER_INIT;
|
|
|
|
public:
|
2013-03-19 04:29:34 -05:00
|
|
|
RimReservoirCellResultsStorageEntryInfo();
|
2018-10-18 12:45:57 -05:00
|
|
|
~RimReservoirCellResultsStorageEntryInfo() override;
|
2013-03-18 05:40:39 -05:00
|
|
|
|
2017-06-13 08:41:52 -05:00
|
|
|
caf::PdmField<caf::AppEnum< RiaDefines::ResultCatType> > m_resultType;
|
2013-03-18 05:40:39 -05:00
|
|
|
caf::PdmField<QString> m_resultName;
|
|
|
|
caf::PdmField< std::vector <QDateTime> > m_timeStepDates;
|
2017-04-26 02:39:17 -05:00
|
|
|
caf::PdmField< std::vector <double> > m_daysSinceSimulationStart;
|
2013-03-18 05:40:39 -05:00
|
|
|
caf::PdmField<qint64> m_filePosition;
|
|
|
|
};
|
|
|
|
|