@@ -201,9 +201,23 @@ void make_ParticleContainer_and_Iterators (py::module &m, std::string allocstr)
201201 .def_property_readonly (" num_runtime_int_comps" , &ParticleContainerType::NumRuntimeIntComps,
202202 " The number of runtime Int components in SoA" )
203203
204+
204205 .def_property_readonly (" num_position_components" , [](const py::object&){ return AMREX_SPACEDIM; })
205206 .def_property_readonly (" byte_spread" , &ParticleContainerType::ByteSpread)
206207
208+ // runtime components
209+ .def (" add_real_comp" , &ParticleContainerType::template AddRealComp<bool >,
210+ py::arg (" communicate" )=true , " add a new runtime component with type Real" )
211+ .def (" add_int_comp" , &ParticleContainerType::template AddIntComp<bool >,
212+ py::arg (" communicate" )=true , " add a new runtime component with type Int" )
213+
214+ .def (" resize_runtime_real_comp" , &ParticleContainerType::ResizeRuntimeRealComp,
215+ py::arg (" new_size" ), py::arg (" communicate" ),
216+ " Resize the Real runtime components (SoA)" )
217+ .def (" resize_runtime_int_comp" , &ParticleContainerType::ResizeRuntimeIntComp,
218+ py::arg (" new_size" ), py::arg (" communicate" ),
219+ " Resize the Int runtime components (SoA)" )
220+
207221 .def_property_readonly (" finest_level" , &ParticleContainerBase::finestLevel)
208222
209223 // ParticleContainer ( const ParticleContainer &) = delete;
0 commit comments