mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Clarify by using this->
Clarify usage of member variables in FlowMainEbos.hpp by prefixing with this->. Also rebased PR on the current master, and updated flow_ebos_oilwater_brine.cpp according to the PR.
This commit is contained in:
parent
f9d47b7c68
commit
c6752c1e0e
@ -85,8 +85,9 @@ int flowEbosOilWaterBrineMain(int argc, char** argv, bool outputCout, bool outpu
|
|||||||
Dune::MPIHelper::instance(argc, argv);
|
Dune::MPIHelper::instance(argc, argv);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
Opm::FlowMainEbos<TTAG(EclFlowOilWaterBrineProblem)> mainfunc;
|
Opm::FlowMainEbos<TTAG(EclFlowOilWaterBrineProblem)>
|
||||||
return mainfunc.execute(argc, argv, outputCout, outputFiles);
|
mainfunc {argc, argv, outputCout, outputFiles};
|
||||||
|
return mainfunc.execute();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -354,7 +354,7 @@ namespace Opm
|
|||||||
try {
|
try {
|
||||||
// deal with some administrative boilerplate
|
// deal with some administrative boilerplate
|
||||||
|
|
||||||
int status = setupParameters_(argc_, argv_);
|
int status = setupParameters_(this->argc_, this->argv_);
|
||||||
if (status)
|
if (status)
|
||||||
return status;
|
return status;
|
||||||
|
|
||||||
@ -374,7 +374,7 @@ namespace Opm
|
|||||||
std::ostringstream message;
|
std::ostringstream message;
|
||||||
message << "Program threw an exception: " << e.what();
|
message << "Program threw an exception: " << e.what();
|
||||||
|
|
||||||
if (output_cout_) {
|
if (this->output_cout_) {
|
||||||
// in some cases exceptions are thrown before the logging system is set
|
// in some cases exceptions are thrown before the logging system is set
|
||||||
// up.
|
// up.
|
||||||
if (OpmLog::hasBackend("STREAMLOG")) {
|
if (OpmLog::hasBackend("STREAMLOG")) {
|
||||||
@ -425,7 +425,7 @@ namespace Opm
|
|||||||
// force closing of all log files.
|
// force closing of all log files.
|
||||||
OpmLog::removeAllBackends();
|
OpmLog::removeAllBackends();
|
||||||
|
|
||||||
if (mpi_rank_ != 0 || mpi_size_ < 2 || !output_files_) {
|
if (mpi_rank_ != 0 || mpi_size_ < 2 || !this->output_files_) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -504,7 +504,7 @@ namespace Opm
|
|||||||
// OpmLog singleton.
|
// OpmLog singleton.
|
||||||
void runDiagnostics()
|
void runDiagnostics()
|
||||||
{
|
{
|
||||||
if (!output_cout_) {
|
if (!this->output_cout_) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -545,7 +545,7 @@ namespace Opm
|
|||||||
// Output summary after simulation has completed
|
// Output summary after simulation has completed
|
||||||
void runSimulatorAfterSim_(SimulatorReport &report)
|
void runSimulatorAfterSim_(SimulatorReport &report)
|
||||||
{
|
{
|
||||||
if (output_cout_) {
|
if (this->output_cout_) {
|
||||||
std::ostringstream ss;
|
std::ostringstream ss;
|
||||||
ss << "\n\n================ End of simulation ===============\n\n";
|
ss << "\n\n================ End of simulation ===============\n\n";
|
||||||
ss << "Number of MPI processes: " << std::setw(6) << mpi_size_ << "\n";
|
ss << "Number of MPI processes: " << std::setw(6) << mpi_size_ << "\n";
|
||||||
@ -582,7 +582,7 @@ namespace Opm
|
|||||||
const auto& initConfig = eclState().getInitConfig();
|
const auto& initConfig = eclState().getInitConfig();
|
||||||
simtimer_->init(timeMap, (size_t)initConfig.getRestartStep());
|
simtimer_->init(timeMap, (size_t)initConfig.getRestartStep());
|
||||||
|
|
||||||
if (output_cout_) {
|
if (this->output_cout_) {
|
||||||
std::ostringstream oss;
|
std::ostringstream oss;
|
||||||
|
|
||||||
// This allows a user to catch typos and misunderstandings in the
|
// This allows a user to catch typos and misunderstandings in the
|
||||||
@ -595,7 +595,7 @@ namespace Opm
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!ioConfig.initOnly()) {
|
if (!ioConfig.initOnly()) {
|
||||||
if (output_cout_) {
|
if (this->output_cout_) {
|
||||||
std::string msg;
|
std::string msg;
|
||||||
msg = "\n\n================ Starting main simulation loop ===============\n";
|
msg = "\n\n================ Starting main simulation loop ===============\n";
|
||||||
OpmLog::info(msg);
|
OpmLog::info(msg);
|
||||||
@ -604,7 +604,7 @@ namespace Opm
|
|||||||
return (this->*initOrRunFunc)();
|
return (this->*initOrRunFunc)();
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if (output_cout_) {
|
if (this->output_cout_) {
|
||||||
std::cout << "\n\n================ Simulation turned off ===============\n" << std::flush;
|
std::cout << "\n\n================ Simulation turned off ===============\n" << std::flush;
|
||||||
}
|
}
|
||||||
return EXIT_SUCCESS;
|
return EXIT_SUCCESS;
|
||||||
|
Loading…
Reference in New Issue
Block a user