#ifdef STATISTICS /* * $Id$ * * [ Description ] * */ #include "Behavioural/include/Statistics.h" #include #include #include namespace morpheo { namespace behavioural { #undef FUNCTION #define FUNCTION "Statistics::generate_file" void Statistics::generate_file(std::string stat) { log_printf(FUNC,Behavioural,FUNCTION,"Begin"); std::stringstream filename; filename << _name << ".stat"; std::cout << "Generate file \""<< filename.str() << "\"" << std::endl; std::ofstream file; file.open(filename.str().c_str(),std::ios::out | std::ios::trunc); time_t current_time; time (¤t_time); // print header file << "" << std::endl << std::endl; file << stat; file.close(); log_printf(FUNC,Behavioural,FUNCTION,"End"); } #undef FUNCTION #define FUNCTION "Statistics::generate_file" void Statistics::generate_file(void) { log_printf(FUNC,Behavioural,FUNCTION,"Begin"); generate_file(print(0)); log_printf(FUNC,Behavioural,FUNCTION,"End"); }; }; // end namespace behavioural }; // end namespace morpheo #endif