freStatisticData.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   F.R.E.E. - flexible registration evaluation engine
00004   Version:   v.1.0.0
00005   Date:      $Date: 2006/09/01 12:00:00 $
00006   Module:    $RCSfile: freStatisticData.h,v $
00007   Language:  C++
00008 
00009 
00010   Copyright (c) 2007 Ralf o Floca (Department of Medical Informatics,
00011   Institute for Medical Biometry and Informatics, University of Heidelberg,
00012   Germany). All rights reserved.
00013   See FREECopyright.txt or http://www.mi.med.uni-hd.de/free/copyright.htm
00014   for details.
00015 
00016      This software is distributed WITHOUT ANY WARRANTY; without even 
00017      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
00018      PURPOSE.  See the above copyright notices for more information.
00019 
00020 =========================================================================*/
00021 #ifndef __freStatisticData_h
00022 #define __freStatisticData_h
00023 
00024 #include "freStatisticEntry.h"
00025 
00026 #include "itkLightObject.h"
00027 
00028 namespace FREE
00029 {
00030 freXMLTagMacro(StatisticData, "freStat:Data");
00031 
00041 class StatisticData: public itk::LightObject, public XMLStreamObject
00042 {
00043 public:
00044   typedef StatisticData  Self;
00045   typedef itk::LightObject Superclass;
00046   typedef itk::SmartPointer<Self>        Pointer;
00047   typedef itk::SmartPointer<const Self>  ConstPointer;
00048 
00049         itkTypeMacro(StatisticData, itk::LightObject);
00050   itkNewMacro(StatisticData);
00051 
00052   typedef StatisticEntry::IDType IDType;
00053 
00054   typedef StatisticEntry::EntriesType EntriesType;
00055 
00057   StatisticData& operator = (const StatisticData& entry);
00058 
00059   StatisticEntry::Pointer CreateEntry();
00060 
00066   StatisticEntry::Pointer CreateChildEntry(const IDType& parentID);
00072   StatisticEntry::Pointer PostCreateChildEntry(const IDType& parentID);
00073 
00077   StatisticEntry::Pointer GetEntry(const IDType& entryID);
00078 
00081   StatisticEntry::Pointer GetCurrentEntry();
00082 
00085   IDType GetCurrentEntryID() const;
00086 
00088   IDType GetLastClosedEntryID() const;
00089 
00095   IDType CloseEntry(const IDType& entryID);
00097   void OpenEntry(const IDType& entryID);
00098 
00100   void CloseEntries();
00101 
00102   virtual ~StatisticData();
00103 
00105   virtual void Reset();
00106 
00107   const EntriesType& GetEntries() const;
00108   EntriesType& GetEntries();
00109 
00110 protected:
00112   StatisticData();
00113 
00115   IDType m_LastID;
00116 
00117   std::vector<IDType> m_EntryStack;
00118   IDType m_LastEntryID;
00119 
00120   StatisticEntry::Pointer m_smpRoot;
00121 
00122   clock_t m_StampOffset;
00123 
00124   StatisticEntry* SearchEntry(StatisticEntry* pCurrentEntry, const IDType& entryID);
00125 
00126   virtual void SubElementLoadProcessing(const std::string& rsXMLSubTag, const std::string& rsXMLSubElement, const std::string& rsXMLSubData);
00127   virtual std::string SaveData(const unsigned int& iDepth, bool& bHasSubElements) const;
00128 };
00129 
00130 } //end of namespace FREE
00131 
00132 #endif

Generated at Sat Oct 13 17:41:41 2007 for f.r.e.e. - Flexible Registration and Evaluation Engine by doxygen 1.5.3 written by Dimitri van Heesch, © 1997-2000