Log well control switching message.

Instead of writing to std::cout.
This commit is contained in:
Atgeirr Flø Rasmussen 2016-05-30 10:26:20 +02:00
parent 8a76adb658
commit cf5dbf292a

View File

@ -722,9 +722,11 @@ namespace Opm
// Constraint number ctrl_index was broken, switch to it.
if (terminal_output)
{
std::cout << "Switching control mode for well " << wells().name[w]
<< " from " << modestring[well_controls_iget_type(wc, current)]
<< " to " << modestring[well_controls_iget_type(wc, ctrl_index)] << std::endl;
std::ostringstream ss;
ss << "Switching control mode for well " << wells().name[w]
<< " from " << modestring[well_controls_iget_type(wc, current)]
<< " to " << modestring[well_controls_iget_type(wc, ctrl_index)] << std::endl;
OpmLog::info(ss.str());
}
xw.currentControls()[w] = ctrl_index;
current = xw.currentControls()[w];