go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
elxBaseComponent.h
Go to the documentation of this file.
1 /*======================================================================
2 
3  This file is part of the elastix software.
4 
5  Copyright (c) University Medical Center Utrecht. All rights reserved.
6  See src/CopyrightElastix.txt or http://elastix.isi.uu.nl/legal.php for
7  details.
8 
9  This software is distributed WITHOUT ANY WARRANTY; without even
10  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11  PURPOSE. See the above copyright notices for more information.
12 
13 ======================================================================*/
14 #ifndef __elxBaseComponent_h
15 #define __elxBaseComponent_h
16 
30 #ifdef _MSC_VER
31 #pragma warning ( disable : 4786 )
32 #pragma warning ( disable : 4503 )
33 #endif
34 
35 #include <iostream>
36 #include <sstream>
37 
39 #define __ELASTIX_VERSION 4.700
40 
42 namespace elastix
43 {
44 
61 {
62 public:
63 
70  virtual int BeforeAllBase( void ) { return 0; }
71  virtual int BeforeAll( void ) { return 0; }
72 
79  virtual void BeforeRegistrationBase( void ) {}
80  virtual void BeforeEachResolutionBase( void ) {}
81  virtual void AfterEachResolutionBase( void ) {}
82  virtual void AfterEachIterationBase( void ) {}
83  virtual void AfterRegistrationBase( void ) {}
84 
91  virtual void BeforeRegistration( void ) {}
92  virtual void BeforeEachResolution( void ) {}
93  virtual void AfterEachResolution( void ) {}
94  virtual void AfterEachIteration( void ) {}
95  virtual void AfterRegistration( void ) {}
96 
102  virtual const char * elxGetClassName( void ) const
103  {
104  return "BaseComponent";
105  }
106 
107 
115  virtual void SetComponentLabel( const char * label, unsigned int idx )
116  {
117  std::ostringstream makestring;
118  makestring << label << idx;
119  this->m_ComponentLabel = makestring.str();
120  }
121 
122 
124  virtual const char * GetComponentLabel( void ) const
125  {
126  return this->m_ComponentLabel.c_str();
127  }
128 
129 
130 protected:
131 
133  virtual ~BaseComponent() {}
134 
135 private:
136 
137  BaseComponent( const BaseComponent & ); // purposely not implemented
138  void operator=( const BaseComponent & ); // purposely not implemented
139 
140  std::string m_ComponentLabel;
141 
142 };
143 
144 } // end namespace elastix
145 
147 namespace elx = elastix;
148 
149 #endif // end #ifndef __elxBaseComponent_h
virtual int BeforeAll(void)
virtual int BeforeAllBase(void)
void operator=(const BaseComponent &)
virtual void AfterEachResolution(void)
virtual void AfterEachIterationBase(void)
The BaseComponent class is a class that all elastix components should inherit from.
virtual const char * elxGetClassName(void) const
virtual const char * GetComponentLabel(void) const
virtual void AfterRegistrationBase(void)
virtual void AfterEachResolutionBase(void)
virtual void BeforeEachResolutionBase(void)
virtual void BeforeRegistrationBase(void)
virtual void AfterEachIteration(void)
virtual void SetComponentLabel(const char *label, unsigned int idx)
virtual void BeforeRegistration(void)
virtual void AfterRegistration(void)
virtual void BeforeEachResolution(void)


Generated on 27-04-2014 for elastix by doxygen 1.8.6 elastix logo