|
SpECTRE
v2025.08.19
|
The array index used for indexing Chare Arrays, mostly an implementation detail. More...
#include <ArrayIndex.hpp>
Public Member Functions | |
| ArrayIndex (const Index &array_index) | |
| ArrayIndex (const CkArrayIndex &array_index) | |
| ArrayIndex (const ArrayIndex &rhs)=delete | |
| ArrayIndex & | operator= (const ArrayIndex &rhs)=delete |
| ArrayIndex (ArrayIndex &&)=delete | |
| ArrayIndex & | operator= (ArrayIndex &&)=delete |
| const Index & | get_index () const |
The array index used for indexing Chare Arrays, mostly an implementation detail.
The implementation is generic and can handle custom array indices. This replaces the generated, hard-coded Charm++ array indices with a template, allowing a single implementation to be used for different array indices.
Charm++ allocates memory for CkArrayIndex. The size can be configured (in the Charm++ configuration) and defaults to the size of three integers. We place the Index into this buffer using placement new. Then, CkArrayIndex::data() can be safely reinterpreted as an Index*.