KWStyle - itkPathToPathFilter.txx
 
Matrix View
Description

1 /*=========================================================================
2
3   Program:   Insight Segmentation & Registration Toolkit
4   Module:    $RCSfile: itkPathToPathFilter.txx.html,v $
5   Language:  C++
6   Date:      $Date: 2006/01/17 19:15:43 $
7   Version:   $Revision: 1.4 $
8
9   Copyright (c) Insight Software Consortium. All rights reserved.
10   See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
11
12      This software is distributed WITHOUT ANY WARRANTY; without even 
13      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
14      PURPOSE.  See the above copyright notices for more information.
15
16 =========================================================================*/
17
18 DEF #ifndef _itkPathToPathFilter_txx
19 DEF #define _itkPathToPathFilter_txx
20
21 #include "itkPathToPathFilter.h"
22
23
24 namespace itk
25 {
26
27 /**
28  *
29  */
30 template <class TInputPath, class TOutputPath>
31 PathToPathFilter<TInputPath,TOutputPath>
32 ::PathToPathFilter()
33 {
34   // Let the superclass do everything
35 }
36
37 /**
38  *
39  */
40 template <class TInputPath, class TOutputPath>
41 void 
42 PathToPathFilter<TInputPath,TOutputPath>
43 ::SetInput(const InputPathType *path)
44 {
45   // Process object is not const-correct so the const_cast is required here
46   this->ProcessObject::SetNthInput(0, 
47                                    const_cast< InputPathType * >( path ) );
48 }
49
50
51 /**
52  * Connect one of the operands for pixel-wise addition
53  */
54 template <class TInputPath, class TOutputPath>
55 void 
56 PathToPathFilter<TInputPath,TOutputPath>
57 ::SetInput( unsigned int index, const TInputPath * path ) 
58 {
59   // Process object is not const-correct so the const_cast is required here
60   this->ProcessObject::SetNthInput(index, 
61                                    const_cast< TInputPath *>( path ) );
62 }
63
64
65 EML
66 /**
67  *
68  */
69 template <class TInputPath, class TOutputPath>
70 const typename PathToPathFilter<TInputPath,TOutputPath>::InputPathType *
71 PathToPathFilter<TInputPath,TOutputPath>
72 ::GetInput(void) 
73 {
74   if (this->GetNumberOfInputs() < 1)
75     {
76     return 0;
77     }
78   
79   return static_cast<const TInputPath * >
80 IND ****(this->ProcessObject::GetInput(0) );
81 }
82   
83 /**
84  *
85  */
86 template <class TInputPath, class TOutputPath>
87 const typename PathToPathFilter<TInputPath,TOutputPath>::InputPathType *
88 PathToPathFilter<TInputPath,TOutputPath>
89 ::GetInput(unsigned int idx)
90 {
91   return static_cast< const TInputPath * >
92 IND ****(this->ProcessObject::GetInput(idx));
93 }
94
95 /**
96  *
97  */
98 template <class TInputPath, class TOutputPath>
99 void 
100 PathToPathFilter<TInputPath,TOutputPath>
101 ::GenerateInputRequestedRegion()
102 {
103   // ProcessObject::GenerateInputRequestedRegion() will (for each input) call
104   // Path::SetRequestedRegionToLargestPossibleRegion(), which is empty.
105   Superclass::GenerateInputRequestedRegion();
106 }
107
108 /**
109  *
110  */
111 template <class TInputPath, class TOutputPath>
112 void 
113 PathToPathFilter<TInputPath,TOutputPath>
114 ::PrintSelf(std::ostream& os, Indent indent) const
115 {
116   Superclass::PrintSelf(os, indent);
117 }
118
119
120 // end namespace itk
121
122 #endif
123

Generated by KWStyle 1.0b on Tuesday January,17 at 02:14:38PM
© Kitware Inc.