8 #ifndef OPENFPM_DATA_SRC_GRID_GRID_KEY_DX_ITERATOR_HILBERT_HPP_ 
    9 #define OPENFPM_DATA_SRC_GRID_GRID_KEY_DX_ITERATOR_HILBERT_HPP_ 
   13 #include "hilbertKey.h" 
   29 template<
unsigned int dim>
 
   33     bool initialized = 
false;
 
   70         for (
size_t i = 0 ; i < dim ; i++)
 
   97         uint64_t nextCoord[dim];
 
  100         getIntCoordFromHKey(nextCoord, 
m, dim, 
hkey, &err);
 
  103         for (
size_t i = 0; i < dim; i++)
 
  104             gk.set_d(i, nextCoord[i]);
 
  119         if ( 
hkey < (
size_t)1 << (
m*dim))
 
  149         for (
size_t i = 0 ; i < dim ; i++)
 
void reset()
Reset the iterator (it restart from the beginning) 
 
grid_key_dx is the key to access any element in the grid 
 
uint64_t hkey
Actual position. 
 
size_t m
Order of a hilbert curve. 
 
grid_sm< dim, void > grid_base
Size of the hilbert grid in each dimension. 
 
grid_key_dx_iterator_hilbert< dim > & operator++()
Get the next element. 
 
grid_key_dx< dim > gk
Actual position in the grid. 
 
grid_key_dx_iterator_hilbert(int32_t m)
Constructor. 
 
bool isNext()
Check if there is the next element. 
 
void setDimensions(const size_t(&dims)[N])
Reset the dimension of the grid.