mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Change Deck access methods/types to references
opm-parser#677 changes the return types for the Deck family of classes. This patch fixes all broken code from that patch set. https://github.com/OPM/opm-parser/pull/677
This commit is contained in:
committed by
lycantrophe
parent
6f3c4fb618
commit
04d605159f
@@ -60,16 +60,16 @@ namespace Opm
|
||||
transmult_ = rocktabTable.getColumn("PV_MULT_TRANX").vectorCopy();
|
||||
}
|
||||
} else if (deck->hasKeyword("ROCK")) {
|
||||
Opm::DeckKeywordConstPtr rockKeyword = deck->getKeyword("ROCK");
|
||||
if (rockKeyword->size() != 1) {
|
||||
const auto& rockKeyword = deck->getKeyword("ROCK");
|
||||
if (rockKeyword.size() != 1) {
|
||||
// here it would be better not to use std::cout directly but to add the
|
||||
// warning to some "warning list"...
|
||||
std::cout << "Can only handle a single region in ROCK ("<<rockKeyword->size()<<" regions specified)."
|
||||
std::cout << "Can only handle a single region in ROCK ("<<rockKeyword.size()<<" regions specified)."
|
||||
<< " Ignoring all except for the first.\n";
|
||||
}
|
||||
|
||||
pref_ = rockKeyword->getRecord(0)->getItem("PREF")->getSIDouble(0);
|
||||
rock_comp_ = rockKeyword->getRecord(0)->getItem("COMPRESSIBILITY")->getSIDouble(0);
|
||||
pref_ = rockKeyword.getRecord(0).getItem("PREF").getSIDouble(0);
|
||||
rock_comp_ = rockKeyword.getRecord(0).getItem("COMPRESSIBILITY").getSIDouble(0);
|
||||
} else {
|
||||
std::cout << "**** warning: no rock compressibility data found in deck (ROCK or ROCKTAB)." << std::endl;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user