wxArt2D
prfl.h
Go to the documentation of this file.
1 /*! \file wx/genart/prfl.h
2  \brief profiling classes
3  \author Michael Sögtrop
4  \date Created 08/05/2004
5 
6  Copyright: 2004-2004 (c) Michael Sögtrop
7 
8  Licence: wxWidgets Licence
9 
10  RCS-ID: $Id: prfl.h,v 1.5 2005/08/16 16:47:52 titato Exp $
11 */
12 
13 
14 #if(defined(TRACE_H))
15 #pragma message(__FILE__)
16 #endif
17 
18 #ifndef WX_PRECOMP
19 #include "wx/wx.h"
20 #endif
21 
22 #include <wx/ffile.h>
23 
24 ///////////////////////////////////////////////////////////////////////////////
25 //
26 // Schutz gegen doppelte Einbindung
27 //
28 ///////////////////////////////////////////////////////////////////////////////
29 
30 #if(!defined(Prfl_H))
31 #define Prfl_H
32 
33 #include "wx/general/smrtptr.h"
34 
35 //! base profiler class
36 //!
37 //! Zusammenfassung der Anwendungsdetails der Klasse a2dProfiler
38 //!
39 //! a2dProfiler verwaltet die Profile-Ausgabedatei profile.txt
40 //!
41 //! Mit PRFL_DUMP(...) kann man wie mit printf in die Profile-Datei schreiben
42 //!
43 //! Profiling ist nur eingeschaltet, wenn das macro PRFL_ENBL definiert ist
44 //! oder wenn die Datei PrflEnbl.h includiert wird.
45 //!
46 //! siehe auch:
47 //! prflCnt.h
48 //! prflTmr.h
49 class A2DGENERALDLLEXP a2dProfiler
50 {
51 public:
52 
53  //! constructor
54  a2dProfiler( const wxString& idIn );
55 
56  //! destructor
57  ~a2dProfiler ();
58 
59  //! opens the profiling data file, if not yet open.
60  static void OpenPrflFile();
61 
62 
63 protected:
64  wxString
65  id;
66 
67  //!Number of aktive PrflCnt ( the last one closes the file. )
68  static int nmbrActv;
69  static wxFFile prflFile; //! output file
70 };
71 
72 #if(defined(PRFL_ENBL))
73 #define PRFL_DUMP a2dProfiler::PrflDump
74 #else
75 #define PRFL_DUMP 1 ? (void)0 : a2dProfiler::PrflDump
76 #endif
77 
78 #endif // Prfl_H
static int nmbrActv
Number of aktive PrflCnt ( the last one closes the file. )
Definition: prfl.h:68
smart pointer class and list.
prfl.h Source File -- Sun Oct 12 2014 17:04:23 -- Sun Oct 12 2014 -- 1.8.5 -- wxArt2D -- . -- Main Page Reference Documentation