SMILX  1.01
elxComponentLoader.h
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 
15 #ifndef __elxComponentLoader_h
16 #define __elxComponentLoader_h
17 
18 #include "elxComponentDatabase.h"
19 #include "xoutmain.h"
20 
21 namespace elastix
22 {
23 
37 class ComponentLoader : public itk::Object
38 {
39 public:
40 
43  typedef itk::Object Superclass;
44  typedef itk::SmartPointer< Self > Pointer;
45  typedef itk::SmartPointer< const Self > ConstPointer;
46 
48  itkNewMacro( Self );
49  itkTypeMacro( ComponentLoader, Object );
50 
52  typedef ComponentDatabase ComponentDatabaseType;
53  typedef ComponentDatabaseType::Pointer ComponentDatabasePointer;
54 
56  itkSetObjectMacro( ComponentDatabase, ComponentDatabaseType );
57  itkGetObjectMacro( ComponentDatabase, ComponentDatabaseType );
58 
61  virtual int LoadComponents( const char * argv0 );
62 
64  virtual void UnloadComponents( void );
65 
66 protected:
67 
70  virtual ~ComponentLoader();
71 
72  ComponentDatabasePointer m_ComponentDatabase;
73 
74  bool m_ImageTypeSupportInstalled;
75  virtual int InstallSupportedImageTypes( void );
76 
77 private:
78 
80  ComponentLoader( const Self & ); // purposely not implemented
81  void operator=( const Self & ); // purposely not implemented
82 
83 };
84 
85 } //end namespace elastix
86 
87 #endif // #ifndef __elxComponentLoader_h
itkSetObjectMacro(ComponentDatabase, ComponentDatabaseType)
Determines which components (metrics, transforms, etc.) are available.
virtual int LoadComponents(const char *argv0)
virtual int InstallSupportedImageTypes(void)
virtual void UnloadComponents(void)
ComponentDatabase ComponentDatabaseType