Alexandria 2.31.0
SDC-CH common library for the Euclid project
|
Class used by the GridContainer to access the different CellManagers. More...
#include <GridCellManagerTraits.h>
Public Types | |
typedef GridCellManager::data_type | data_type |
The type of the data kept by the GridCellManager. | |
typedef GridCellManager::iterator | iterator |
Static Public Member Functions | |
static std::unique_ptr< GridCellManager > | factory (size_t size) |
static size_t | size (const GridCellManager &cell_manager) |
static iterator | begin (GridCellManager &cell_manager) |
static iterator | end (GridCellManager &cell_manager) |
Static Public Attributes | |
static const bool | enable_boost_serialize = false |
Class used by the GridContainer to access the different CellManagers.
To reduce the requirements of the different GridCellManager which are used by the GridContainer to store the data, the GridContainer class does not directly access the GridCellManager instances, but it uses this trait to redirect all the operations. The default implementation of the trait simply redirects the operations, but, if the API of a manager does not fit the trait, this default behavior can be overridden by declaring a specialization of the trait.
GridCellManager | the manager which keeps the GridContainer data |
Definition at line 50 of file GridCellManagerTraits.h.
typedef GridCellManager::data_type Euclid::GridContainer::GridCellManagerTraits< GridCellManager >::data_type |
The type of the data kept by the GridCellManager.
Definition at line 53 of file GridCellManagerTraits.h.
typedef GridCellManager::iterator Euclid::GridContainer::GridCellManagerTraits< GridCellManager >::iterator |
The iterator type which is used to iterate through the data kept in the cell manager
Definition at line 57 of file GridCellManagerTraits.h.
|
static |
Returns an iterator pointing to the first element managed by the GridCellManager. Defaults on calling the begin() method of the GridCellManager instance.
cell_manager | the cell manager |
|
static |
Returns an iterator pointing right after the last element managed by the GridCellManager. Defaults on calling the end() method of the GridCellManager instance.
cell_manager | the GridCellManager |
|
static |
Factory which creates a GridCellManager instance with the given number of managed data, which all are set to a default value. The default implementation will try to use a constructor with the size as parameter.
size | The number of data the manager will contain |
|
static |
Returns the number of data managed by the given GridCellManager. Defaults on calling the constant version of method size() on the GridCellManager instance.
cell_manager | The GridCellManager to get the size of |
Referenced by Euclid::GridContainer::GridCellManagerTraits< GridCellManagerVectorOfVectors< T > >::factory().
|
static |
Flag which indicates if the GridCellManager is boost serializable. By default it is set to false. Note that Grids which use CellManagers which have this flag set to false cannot be serialized.
Definition at line 101 of file GridCellManagerTraits.h.