27 lines
632 B
C++
27 lines
632 B
C++
#ifndef MPI_PARTICLE_WRITER_H
|
|
#define MPI_PARTICLE_WRITER_H
|
|
|
|
#include <string>
|
|
#include <vector>
|
|
|
|
namespace particle {
|
|
class SerializedParticle;
|
|
}
|
|
|
|
class MpiParticleWriter {
|
|
public:
|
|
MpiParticleWriter(std::string directory = "./output",
|
|
std::string filename = "output",
|
|
int fs_blocksize = 4096);
|
|
|
|
void output_particles(std::vector<particle::SerializedParticle>& particles,
|
|
int cpu_sync, double dt);
|
|
|
|
private:
|
|
std::string directory_;
|
|
std::string filename_;
|
|
void createFolder(std::string directory);
|
|
int fs_blocksize_;
|
|
};
|
|
|
|
#endif /* MPI_PARTICLE_WRITER_H */ |