22 #include "LbmLib/include/reportHandler/GeometryReporter.hpp"
23 #include <UtilLib/include/Exception.hpp>
24 #include <LbmLib/include/solver/FluidSolver/FluidSolver.hpp>
25 #include <LbmLib/include/nodes/GeometryNode.hpp>
31 namespace reportHandler {
36 typedef std::map<unsigned int, std::shared_ptr<nodes::GeometryNode> >::const_iterator MapIterator;
38 std::stringstream filename;
39 filename <<
filename_ <<
"_" << time <<
".txt";
40 std::ofstream oStream(filename.str().c_str());
41 if (!oStream.is_open()) {
46 for (MapIterator it = this->GeometryNodes_.begin();
47 it != this->GeometryNodes_.end(); it++)
49 oStream << std::setprecision(12) <<
50 it->second->getId() <<
"\t" <<
51 it->second->getXPos() <<
"\t" <<
52 it->second->getYPos() <<
"\t" <<
53 it->second->getXVelocity() <<
"\t" <<
54 it->second->getYVelocity() <<
"\n";
const std::string filename_
filename_ Stores the filename of this functor
virtual void operator()(unsigned int time) const
operator() writes the report