source: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Counter/src/Statistics_print.cpp @ 2

Last change on this file since 2 was 2, checked in by kane, 17 years ago

Import Morpheo

File size: 938 bytes
Line 
1#ifdef STATISTICS
2/*
3 * $Id$
4 *
5 * [ Description ]
6 *
7 */
8
9#include "Behavioural/Generic/Counter/include/Statistics.h"
10
11#include <sstream>
12using namespace std;
13
14namespace morpheo {
15namespace behavioural {
16namespace generic {
17namespace counter {
18
19
20  string Statistics::print (uint32_t depth)
21  {
22    log_printf(FUNC,Counter,"print","Begin");
23
24    string        tab = string(depth,'\t');
25    ostringstream msg;
26
27    msg << tab << "<counter name=\"" << _name << "\" >" << endl
28        << print_body(depth+1)
29        << tab << "</counter>" << endl;
30   
31    log_printf(FUNC,Counter,"print","End");
32
33    return msg.str();
34  };
35
36  ostream& operator<< (ostream& output_stream ,
37                       morpheo::behavioural::generic::counter::Statistics & x)
38  {
39    output_stream << x.print(0);
40
41    return output_stream;
42  };
43
44}; // end namespace counter
45}; // end namespace generic
46
47}; // end namespace behavioural
48}; // end namespace morpheo             
49#endif
Note: See TracBrowser for help on using the repository browser.