2012-05-18 09:45:23 +02:00
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
//
|
2014-09-23 15:04:57 +02:00
|
|
|
// Copyright (C) 2011- Statoil ASA
|
|
|
|
|
// Copyright (C) 2013- Ceetron Solutions AS
|
|
|
|
|
// Copyright (C) 2011-2012 Ceetron AS
|
2012-05-18 09:45:23 +02: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
|
|
|
|
|
|
|
|
|
|
#include "cvfBase.h"
|
|
|
|
|
#include "cvfObject.h"
|
2015-07-31 18:58:23 +02:00
|
|
|
|
|
|
|
|
#include "RimCase.h"
|
|
|
|
|
#include "RimEclipseView.h"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#include "cafPdmChildArrayField.h"
|
|
|
|
|
#include "cafPdmChildField.h"
|
2012-05-18 09:45:23 +02:00
|
|
|
#include "cafPdmField.h"
|
|
|
|
|
#include "cafPdmObject.h"
|
2015-07-31 18:58:23 +02:00
|
|
|
|
2013-03-18 14:34:29 +01:00
|
|
|
#include "RifReaderInterface.h"
|
2015-07-31 18:58:23 +02:00
|
|
|
|
2012-05-18 09:45:23 +02:00
|
|
|
class QString;
|
2012-08-31 19:12:47 +02:00
|
|
|
|
2013-03-22 15:43:42 +01:00
|
|
|
class RigCaseData;
|
2012-05-18 09:45:23 +02:00
|
|
|
class RigGridBase;
|
2013-03-13 11:42:26 +01:00
|
|
|
class RimCaseCollection;
|
2013-04-08 12:16:38 +02:00
|
|
|
class RimIdenticalGridCaseGroup;
|
2013-05-06 10:55:00 +02:00
|
|
|
class RimReservoirCellResultsStorage;
|
2012-05-18 09:45:23 +02:00
|
|
|
|
2015-05-15 18:51:49 +02:00
|
|
|
|
2012-05-18 09:45:23 +02:00
|
|
|
//==================================================================================================
|
|
|
|
|
//
|
2012-06-26 16:10:41 +02:00
|
|
|
// Interface for reservoirs.
|
|
|
|
|
//
|
2012-05-18 09:45:23 +02:00
|
|
|
//==================================================================================================
|
2015-05-15 18:51:49 +02:00
|
|
|
class RimEclipseCase : public RimCase
|
2012-05-18 09:45:23 +02:00
|
|
|
{
|
2013-03-18 11:40:39 +01:00
|
|
|
CAF_PDM_HEADER_INIT;
|
2012-05-18 09:45:23 +02:00
|
|
|
public:
|
2015-05-15 08:40:27 +02:00
|
|
|
RimEclipseCase();
|
|
|
|
|
virtual ~RimEclipseCase();
|
2012-05-18 09:45:23 +02:00
|
|
|
|
2013-04-11 12:06:38 +02:00
|
|
|
|
2013-03-18 14:34:29 +01:00
|
|
|
// Fields:
|
|
|
|
|
caf::PdmField<bool> releaseResultMemory;
|
2015-07-31 18:58:23 +02:00
|
|
|
caf::PdmChildArrayField<RimEclipseView*> reservoirViews;
|
2013-04-26 13:19:34 +02:00
|
|
|
caf::PdmField<bool> flipXAxis;
|
|
|
|
|
caf::PdmField<bool> flipYAxis;
|
2013-12-17 11:37:58 +01:00
|
|
|
|
|
|
|
|
caf::PdmField<std::vector<QString> > filesContainingFaults;
|
2013-04-26 13:19:34 +02:00
|
|
|
|
2012-06-26 16:10:41 +02:00
|
|
|
|
2014-08-21 08:39:19 +02:00
|
|
|
bool openReserviorCase();
|
2015-05-15 18:51:49 +02:00
|
|
|
virtual bool openEclipseGridFile() = 0;
|
2013-03-18 14:34:29 +01:00
|
|
|
|
2013-04-11 12:06:38 +02:00
|
|
|
RigCaseData* reservoirData();
|
|
|
|
|
const RigCaseData* reservoirData() const;
|
2012-05-18 09:45:23 +02:00
|
|
|
|
2013-03-19 10:29:34 +01:00
|
|
|
RimReservoirCellResultsStorage* results(RifReaderInterface::PorosityModelResultType porosityModel);
|
2013-03-18 14:34:29 +01:00
|
|
|
|
2015-05-21 10:05:33 +02:00
|
|
|
RimEclipseView* createAndAddReservoirView();
|
2012-05-18 09:45:23 +02:00
|
|
|
|
2013-03-18 14:34:29 +01:00
|
|
|
void removeResult(const QString& resultName);
|
2012-05-18 09:45:23 +02:00
|
|
|
|
2013-03-18 14:34:29 +01:00
|
|
|
virtual QString locationOnDisc() const { return QString(); }
|
2013-04-11 12:06:38 +02:00
|
|
|
virtual QString gridFileName() const { return QString(); }
|
|
|
|
|
|
2013-03-19 12:47:38 +01:00
|
|
|
|
|
|
|
|
RimCaseCollection* parentCaseCollection();
|
2013-04-08 12:16:38 +02:00
|
|
|
RimIdenticalGridCaseGroup* parentGridCaseGroup();
|
|
|
|
|
|
2015-05-15 18:51:49 +02:00
|
|
|
virtual std::vector<RimView*> views();
|
2013-03-18 14:34:29 +01:00
|
|
|
|
|
|
|
|
// Overridden methods from PdmObject
|
|
|
|
|
public:
|
2015-05-16 08:45:50 +02:00
|
|
|
|
2012-05-18 09:45:23 +02:00
|
|
|
protected:
|
2013-03-18 14:34:29 +01:00
|
|
|
virtual void initAfterRead();
|
|
|
|
|
virtual void fieldChangedByUi( const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue );
|
2012-05-18 09:45:23 +02:00
|
|
|
|
2013-03-18 14:34:29 +01:00
|
|
|
// Internal methods
|
|
|
|
|
protected:
|
|
|
|
|
void computeCachedData();
|
2013-03-22 15:43:42 +01:00
|
|
|
void setReservoirData(RigCaseData* eclipseCase);
|
2015-05-15 18:51:49 +02:00
|
|
|
|
2013-02-14 13:16:56 +01:00
|
|
|
|
2013-03-13 11:42:26 +01:00
|
|
|
private:
|
2013-04-11 12:06:38 +02:00
|
|
|
cvf::ref<RigCaseData> m_rigEclipseCase;
|
2013-03-13 11:42:26 +01:00
|
|
|
|
2013-03-18 14:34:29 +01:00
|
|
|
private:
|
2015-07-31 18:58:23 +02:00
|
|
|
caf::PdmChildField<RimReservoirCellResultsStorage*> m_matrixModelResults;
|
|
|
|
|
caf::PdmChildField<RimReservoirCellResultsStorage*> m_fractureModelResults;
|
2012-05-18 09:45:23 +02:00
|
|
|
|
2013-04-11 12:06:38 +02:00
|
|
|
// Obsolete fields
|
|
|
|
|
protected:
|
|
|
|
|
caf::PdmField<QString> caseName;
|
2013-03-18 11:40:39 +01:00
|
|
|
};
|