From 8f0d81db2f015ba30054de70f0d1dac6b8eed724 Mon Sep 17 00:00:00 2001 From: Andreas Lauser Date: Mon, 15 Feb 2016 14:59:52 +0100 Subject: [PATCH] fix the build it broke because EclipseState::get*GridProperty() now returns a pointer to a constant object. --- opm/core/utility/CompressedPropertyAccess.hpp | 12 ++++++------ opm/core/utility/thresholdPressures.hpp | 6 +++--- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/opm/core/utility/CompressedPropertyAccess.hpp b/opm/core/utility/CompressedPropertyAccess.hpp index 6fd5601a..4ef19451 100644 --- a/opm/core/utility/CompressedPropertyAccess.hpp +++ b/opm/core/utility/CompressedPropertyAccess.hpp @@ -205,13 +205,13 @@ namespace Opm { * \return Data values for property \c kw. */ template - static std::shared_ptr< GridProperty > + static std::shared_ptr > value(PropertyContainer& ecl, const std::string& kw); }; template - std::shared_ptr< GridProperty > + std::shared_ptr > GetProperty::value(PropertyContainer& ecl, const std::string& kw) { @@ -245,18 +245,18 @@ namespace Opm { * an empty \code shared_ptr<> \endcode if not. */ template - static std::shared_ptr< GridProperty > + static std::shared_ptr > value(PropertyContainer& ecl, const std::string& kw); }; template template - std::shared_ptr< GridProperty > + std::shared_ptr > EclipsePropertyArray::value(PropertyContainer& ecl, const std::string& kw) { - std::shared_ptr< GridProperty > x; + std::shared_ptr > x; if (EclPropImpl::HasProperty::p(ecl, kw)) { x = EclPropImpl::GetProperty::value(ecl, kw); @@ -349,7 +349,7 @@ namespace Opm { * * Null if data not defined. */ - std::shared_ptr< GridProperty > x_; + std::shared_ptr > x_; /** * Fall-back data element value if data not defined. diff --git a/opm/core/utility/thresholdPressures.hpp b/opm/core/utility/thresholdPressures.hpp index 8d60cf25..6b96dd8b 100644 --- a/opm/core/utility/thresholdPressures.hpp +++ b/opm/core/utility/thresholdPressures.hpp @@ -55,7 +55,7 @@ void computeMaxDp(std::map, double>& maxDp, const PhaseUsage& pu = props.phaseUsage(); - std::shared_ptr> eqlnum = eclipseState->getIntGridProperty("EQLNUM"); + std::shared_ptr> eqlnum = eclipseState->getIntGridProperty("EQLNUM"); const auto& eqlnumData = eqlnum->getData(); const int numPhases = initialState.numPhases(); @@ -324,7 +324,7 @@ void computeMaxDp(std::map, double>& maxDp, std::vector thpres_vals; if (simulationConfig->hasThresholdPressure()) { std::shared_ptr thresholdPressure = simulationConfig->getThresholdPressure(); - std::shared_ptr> eqlnum = eclipseState->getIntGridProperty("EQLNUM"); + std::shared_ptr> eqlnum = eclipseState->getIntGridProperty("EQLNUM"); const auto& eqlnumData = eqlnum->getData(); // Set threshold pressure values for each cell face. @@ -382,7 +382,7 @@ void computeMaxDp(std::map, double>& maxDp, std::vector thpres_vals; if (simulationConfig->hasThresholdPressure()) { std::shared_ptr thresholdPressure = simulationConfig->getThresholdPressure(); - std::shared_ptr> eqlnum = eclipseState->getIntGridProperty("EQLNUM"); + std::shared_ptr> eqlnum = eclipseState->getIntGridProperty("EQLNUM"); auto eqlnumData = eqlnum->getData(); // Set values for each NNC