Move enum Well:InjectorType to new file ScheduleTypes

This commit is contained in:
Joakim Hove
2020-02-27 14:29:01 +01:00
parent e3a9174aa3
commit 1b2fadcdc4
15 changed files with 153 additions and 89 deletions

View File

@@ -0,0 +1,38 @@
/*
Copyright 2020 Equinor ASA.
This file is part of the Open Porous Media project (OPM).
OPM 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.
OPM 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 for more details.
You should have received a copy of the GNU General Public License
along with OPM. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef OPM_SCHEDULE_TYPES_HPP
#define OPM_SCHEDULE_TYPES_HPP
namespace Opm {
enum class InjectorType {
WATER = 1,
GAS = 2,
OIL = 3,
MULTI = 4
};
const std::string InjectorType2String( InjectorType enumValue );
InjectorType InjectorTypeFromString( const std::string& stringValue );
}
#endif

View File

@@ -27,6 +27,7 @@
#include <opm/parser/eclipse/EclipseState/Schedule/SummaryState.hpp>
#include <opm/parser/eclipse/EclipseState/Schedule/Well/WellConnections.hpp>
#include <opm/parser/eclipse/EclipseState/Schedule/MSW/WellSegments.hpp>
#include <opm/parser/eclipse/EclipseState/Schedule/ScheduleTypes.hpp>
#include <opm/parser/eclipse/EclipseState/Schedule/Well/ProductionControls.hpp>
#include <opm/parser/eclipse/EclipseState/Schedule/Well/InjectionControls.hpp>
#include <opm/parser/eclipse/EclipseState/Schedule/Well/WellFoamProperties.hpp>
@@ -62,14 +63,6 @@ public:
static Status StatusFromString(const std::string& stringValue);
enum class InjectorType {
WATER = 1,
GAS = 2,
OIL = 3,
MULTI = 4
};
static const std::string InjectorType2String( InjectorType enumValue );
static InjectorType InjectorTypeFromString( const std::string& stringValue );
/*
@@ -211,7 +204,7 @@ public:
int VFPTableNumber;
bool predictionMode;
int injectionControls;
Well::InjectorType injectorType;
InjectorType injectorType;
InjectorCMode controlMode;
bool operator==(const WellInjectionProperties& other) const;
@@ -232,7 +225,7 @@ public:
int vfpTableNum,
bool predMode,
int injControls,
Well::InjectorType injType,
InjectorType injType,
InjectorCMode ctrlMode);
void handleWELTARG(WELTARGCMode cmode, double newValue, double SIFactorP);