diff --git a/Src/Particle/AMReX_StructOfArrays.H b/Src/Particle/AMReX_StructOfArrays.H index 201cf340dc..46d18a1715 100644 --- a/Src/Particle/AMReX_StructOfArrays.H +++ b/Src/Particle/AMReX_StructOfArrays.H @@ -52,6 +52,28 @@ struct StructOfArrays { /** Get access to the particle Int Arrays (only compile-time components) */ [[nodiscard]] const std::array< IntVector, NInt>& GetIntData () const { return m_idata; } + /** Get the names for the real SoA components **/ + [[nodiscard]] std::vector GetRealNames () const + { + if (m_rdata_names) { + return *m_rdata_names; + } + else { + return std::vector(); + } + } + + /** Get the names for the int SoA components **/ + [[nodiscard]] std::vector GetIntNames () const + { + if (m_idata_names) { + return *m_idata_names; + } + else { + return std::vector(); + } + } + /** Get access to a particle Real component Array (compile-time and runtime component) * * @param index component with 0...NReal-1 compile-time and NReal... runtime arguments