aboutsummaryrefslogtreecommitdiff
path: root/Source/Particles/ParticleBoundaryBuffer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Particles/ParticleBoundaryBuffer.cpp')
-rw-r--r--Source/Particles/ParticleBoundaryBuffer.cpp21
1 files changed, 13 insertions, 8 deletions
diff --git a/Source/Particles/ParticleBoundaryBuffer.cpp b/Source/Particles/ParticleBoundaryBuffer.cpp
index 2f105de55..6837aef31 100644
--- a/Source/Particles/ParticleBoundaryBuffer.cpp
+++ b/Source/Particles/ParticleBoundaryBuffer.cpp
@@ -10,6 +10,7 @@
#include "Particles/ParticleBoundaryBuffer.H"
#include "Particles/MultiParticleContainer.H"
#include "Particles/Gather/ScalarFieldGather.H"
+#include "Utils/TextMsg.H"
#include <AMReX_Geometry.H>
#include <AMReX_ParmParse.H>
@@ -100,9 +101,11 @@ void ParticleBoundaryBuffer::printNumParticles () const {
for (int i = 0; i < numSpecies(); ++i)
{
int np = buffer[i].isDefined() ? buffer[i].TotalNumberOfParticles(false) : 0;
- amrex::Print() << "Species " << getSpeciesNames()[i] << " has "
- << np << " particles in the boundary buffer "
- << "for side " << iside << " of dim " << idim << "\n";
+ amrex::Print() << Utils::TextMsg::Info(
+ "Species " + getSpeciesNames()[i] + " has "
+ + std::to_string(np) + " particles in the boundary buffer "
+ + "for side " + std::to_string(iside) + " of dim " + std::to_string(idim)
+ );
}
}
}
@@ -111,8 +114,10 @@ void ParticleBoundaryBuffer::printNumParticles () const {
for (int i = 0; i < numSpecies(); ++i)
{
int np = buffer[i].isDefined() ? buffer[i].TotalNumberOfParticles(false) : 0;
- amrex::Print() << "Species " << getSpeciesNames()[i] << " has "
- << np << " particles in the EB boundary buffer \n";
+ amrex::Print() << Utils::TextMsg::Info(
+ "Species " + getSpeciesNames()[i] + " has "
+ + std::to_string(np) + " particles in the EB boundary buffer"
+ );
}
#endif
}
@@ -269,10 +274,10 @@ ParticleBoundaryBuffer::getParticleBuffer(const std::string species_name, int bo
auto& buffer = m_particle_containers[boundary];
auto index = WarpX::GetInstance().GetPartContainer().getSpeciesID(species_name);
- AMREX_ALWAYS_ASSERT_WITH_MESSAGE(m_do_boundary_buffer[boundary][index],
+ WARPX_ALWAYS_ASSERT_WITH_MESSAGE(m_do_boundary_buffer[boundary][index],
"Attempted to get particle buffer for boundary "
- + boundary + ", which is not used!");
- AMREX_ALWAYS_ASSERT_WITH_MESSAGE(buffer[index].isDefined(),
+ + std::to_string(boundary) + ", which is not used!");
+ WARPX_ALWAYS_ASSERT_WITH_MESSAGE(buffer[index].isDefined(),
"Tried to get a buffer that is not defined!");
return buffer[index];