SoAStorage is a helper to access the stored SoA's.
More...
#include <SoAStorage.h>
|
| template<typename FunctorT > |
| void | apply (FunctorT func) |
| | Apply the specific function to all vectors.
|
| |
| template<size_t soaAttribute> |
| constexpr auto & | get () |
| | Get the vector at the specific entry of the storage.
|
| |
| template<size_t soaAttribute> |
| constexpr const auto & | get () const |
| | Get the vector at the specific entry of the storage.
|
| |
| constexpr const auto & | getTuple () const |
| | Getter for the internal tuple.
|
| |
template<class SoAArraysType>
class autopas::utils::SoAStorage< SoAArraysType >
SoAStorage is a helper to access the stored SoA's.
- Template Parameters
-
| SoAArraysType | the type of the storage arrays. should be a tuple of aligned vectors |
◆ apply()
template<class SoAArraysType >
template<typename FunctorT >
Apply the specific function to all vectors.
This can e.g. be resize operations, ... The functor func should not require input parameters. The returns of the functor are ignored.
- Template Parameters
-
| FunctorT | the type of the functor |
- Parameters
-
| func | a functor, that should be applied on all vectors (e.g. lambda functions, should take auto& list as an argument) |
- Todo:
- c++20: replace with expansion statement:
for... (auto& elem : tup) {}
◆ get() [1/2]
template<class SoAArraysType >
template<size_t soaAttribute>
Get the vector at the specific entry of the storage.
- Template Parameters
-
| soaAttribute | the attribute for which the vector should be returned |
- Returns
- a reference to the vector for the specific attribute
◆ get() [2/2]
template<class SoAArraysType >
template<size_t soaAttribute>
Get the vector at the specific entry of the storage.
- Template Parameters
-
| soaAttribute | the attribute for which the vector should be returned |
- Returns
- a reference to the vector for the specific attribute
- Note
- const variant
◆ getTuple()
template<class SoAArraysType >
Getter for the internal tuple.
- Returns
The documentation for this class was generated from the following file: