2012-06-26 16:10:41 +02:00
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
//
|
|
|
|
|
// Copyright (C) 2011-2012 Statoil ASA, Ceetron AS
|
|
|
|
|
//
|
|
|
|
|
// 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
|
|
|
|
|
|
2015-07-31 18:58:23 +02:00
|
|
|
#include "RimEclipseCase.h"
|
|
|
|
|
|
|
|
|
|
#include "cafPdmChildField.h"
|
2012-06-26 16:10:41 +02:00
|
|
|
#include "cafPdmField.h"
|
|
|
|
|
#include "cafPdmObject.h"
|
2017-06-28 20:10:06 +02:00
|
|
|
#include "cafPdmProxyValueField.h"
|
2012-06-26 16:10:41 +02:00
|
|
|
|
2015-07-31 18:58:23 +02:00
|
|
|
#include "cvfBase.h"
|
|
|
|
|
#include "cvfObject.h"
|
2012-06-26 16:10:41 +02:00
|
|
|
|
|
|
|
|
class RifReaderInterface;
|
2015-06-25 11:51:59 +02:00
|
|
|
class RimEclipseInputProperty;
|
2015-07-31 18:58:23 +02:00
|
|
|
class RimEclipseInputPropertyCollection;
|
2012-06-26 16:10:41 +02:00
|
|
|
|
|
|
|
|
//==================================================================================================
|
|
|
|
|
//
|
|
|
|
|
//
|
|
|
|
|
//
|
|
|
|
|
//==================================================================================================
|
2015-06-25 11:50:13 +02:00
|
|
|
class RimEclipseInputCase : public RimEclipseCase
|
2012-06-26 16:10:41 +02:00
|
|
|
{
|
|
|
|
|
CAF_PDM_HEADER_INIT;
|
|
|
|
|
|
|
|
|
|
public:
|
2015-06-25 11:50:13 +02:00
|
|
|
RimEclipseInputCase();
|
2018-10-18 19:45:57 +02:00
|
|
|
~RimEclipseInputCase() override;
|
2012-06-26 16:10:41 +02:00
|
|
|
|
|
|
|
|
// File open methods
|
2017-10-19 11:37:17 +02:00
|
|
|
bool openDataFileSet(const QStringList& fileNames);
|
2013-04-08 09:57:40 +02:00
|
|
|
void loadAndSyncronizeInputProperties();
|
2012-06-26 16:10:41 +02:00
|
|
|
|
2018-10-10 09:35:01 +02:00
|
|
|
RimEclipseInputPropertyCollection* inputPropertyCollection();
|
|
|
|
|
|
2013-03-22 16:40:41 +01:00
|
|
|
// RimCase overrides
|
2018-10-10 09:35:01 +02:00
|
|
|
bool openEclipseGridFile() override;
|
|
|
|
|
void reloadEclipseGridFile() override;
|
2012-06-26 16:10:41 +02:00
|
|
|
|
2013-04-08 12:01:40 +02:00
|
|
|
// Overrides from RimCase
|
2018-10-10 09:35:01 +02:00
|
|
|
QString locationOnDisc() const override;
|
|
|
|
|
QString gridFileName() const override { return m_gridFileName();}
|
2013-04-11 12:06:38 +02:00
|
|
|
|
2018-10-10 09:35:01 +02:00
|
|
|
void updateFilePathsFromProjectPath(const QString& projectPath, const QString& oldProjectPath) override;
|
2012-06-26 16:10:41 +02:00
|
|
|
|
2017-06-28 20:10:06 +02:00
|
|
|
void updateAdditionalFileFolder(const QString& newFolder);
|
|
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
std::vector<QString> additionalFiles() const;
|
|
|
|
|
|
2017-04-06 18:37:43 +02:00
|
|
|
protected:
|
2018-10-18 19:45:57 +02:00
|
|
|
void defineUiOrdering(QString uiConfigName, caf::PdmUiOrdering& uiOrdering) override;
|
|
|
|
|
void defineUiTreeOrdering(caf::PdmUiTreeOrdering& uiTreeOrdering, QString uiConfigName = "") override;
|
2017-04-06 18:37:43 +02:00
|
|
|
|
2012-06-26 16:10:41 +02:00
|
|
|
private:
|
2013-04-08 09:57:40 +02:00
|
|
|
cvf::ref<RifReaderInterface> createMockModel(QString modelName);
|
2013-04-11 12:06:38 +02:00
|
|
|
|
2018-10-10 09:35:01 +02:00
|
|
|
private:
|
2013-04-11 12:06:38 +02:00
|
|
|
// Fields
|
2018-10-10 09:35:01 +02:00
|
|
|
caf::PdmChildField<RimEclipseInputPropertyCollection*> m_inputPropertyCollection;
|
2017-06-28 20:10:06 +02:00
|
|
|
caf::PdmField<QString> m_gridFileName;
|
|
|
|
|
caf::PdmProxyValueField< std::vector<QString> > m_additionalFiles;
|
2013-04-11 12:06:38 +02:00
|
|
|
|
2017-06-28 20:10:06 +02:00
|
|
|
// Obsolete fields
|
|
|
|
|
caf::PdmField<std::vector<QString> > m_additionalFilenames_OBSOLETE;
|
2012-06-26 16:10:41 +02:00
|
|
|
};
|