24 #include <boost/property_tree/xml_parser.hpp>
29 using boost::property_tree::ptree;
35 int SimState::GetTimeStep()
const
40 double SimState::GetTime()
const
50 ptree SimState::GetParameters()
const
55 string SimState::GetProjectName()
const
57 return m_project_name;
60 ptree SimState::GetRandomEngineState()
const
65 void SimState::SetTimeStep(
int step)
70 void SimState::SetTime(
double t)
75 void SimState::SetMeshState(
const MeshState& mesh_state)
77 m_mesh_state = mesh_state;
80 void SimState::SetParameters(
const ptree& parameters)
82 m_parameters = parameters;
85 void SimState::SetProjectName(
string project_name)
87 m_project_name = project_name;
90 void SimState::SetRandomEngineState(
const ptree& re_state)
92 m_re_state = re_state;
95 void SimState::PrintToStream(ostream& out)
const
97 out <<
"SimState at time step: " << this->m_time_step;
98 out <<
", time: " << this->m_time << endl;
100 out <<
"Simulation parameters:" << endl;
101 write_xml(out, m_parameters, XmlWriterSettings::GetTab());
102 out <<
"Random engine state:" << endl;
103 write_xml(out, m_re_state, XmlWriterSettings::GetTab());
void PrintToStream(std::ostream &out) const
Prints a textual representation of this MeshState to output stream.
Namespace for miscellaneous utilities.
Namespace for the core simulator.
Contains the state of the whole Mesh at a given simulation step.
Xml writer settings class.