KWStyle - itkTimeProbesCollectorBase.h
 
Matrix View
Description

1 /*=========================================================================
2
3   Program:   Insight Segmentation & Registration Toolkit
4   Module:    $RCSfile: itkTimeProbesCollectorBase.h.html,v $
5   Language:  C++
6   Date:      $Date: 2006/01/17 19:15:48 $
7   Version:   $Revision: 1.4 $
8
9   Copyright (c) Insight Software Consortium. All rights reserved.
10   See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
11
12      This software is distributed WITHOUT ANY WARRANTY; without even 
13      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
14      PURPOSE.  See the above copyright notices for more information.
15
16 =========================================================================*/
17 DEF #ifndef TimeProbesCollectorBase_h
18 DEF #define TimeProbesCollectorBase_h
19
20
21 #include "itkMacro.h"
22 #include "itkTimeProbe.h"
23 #include <map>
24 #include <string>
25
26 namespace itk
27 {
28
29 IND **/** \class TimeProbesCollectorBase
30 IND ****  \brief Class for aggregating a set of time probes. 
31 IND ****
32 IND ****  This class defines a set of TimeProbes and assign names to them.
33 LEN,IND ****  The user can start and stop each one of the probes by addressing them by name.
34 IND ****  
35 IND ****  \sa TimeProbe
36 IND ****  \sa RealTimeClock
37 IND ****
38 IND ****/
39 class ITKCommon_EXPORT TimeProbesCollectorBase 
40 {
41
42 public:
43
44   typedef std::string                IdType;
45   typedef std::map<IdType,TimeProbe> MapType;
46
47   TimeProbesCollectorBase();
48   virtual ~TimeProbesCollectorBase();
49
50   /** Start a time probe with a particular name. If the time probe does not
51    * exist, it will be created */
52   virtual void Start( const char * name );
53
54   /** Stop a time probe identified with a name */
55   virtual void Stop( const char * name );
56   
57   /** Report the summary of results from the time probes */
58   virtual void Report(void) const;
59
60 LEN   /** Destroy the set of probes. New probes can be created after invoking this method. */
61   virtual void Clear(void);
62
63 protected:
64
65   MapType   m_Probes;
66
67
68 };
69
70 }
71
72 #endif
73

Generated by KWStyle 1.0b on Tuesday January,17 at 02:14:50PM
© Kitware Inc.