]> Creatis software - FrontAlgorithms.git/blob - lib/fpa/Base/SkeletonWriter.h
26c4972ece50dd620490d39188e11689640f5025
[FrontAlgorithms.git] / lib / fpa / Base / SkeletonWriter.h
1 // =========================================================================
2 // @author Leonardo Florez Valencia
3 // @email florez-l@javeriana.edu.co
4 // =========================================================================
5
6 #ifndef __fpa__Base__SkeletonWriter__h__
7 #define __fpa__Base__SkeletonWriter__h__
8
9 #include <itkProcessObject.h>
10
11 namespace fpa
12 {
13   namespace Base
14   {
15     /**
16      */
17     template< class _TSkeleton >
18     class SkeletonWriter
19       : public itk::ProcessObject
20     {
21     public:
22       // Basic types
23       typedef SkeletonWriter                  Self;
24       typedef itk::ProcessObject              Superclass;
25       typedef itk::SmartPointer< Self >       Pointer;
26       typedef itk::SmartPointer< const Self > ConstPointer;
27
28       typedef _TSkeleton TSkeleton;
29       typedef typename TSkeleton::TEdges     TEdges;
30       typedef typename TSkeleton::TMatrix    TMatrix;
31       typedef typename TSkeleton::TMatrixRow TMatrixRow;
32       typedef typename TSkeleton::TPath      TPath;
33       typedef typename TSkeleton::TVertex    TVertex;
34
35     public:
36       itkNewMacro( Self );
37       itkTypeMacro( SkeletonWriter, itk::ProcessObject );
38
39       itkGetConstMacro( FileName, std::string );
40       itkSetMacro( FileName, std::string );
41
42     public:
43       const TSkeleton* GetInput( ) const;
44       void SetInput( const TSkeleton* skeleton );
45       virtual void Update( ) override;
46
47     protected:
48       SkeletonWriter( );
49       virtual ~SkeletonWriter( );
50
51       virtual void GenerateData( ) override;
52
53     private:
54       // Purposely not implemented
55       SkeletonWriter( const Self& );
56       void operator=( const Self& );
57
58     protected:
59       std::string m_FileName;
60     };
61
62   } // ecapseman
63
64 } // ecapseman
65
66 #ifndef ITK_MANUAL_INSTANTIATION
67 #  include <fpa/Base/SkeletonWriter.hxx>
68 #endif // ITK_MANUAL_INSTANTIATION
69
70 #endif // __fpa__Base__SkeletonWriter__h__
71
72 // eof - $RCSfile$