mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
readDeck: make the ErrorGuard an internal detail
This commit is contained in:
parent
9c3d1237bd
commit
240c039f53
@ -28,7 +28,6 @@
|
|||||||
#include <opm/common/utility/TimeService.hpp>
|
#include <opm/common/utility/TimeService.hpp>
|
||||||
#include <opm/input/eclipse/EclipseState/Aquifer/NumericalAquifer/NumericalAquiferCell.hpp>
|
#include <opm/input/eclipse/EclipseState/Aquifer/NumericalAquifer/NumericalAquiferCell.hpp>
|
||||||
#include <opm/input/eclipse/EclipseState/EclipseState.hpp>
|
#include <opm/input/eclipse/EclipseState/EclipseState.hpp>
|
||||||
#include <opm/input/eclipse/Parser/ErrorGuard.hpp>
|
|
||||||
#include <opm/input/eclipse/Parser/InputErrorAction.hpp>
|
#include <opm/input/eclipse/Parser/InputErrorAction.hpp>
|
||||||
#include <opm/input/eclipse/Schedule/Action/State.hpp>
|
#include <opm/input/eclipse/Schedule/Action/State.hpp>
|
||||||
#include <opm/input/eclipse/Schedule/OilVaporizationProperties.hpp>
|
#include <opm/input/eclipse/Schedule/OilVaporizationProperties.hpp>
|
||||||
@ -101,7 +100,7 @@ void EclGenericVanguard::readDeck(const std::string& filename)
|
|||||||
Opm::readDeck(EclGenericVanguard::comm(),
|
Opm::readDeck(EclGenericVanguard::comm(),
|
||||||
filename, eclipseState, schedule, udqState,
|
filename, eclipseState, schedule, udqState,
|
||||||
actionState, wtestState,
|
actionState, wtestState,
|
||||||
summaryConfig, nullptr, nullptr, false,
|
summaryConfig, nullptr, false,
|
||||||
false, false, {});
|
false, false, {});
|
||||||
|
|
||||||
EclGenericVanguard::setParams(setupTimer.elapsed(),
|
EclGenericVanguard::setParams(setupTimer.elapsed(),
|
||||||
|
@ -53,7 +53,6 @@ namespace Opm {
|
|||||||
namespace Action { class State; }
|
namespace Action { class State; }
|
||||||
class Deck;
|
class Deck;
|
||||||
class EclipseState;
|
class EclipseState;
|
||||||
class ErrorGuard;
|
|
||||||
struct NumericalAquiferCell;
|
struct NumericalAquiferCell;
|
||||||
class ParseContext;
|
class ParseContext;
|
||||||
class Schedule;
|
class Schedule;
|
||||||
|
@ -515,7 +515,7 @@ private:
|
|||||||
|
|
||||||
readDeck(EclGenericVanguard::comm(), deckFilename, eclipseState_,
|
readDeck(EclGenericVanguard::comm(), deckFilename, eclipseState_,
|
||||||
schedule_, udqState_, actionState_, wtestState_,
|
schedule_, udqState_, actionState_, wtestState_,
|
||||||
summaryConfig_, nullptr, python, strictParsing,
|
summaryConfig_, python, strictParsing,
|
||||||
init_from_restart_file, outputCout_, outputInterval);
|
init_from_restart_file, outputCout_, outputInterval);
|
||||||
|
|
||||||
verifyValidCellGeometry(EclGenericVanguard::comm(), *this->eclipseState_);
|
verifyValidCellGeometry(EclGenericVanguard::comm(), *this->eclipseState_);
|
||||||
|
@ -487,16 +487,13 @@ void Opm::readDeck(Opm::Parallel::Communication comm,
|
|||||||
std::unique_ptr<Action::State>& actionState,
|
std::unique_ptr<Action::State>& actionState,
|
||||||
std::unique_ptr<WellTestState>& wtestState,
|
std::unique_ptr<WellTestState>& wtestState,
|
||||||
std::shared_ptr<SummaryConfig>& summaryConfig,
|
std::shared_ptr<SummaryConfig>& summaryConfig,
|
||||||
std::unique_ptr<ErrorGuard> errorGuard,
|
|
||||||
std::shared_ptr<Python> python,
|
std::shared_ptr<Python> python,
|
||||||
const bool strictParsing,
|
const bool strictParsing,
|
||||||
const bool initFromRestart,
|
const bool initFromRestart,
|
||||||
const bool checkDeck,
|
const bool checkDeck,
|
||||||
const std::optional<int>& outputInterval)
|
const std::optional<int>& outputInterval)
|
||||||
{
|
{
|
||||||
if (errorGuard == nullptr) {
|
auto errorGuard = std::make_unique<ErrorGuard>();
|
||||||
errorGuard = std::make_unique<ErrorGuard>();
|
|
||||||
}
|
|
||||||
|
|
||||||
int parseSuccess = 1; // > 0 is success
|
int parseSuccess = 1; // > 0 is success
|
||||||
std::string failureMessage;
|
std::string failureMessage;
|
||||||
|
@ -84,7 +84,6 @@ void readDeck(Parallel::Communication comm,
|
|||||||
std::unique_ptr<Action::State>& actionState,
|
std::unique_ptr<Action::State>& actionState,
|
||||||
std::unique_ptr<WellTestState>& wtestState,
|
std::unique_ptr<WellTestState>& wtestState,
|
||||||
std::shared_ptr<SummaryConfig>& summaryConfig,
|
std::shared_ptr<SummaryConfig>& summaryConfig,
|
||||||
std::unique_ptr<ErrorGuard> errorGuard,
|
|
||||||
std::shared_ptr<Python> python,
|
std::shared_ptr<Python> python,
|
||||||
bool strictParsing,
|
bool strictParsing,
|
||||||
bool initFromRestart,
|
bool initFromRestart,
|
||||||
|
Loading…
Reference in New Issue
Block a user