Private Types | List of all members
util::GridContainerBase1D< DATUM, IXMAN > Class Template Reference

Base class for a container of data arranged on a 1D-grid. More...

#include <GridContainers.h>

Inheritance diagram for util::GridContainerBase1D< DATUM, IXMAN >:
util::details::GridContainerBase< DATUM, IXMAN > util::GridContainerBase2D< DATUM, IXMAN > util::GridContainerBase3D< DATUM, IXMAN >

Public Member Functions

Data structure
bool hasX (typename Base_t::CellDimIndex_t index) const
 Returns whether the specified x index is valid. More...
 
size_t sizeX () const
 Returns the size of the container in the first dimension (x) More...
 
- Public Member Functions inherited from util::details::GridContainerBase< DATUM, IXMAN >
 GridContainerBase (std::array< size_t, dims()> const &dims)
 Constructor: specifies the size of the container and allocates it. More...
 
Indexer_t const & indexManager () const
 Returns the index manager of the grid. More...
 
size_t size () const
 Returns the total size of the container. More...
 
bool has (CellIndexOffset_t index) const
 Returns whether the specified index is valid. More...
 
CellIndex_t index (CellID_t const &id) const
 Return the index of the element from its cell coordinates (no check!) More...
 
CellIndexOffset_t indexOffset (CellID_t const &origin, CellID_t const &cellID) const
 Returns the difference in index from two cells. More...
 
Cell_toperator[] (CellID_t const &id)
 Returns a reference to the specified cell. More...
 
Cell_t const & operator[] (CellID_t const &id) const
 Returns a constant reference to the specified cell. More...
 
Cell_toperator[] (CellIndex_t index)
 Returns a reference to to the cell with specified index. More...
 
Cell_t const & operator[] (CellIndex_t index) const
 Returns a constant reference to the cell with specified index. More...
 
void insert (CellID_t const &cellID, Datum_t const &elem)
 Copies an element into the specified cell. More...
 
void insert (CellID_t const &cellID, Datum_t &&elem)
 Moves an element into the specified cell. More...
 
void insert (CellIndex_t index, Datum_t const &elem)
 Copies an element into the cell with the specified index. More...
 
void insert (CellIndex_t index, Datum_t &&elem)
 Moves an element into the cell with the specified index. More...
 

Private Types

using Base_t = details::GridContainerBase< DATUM, IXMAN >
 

Additional Inherited Members

- Public Types inherited from util::details::GridContainerBase< DATUM, IXMAN >
using Datum_t = DATUM
 type of contained datum More...
 
using Indexer_t = IXMAN
 
using Grid_t = GridContainerBase< Datum_t, Indexer_t >
 this type More...
 
using CellIndex_t = typename Indexer_t::CellIndex_t
 type of index for direct access to the cell More...
 
using CellIndexOffset_t = typename Indexer_t::CellIndexOffset_t
 type of difference between indices More...
 
using CellDimIndex_t = typename Indexer_t::CellDimIndex_t
 type of difference between indices More...
 
using CellID_t = typename Indexer_t::CellID_t
 type of cell coordinate (x, y, z) More...
 
using Cell_t = std::vector< Datum_t >
 type of a single cell container More...
 
using Cells_t = std::vector< Cell_t >
 type of container holding all cells More...
 
using const_iterator = typename Cells_t::const_iterator
 type of iterator to all cells More...
 
- Static Public Member Functions inherited from util::details::GridContainerBase< DATUM, IXMAN >
static constexpr unsigned int dims ()
 
- Protected Member Functions inherited from util::details::GridContainerBase< DATUM, IXMAN >
Cell_tcell (CellID_t const &cellID)
 Returns a reference to the specified cell. More...
 
Cell_t const & cell (CellID_t const &cellID) const
 Returns a constant reference to the specified cell. More...
 
- Protected Attributes inherited from util::details::GridContainerBase< DATUM, IXMAN >
Indexer_t indices
 manager of the indices of the container More...
 
Cells_t data
 organised collection of points More...
 

Detailed Description

template<typename DATUM, typename IXMAN>
class util::GridContainerBase1D< DATUM, IXMAN >

Base class for a container of data arranged on a 1D-grid.

Template Parameters
DATUMtype of datum to be contained
IXMANtype of the grid index manager

Definition at line 167 of file GridContainers.h.

Member Typedef Documentation

template<typename DATUM, typename IXMAN>
using util::GridContainerBase1D< DATUM, IXMAN >::Base_t = details::GridContainerBase<DATUM, IXMAN>
private

Definition at line 168 of file GridContainers.h.

Member Function Documentation

template<typename DATUM, typename IXMAN>
bool util::GridContainerBase1D< DATUM, IXMAN >::hasX ( typename Base_t::CellDimIndex_t  index) const
inline

Returns whether the specified x index is valid.

Definition at line 180 of file GridContainers.h.

181  { return Base_t::indices.hasX(index); }
Indexer_t indices
manager of the indices of the container
CellIndex_t index(CellID_t const &id) const
Return the index of the element from its cell coordinates (no check!)
template<typename DATUM, typename IXMAN>
size_t util::GridContainerBase1D< DATUM, IXMAN >::sizeX ( ) const
inline

Returns the size of the container in the first dimension (x)

Definition at line 184 of file GridContainers.h.

184 { return Base_t::indices.sizeX(); }
Indexer_t indices
manager of the indices of the container

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