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->hasIntGridProperty(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->hasDoubleGridProperty(kw);
171 template <
class PropertyContainer>
172 static std::shared_ptr< GridProperty<int> >
173 value(PropertyContainer& ecl,
174 const std::string& kw);
177 template <
class PropertyContainer>
178 std::shared_ptr< GridProperty<int> >
180 const std::string& kw)
184 return ecl->getIntGridProperty(kw);
207 template <
class PropertyContainer>
208 static std::shared_ptr< GridProperty<double> >
209 value(PropertyContainer& ecl,
210 const std::string& kw);
213 template <
class PropertyContainer>
214 std::shared_ptr< GridProperty<double> >
216 const std::string& kw)
220 return ecl->getDoubleGridProperty(kw);
232 template <
typename T>
247 template <
class PropertyContainer>
248 static std::shared_ptr< GridProperty<T> >
249 value(PropertyContainer& ecl,
250 const std::string& kw);
253 template <
typename T>
254 template <
class PropertyContainer>
255 std::shared_ptr< GridProperty<T> >
257 const std::string& kw)
259 std::shared_ptr< GridProperty<T> > x;
273 namespace ArrayPolicy {
285 template <
typename T>
307 template <
class PropertyContainer>
309 const std::string& kw,
311 : x_ (Details::EclipsePropertyArray<T>::value(ecl, kw))
352 std::shared_ptr< GridProperty<T> > x_;
368 template <
typename T>
403 static_cast<void>(i);
450 template <
class DataArray,
class PropertyTag = Tag::Any>
486 return x_[ (gc_ == 0) ? c : gc_[c] ];
Definition: AnisotropicEikonal.hpp:43
Definition: CompressedPropertyAccess.hpp:451
Constant(const T c)
Definition: CompressedPropertyAccess.hpp:377
DataArray::value_type value_type
Definition: CompressedPropertyAccess.hpp:474
Compressed(const DataArray &x, const int *gc)
Definition: CompressedPropertyAccess.hpp:465
Definition: CompressedPropertyAccess.hpp:430
Definition: CompressedPropertyAccess.hpp:69
static std::shared_ptr< GridProperty< T > > value(PropertyContainer &ecl, const std::string &kw)
Definition: CompressedPropertyAccess.hpp:256
T value_type
Definition: CompressedPropertyAccess.hpp:384
Definition: CompressedPropertyAccess.hpp:233
Definition: CompressedPropertyAccess.hpp:369
std::size_t size_type
Definition: CompressedPropertyAccess.hpp:389
Definition: CompressedPropertyAccess.hpp:424
value_type operator[](const size_type i) const
Definition: CompressedPropertyAccess.hpp:401
value_type operator[](const int c) const
Definition: CompressedPropertyAccess.hpp:484
Definition: CompressedPropertyAccess.hpp:79