- Timestamp:
- Jan 19, 2008, 12:09:01 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/IPs/systemC/processor/Morpheo/Behavioural/src/Statistics_generate_file.cpp
r43 r71 12 12 #include <sstream> 13 13 #include <fstream> 14 using namespace std;15 14 16 15 namespace morpheo { … … 19 18 #undef FUNCTION 20 19 #define FUNCTION "Statistics::generate_file" 21 void Statistics::generate_file(st ring stat)20 void Statistics::generate_file(std::string stat) 22 21 { 23 22 log_printf(FUNC,Behavioural,FUNCTION,"Begin"); 24 23 25 ostringstream filename;24 std::stringstream filename; 26 25 filename << _name << ".stat"; 27 26 28 cout << "Generate file \""<< filename.str() << "\"" <<endl;27 std::cout << "Generate file \""<< filename.str() << "\"" << std::endl; 29 28 30 ofstream file;31 file.open(filename.str().c_str(), ios::out |ios::trunc);29 std::ofstream file; 30 file.open(filename.str().c_str(),std::ios::out | std::ios::trunc); 32 31 33 32 time_t current_time; … … 35 34 36 35 // print header 37 file << "<!-- " << endl38 << "\tfile : " << filename.str() << endl36 file << "<!-- " << std::endl 37 << "\tfile : " << filename.str() << std::endl 39 38 << "\tdate : " << ctime (¤t_time ) 40 << "\tcomment : it's a autogenerated file : don't modify" << endl41 << "-->" << endl42 << endl;39 << "\tcomment : it's a autogenerated file : don't modify" << std::endl 40 << "-->" << std::endl 41 << std::endl; 43 42 44 43 file << stat;
Note: See TracChangeset
for help on using the changeset viewer.