21 #ifndef OPM_COMPRESSEDPROPERTYACCESS_HPP_HEADER 22 #define OPM_COMPRESSEDPROPERTYACCESS_HPP_HEADER 37 #include <opm/parser/eclipse/EclipseState/Grid/GridProperty.hpp> 50 namespace GridPropertyAccess {
60 namespace EclPropImpl {
102 template <
class PropertyContainer>
104 p(PropertyContainer& ecl,
105 const std::string& kw);
108 template <
class PropertyContainer>
111 const std::string& kw)
113 return ecl.get3DProperties().hasDeckIntGridProperty(kw);
137 template <
class PropertyContainer>
139 p(PropertyContainer& ecl,
140 const std::string& kw);
143 template <
class PropertyContainer>
146 const std::string& kw)
148 return ecl.get3DProperties().hasDeckDoubleGridProperty(kw);
171 template <
class PropertyContainer>
172 static const GridProperty<int>*
173 value(PropertyContainer& ecl,
174 const std::string& kw);
177 template <
class PropertyContainer>
178 const GridProperty<int>*
180 const std::string& kw)
184 return &ecl.get3DProperties().getIntGridProperty(kw);
207 template <
class PropertyContainer>
208 static const GridProperty<double>*
209 value(PropertyContainer& ecl,
210 const std::string& kw);
213 template <
class PropertyContainer>
214 const GridProperty<double>*
216 const std::string& kw)
220 return &ecl.get3DProperties().getDoubleGridProperty(kw);
232 template <
typename T>
247 template <
class PropertyContainer>
248 static const GridProperty<T>*
249 value(PropertyContainer& ecl,
250 const std::string& kw);
253 template <
typename T>
254 template <
class PropertyContainer>
255 const GridProperty<T>*
257 const std::string& kw)
270 namespace ArrayPolicy {
282 template <
typename T>
304 template <
class PropertyContainer>
306 const std::string& kw,
308 : x_ (Details::EclipsePropertyArray<T>::value(ecl, kw))
349 const GridProperty<T>* x_ =
nullptr;
365 template <
typename T>
400 static_cast<void>(i);
447 template <
class DataArray,
class PropertyTag = Tag::Any>
483 return x_[ (gc_ == 0) ? c : gc_[c] ];
Tag that restricts usage to NTG (net-to-gross) contexts.
Definition: CompressedPropertyAccess.hpp:427
Data array policy that returns a single, constant user specified value for every global cell...
Definition: CompressedPropertyAccess.hpp:366
Compressed(const DataArray &x, const int *gc)
Constructor.
Definition: CompressedPropertyAccess.hpp:462
Provide compressed (active cell) read-only access to globally defined data array. ...
Definition: CompressedPropertyAccess.hpp:448
static const GridProperty< T > * value(PropertyContainer &ecl, const std::string &kw)
Retrieve property values if present in container.
Definition: CompressedPropertyAccess.hpp:256
Definition: AnisotropicEikonal.cpp:446
DataArray::value_type value_type
Property value type.
Definition: CompressedPropertyAccess.hpp:471
Constant(const T c)
Constructor.
Definition: CompressedPropertyAccess.hpp:374
Property value retrieval.
Definition: CompressedPropertyAccess.hpp:79
T value_type
Publicly accessible data array element type.
Definition: CompressedPropertyAccess.hpp:381
std::size_t size_type
Index type for accessing data array.
Definition: CompressedPropertyAccess.hpp:386
Conditional retrieval of property values from an ECLIPSE input deck.
Definition: CompressedPropertyAccess.hpp:233
value_type operator[](const size_type i) const
Read-only data array access.
Definition: CompressedPropertyAccess.hpp:398
Property existence predicate.
Definition: CompressedPropertyAccess.hpp:69
Default tag that implies no restriction.
Definition: CompressedPropertyAccess.hpp:421
value_type operator[](const int c) const
Read-only data array access.
Definition: CompressedPropertyAccess.hpp:481