mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
typos and minor changes.
This commit is contained in:
parent
61144a73af
commit
0f20e187a6
@ -161,8 +161,9 @@ namespace Opm {
|
|||||||
// read id and compare with object
|
// read id and compare with object
|
||||||
int id = -1;
|
int id = -1;
|
||||||
readValue( in, id );
|
readValue( in, id );
|
||||||
if( id != objectId( state ) )
|
if( id != objectId( state ) ) {
|
||||||
OPM_THROW(std::logic_error,"backup-restore object type missmatch");
|
OPM_THROW(std::logic_error,"backup-restore object type mismatch");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -233,11 +234,11 @@ namespace Opm {
|
|||||||
// check id of stored object
|
// check id of stored object
|
||||||
checkObjectId( in, state );
|
checkObjectId( in, state );
|
||||||
|
|
||||||
// backup simulator state
|
// restore simulator state
|
||||||
SimulatorState& simstate = static_cast< SimulatorState& > (state);
|
SimulatorState& simstate = static_cast< SimulatorState& > (state);
|
||||||
in >> simstate;
|
in >> simstate;
|
||||||
|
|
||||||
// backup additional blackoil state variables
|
// restore additional blackoil state variables
|
||||||
readContainer( in, state.surfacevol() );
|
readContainer( in, state.surfacevol() );
|
||||||
readContainer( in, state.gasoilratio() );
|
readContainer( in, state.gasoilratio() );
|
||||||
readContainer( in, state.rv() );
|
readContainer( in, state.rv() );
|
||||||
|
@ -265,12 +265,9 @@ namespace Opm
|
|||||||
// write resport step number
|
// write resport step number
|
||||||
backupfile_.write( (const char *) &reportStep, sizeof(int) );
|
backupfile_.write( (const char *) &reportStep, sizeof(int) );
|
||||||
|
|
||||||
const BlackoilState* boState = dynamic_cast< const BlackoilState* > (&state);
|
const BlackoilState& boState = dynamic_cast< const BlackoilState& > (state);
|
||||||
if( boState ) {
|
backupfile_ << boState;
|
||||||
backupfile_ << (*boState);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
OPM_THROW(std::logic_error,"cast to BlackoilState failed");
|
|
||||||
const WellStateFullyImplicitBlackoil& boWellState = static_cast< const WellStateFullyImplicitBlackoil& > (wellState);
|
const WellStateFullyImplicitBlackoil& boWellState = static_cast< const WellStateFullyImplicitBlackoil& > (wellState);
|
||||||
backupfile_ << boWellState;
|
backupfile_ << boWellState;
|
||||||
/*
|
/*
|
||||||
|
Loading…
Reference in New Issue
Block a user