Opm::GridPropertyAccess::Compressed< DataArray, PropertyTag > Class Template Reference

#include <CompressedPropertyAccess.hpp>

Public Types

typedef DataArray::value_type value_type
 

Public Member Functions

 Compressed (const DataArray &x, const int *gc)
 
value_type operator[] (const int c) const
 

Detailed Description

template<class DataArray, class PropertyTag = Tag::Any>
class Opm::GridPropertyAccess::Compressed< DataArray, PropertyTag >

Provide compressed (active cell) read-only access to globally defined data array.

Template Parameters
DataArrayType representing an array of data values, one value for each global (uncompressed) cell in a model. Must implement value semantics. Typically one of the array policies of name space ArrayPolicy. Must provide public type value_type to infer the data element type and to access the property value of the i'th global cell.
PropertyTagType tag that can be used to restrict applicability of the resulting Compressed array, e.g., to enforce net-to-gross ratios only. Default: No restriction.

Member Typedef Documentation

template<class DataArray , class PropertyTag = Tag::Any>
typedef DataArray::value_type Opm::GridPropertyAccess::Compressed< DataArray, PropertyTag >::value_type

Property value type.

Constructor & Destructor Documentation

template<class DataArray , class PropertyTag = Tag::Any>
Opm::GridPropertyAccess::Compressed< DataArray, PropertyTag >::Compressed ( const DataArray &  x,
const int *  gc 
)
inline

Constructor

Parameters
[in]xPreconfigured global property value array. The Compressed array creates a private copy of this object.
[in]gcCompressed-to-global cell map. Typically the global_cell field of an UnstructuredGrid or something very similar. If null, interpreted as identity mapping, i.e., as if all cells are active.

Member Function Documentation

template<class DataArray , class PropertyTag = Tag::Any>
value_type Opm::GridPropertyAccess::Compressed< DataArray, PropertyTag >::operator[] ( const int  c) const
inline

Read-only data array access.

Parameters
[in]cActive cell index.
Returns
Property value in active cell c.

The documentation for this class was generated from the following file: