2013-03-18 11:40:39 +01:00
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
//
|
2014-09-24 07:14:52 +02:00
|
|
|
// Copyright (C) Statoil ASA
|
|
|
|
|
// Copyright (C) Ceetron Solutions AS
|
2013-03-18 11:40:39 +01: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 10:55:00 +02:00
|
|
|
|
2017-06-13 15:41:52 +02:00
|
|
|
#include "RiaDefines.h"
|
2015-07-31 18:58:23 +02:00
|
|
|
|
2014-07-24 10:11:43 +02:00
|
|
|
#include "cafAppEnum.h"
|
2015-07-31 18:58:23 +02:00
|
|
|
#include "cafPdmChildArrayField.h"
|
2013-03-18 11:40:39 +01:00
|
|
|
#include "cafPdmField.h"
|
|
|
|
|
#include "cafPdmObject.h"
|
2015-07-31 18:58:23 +02:00
|
|
|
|
2014-07-24 10:11:43 +02:00
|
|
|
#include "cvfBase.h"
|
|
|
|
|
#include "cvfObject.h"
|
|
|
|
|
|
2013-03-18 11:40:39 +01:00
|
|
|
|
2014-07-24 10:11:43 +02:00
|
|
|
#include <QDateTime>
|
|
|
|
|
|
2013-03-19 10:29:34 +01:00
|
|
|
class RimReservoirCellResultsStorageEntryInfo;
|
2013-03-22 15:43:42 +01:00
|
|
|
class RigCaseCellResultsData;
|
2013-03-18 14:34:29 +01:00
|
|
|
class RifReaderInterface;
|
|
|
|
|
class RigMainGrid;
|
2013-03-18 11:40:39 +01:00
|
|
|
|
2013-03-19 10:29:34 +01:00
|
|
|
class RimReservoirCellResultsStorage : public caf::PdmObject
|
2013-03-18 11:40:39 +01:00
|
|
|
{
|
|
|
|
|
CAF_PDM_HEADER_INIT;
|
|
|
|
|
public:
|
2013-03-19 10:29:34 +01:00
|
|
|
RimReservoirCellResultsStorage();
|
|
|
|
|
virtual ~RimReservoirCellResultsStorage();
|
2013-03-18 11:40:39 +01:00
|
|
|
|
2013-03-22 15:43:42 +01:00
|
|
|
void setCellResults(RigCaseCellResultsData* cellResults);
|
2013-03-18 11:40:39 +01:00
|
|
|
|
2013-03-21 15:31:47 +01:00
|
|
|
size_t storedResultsCount();
|
|
|
|
|
|
|
|
|
|
protected:
|
2013-03-18 14:34:29 +01:00
|
|
|
// Overridden methods from PdmObject
|
2013-03-19 09:08:37 +01:00
|
|
|
virtual void setupBeforeSave();
|
2013-03-18 11:40:39 +01:00
|
|
|
|
2013-03-18 14:34:29 +01:00
|
|
|
private:
|
2013-03-19 09:08:37 +01:00
|
|
|
QString getValidCacheFileName();
|
|
|
|
|
QString getCacheDirectoryPath();
|
2013-03-21 15:31:47 +01:00
|
|
|
// Fields
|
|
|
|
|
caf::PdmField<QString> m_resultCacheFileName;
|
2015-07-31 18:58:23 +02:00
|
|
|
caf::PdmChildArrayField<RimReservoirCellResultsStorageEntryInfo*>
|
2013-06-26 23:26:01 +02:00
|
|
|
m_resultCacheMetaData;
|
2013-03-21 15:31:47 +01:00
|
|
|
|
2013-06-26 23:26:01 +02:00
|
|
|
RigCaseCellResultsData* m_cellResults;
|
2013-03-18 11:40:39 +01:00
|
|
|
};
|
|
|
|
|
|
2013-03-19 10:29:34 +01:00
|
|
|
class RimReservoirCellResultsStorageEntryInfo : public caf::PdmObject
|
2013-03-18 11:40:39 +01:00
|
|
|
{
|
|
|
|
|
CAF_PDM_HEADER_INIT;
|
|
|
|
|
public:
|
2013-03-19 10:29:34 +01:00
|
|
|
RimReservoirCellResultsStorageEntryInfo();
|
|
|
|
|
virtual ~RimReservoirCellResultsStorageEntryInfo();
|
2013-03-18 11:40:39 +01:00
|
|
|
|
2017-06-13 15:41:52 +02:00
|
|
|
caf::PdmField<caf::AppEnum< RiaDefines::ResultCatType> > m_resultType;
|
2013-03-18 11:40:39 +01:00
|
|
|
caf::PdmField<QString> m_resultName;
|
|
|
|
|
caf::PdmField< std::vector <QDateTime> > m_timeStepDates;
|
2017-04-26 09:39:17 +02:00
|
|
|
caf::PdmField< std::vector <double> > m_daysSinceSimulationStart;
|
2013-03-18 11:40:39 +01:00
|
|
|
caf::PdmField<qint64> m_filePosition;
|
|
|
|
|
};
|
|
|
|
|
|