]> Creatis software - FrontAlgorithms.git/blob - lib/fpa/Base/Functors/Inverse.h
af68022246189edf414cfa37b26c906a09671370
[FrontAlgorithms.git] / lib / fpa / Base / Functors / Inverse.h
1 #ifndef __fpa__Base__Functors__Inverse__h__
2 #define __fpa__Base__Functors__Inverse__h__
3
4 #include <fpa/Config.h>
5 #include <itkFunctionBase.h>
6
7 namespace fpa
8 {
9   namespace Base
10   {
11     namespace Functors
12     {
13       /**
14        */
15       template< class _TInput, class _TOutput >
16       class Inverse
17         : public itk::FunctionBase< _TInput, _TOutput >
18       {
19       public:
20         typedef Inverse                                Self;
21         typedef itk::FunctionBase< _TInput, _TOutput > Superclass;
22         typedef itk::SmartPointer< Self >              Pointer;
23         typedef itk::SmartPointer< const Self >        ConstPointer;
24
25         typedef _TInput  TInput;
26         typedef _TOutput TOutput;
27
28       public:
29         itkNewMacro( Self );
30         itkTypeMacro( Inverse, itk::FunctionBase );
31
32         itkGetConstMacro( NegativeValue, _TOutput );
33         itkSetMacro( NegativeValue, _TOutput );
34
35       public:
36         virtual TOutput Evaluate( const TInput& x ) const override;
37
38       protected:
39         Inverse( );
40         virtual ~Inverse( );
41
42       private:
43         // Purposely not implemented
44         Inverse( const Self& other );
45         Self& operator=( const Self& other );
46
47       protected:
48         _TOutput m_NegativeValue;
49       };
50
51     } // ecapseman
52
53   } // ecapseman
54
55 } // ecapseman
56
57 #ifndef ITK_MANUAL_INSTANTIATION
58 #  include <fpa/Base/Functors/Inverse.hxx>
59 #endif // ITK_MANUAL_INSTANTIATION
60
61 #endif // __fpa__Base__Functors__Inverse__h__
62
63 // eof - $RCSfile$