ITK  5.0.0
Insight Segmentation and Registration Toolkit
itkTransformIOFactory.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef itkTransformIOFactory_h
19 #define itkTransformIOFactory_h
20 
21 #include "ITKIOTransformBaseExport.h"
22 
23 #include "itkObject.h"
24 #include "itkTransformIOBase.h"
25 
26 namespace itk
27 {
28 
31 
36 template<typename TParametersValueType>
37 class ITK_TEMPLATE_EXPORT TransformIOFactoryTemplate:public Object
38 {
39 public:
40  ITK_DISALLOW_COPY_AND_ASSIGN(TransformIOFactoryTemplate);
41 
44  using Superclass = Object;
47 
51  itkTypeMacro(TransformIOFactoryTemplate, Object);
52 
55 
60  CreateTransformIO(const char *path, TransformIOFactoryFileModeType mode);
61 
62 protected:
64  ~TransformIOFactoryTemplate() override;
65 };
66 
69 
70 } // end namespace itk
71 
72 // Note: Explicit instantiation is done in itkTransformIOFactory.cxx
73 
74 #endif
75 
77 #ifndef ITK_TEMPLATE_EXPLICIT_TransformIOFactory
78 // Explicit instantiation is required to ensure correct dynamic_cast
79 // behavior across shared libraries.
80 //
81 // IMPORTANT: Since within the same compilation unit,
82 // ITK_TEMPLATE_EXPLICIT_<classname> defined and undefined states
83 // need to be considered. This code *MUST* be *OUTSIDE* the header
84 // guards.
85 //
86 # if defined( ITKIOTransformBase_EXPORTS )
87 // We are building this library
88 # define ITKIOTransformBase_EXPORT_EXPLICIT ITK_FORWARD_EXPORT
89 # else
90 // We are using this library
91 # define ITKIOTransformBase_EXPORT_EXPLICIT ITKIOTransformBase_EXPORT
92 # endif
93 namespace itk
94 {
95 
96 #ifdef ITK_HAS_GCC_PRAGMA_DIAG_PUSHPOP
97  ITK_GCC_PRAGMA_DIAG_PUSH()
98 #endif
99 ITK_GCC_PRAGMA_DIAG(ignored "-Wattributes")
100 
103 
104 #ifdef ITK_HAS_GCC_PRAGMA_DIAG_PUSHPOP
105  ITK_GCC_PRAGMA_DIAG_POP()
106 #else
107  ITK_GCC_PRAGMA_DIAG(warning "-Wattributes")
108 #endif
109 
110 } // end namespace itk
111 # undef ITKIOTransformBase_EXPORT_EXPLICIT
112 #endif
#define ITKIOTransformBase_EXPORT_EXPLICIT
Light weight base class for most itk classes.
template class ITKIOTransformBase_EXPORT_EXPLICIT TransformIOFactoryTemplate< float >
TransformIOFactoryFileModeType
typename TransformIOBaseTemplate< TParametersValueType >::Pointer TransformIOBasePointer
Create instances of TransformIO objects using an object factory.
template class ITKIOTransformBase_EXPORT_EXPLICIT TransformIOFactoryTemplate< double >
Base class for most ITK classes.
Definition: itkObject.h:60