Update to shared_ptr-less parser interface.

This commit is contained in:
Jørgen Kvalsvik
2016-10-13 16:03:35 +02:00
parent 518c9849ff
commit 1057e6d3d0
58 changed files with 442 additions and 455 deletions

View File

@@ -31,14 +31,14 @@
namespace Opm
{
IncompPropertiesSinglePhase::IncompPropertiesSinglePhase(Opm::DeckConstPtr deck,
Opm::EclipseStateConstPtr eclState,
IncompPropertiesSinglePhase::IncompPropertiesSinglePhase(const Opm::Deck& deck,
const Opm::EclipseState& eclState,
const UnstructuredGrid& grid)
{
rock_.init(eclState, grid.number_of_cells, grid.global_cell, grid.cartdims);
if (deck->hasKeyword("DENSITY")) {
const auto& densityRecord = deck->getKeyword("DENSITY").getRecord(0);
if (deck.hasKeyword("DENSITY")) {
const auto& densityRecord = deck.getKeyword("DENSITY").getRecord(0);
surface_density_ = densityRecord.getItem("OIL").getSIDouble(0);
} else {
surface_density_ = 1000.0;
@@ -49,8 +49,8 @@ namespace Opm
// This will be modified if we have a PVCDO specification.
reservoir_density_ = surface_density_;
if (deck->hasKeyword("PVCDO")) {
const auto& pvcdoRecord = deck->getKeyword("PVCDO").getRecord(0);
if (deck.hasKeyword("PVCDO")) {
const auto& pvcdoRecord = deck.getKeyword("PVCDO").getRecord(0);
if (pvcdoRecord.getItem("OIL_COMPRESSIBILITY").getSIDouble(0) != 0.0 ||
pvcdoRecord.getItem("OIL_VISCOSIBILITY").getSIDouble(0) != 0.0) {
OPM_MESSAGE("Compressibility effects in PVCDO are ignored.");