NifTK  16.4.1 - 0798f20
CMIC's Translational Medical Imaging Platform
itkConstraint.h
Go to the documentation of this file.
1 /*=============================================================================
2 
3  NifTK: A software platform for medical image computing.
4 
5  Copyright (c) University College London (UCL). All rights reserved.
6 
7  This software is distributed WITHOUT ANY WARRANTY; without even
8  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
9  PURPOSE.
10 
11  See LICENSE.txt in the top level directory for details.
12 
13 =============================================================================*/
14 
15 #ifndef itkConstraint_h
16 #define itkConstraint_h
17 
18 #include <itkObject.h>
19 #include <itkObjectFactory.h>
20 
21 #include <itkSingleValuedCostFunction.h>
22 
23 namespace itk
24 {
25 
42 class ITK_EXPORT Constraint :
43  public Object
44 {
45 public:
47  typedef Constraint Self;
48  typedef Object Superclass;
49  typedef SmartPointer<Self> Pointer;
50  typedef SmartPointer<const Self> ConstPointer;
51  typedef SingleValuedCostFunction::MeasureType MeasureType;
52  typedef SingleValuedCostFunction::DerivativeType DerivativeType;
53  typedef SingleValuedCostFunction::ParametersType ParametersType;
54 
56  itkTypeMacro( Constraint, Object );
57 
59  virtual MeasureType EvaluateConstraint(const ParametersType & parameters) = 0;
60 
62  virtual void EvaluateDerivative(const ParametersType & parameters, DerivativeType & derivative ) const = 0;
63 
64 protected:
65 
66  Constraint() {};
67  virtual ~Constraint() {};
68 
69 private:
70 
71  Constraint(const Self&); // purposely not implemented
72  void operator=(const Self&); // purposely not implemented
73 };
74 
75 } // end namespace itk
76 
77 #endif
SingleValuedCostFunction::ParametersType ParametersType
Definition: itkConstraint.h:53
SingleValuedCostFunction::DerivativeType DerivativeType
Definition: itkConstraint.h:52
Definition: niftkITKAffineResampleImage.cxx:74
SmartPointer< Self > Pointer
Definition: itkConstraint.h:49
virtual ~Constraint()
Definition: itkConstraint.h:67
Abstract Base class for constraints, which are objects that return a single double value...
Definition: itkConstraint.h:42
SingleValuedCostFunction::MeasureType MeasureType
Definition: itkConstraint.h:51
Constraint Self
Definition: itkConstraint.h:47
Constraint()
Definition: itkConstraint.h:66
Object Superclass
Definition: itkConstraint.h:48
SmartPointer< const Self > ConstPointer
Definition: itkConstraint.h:50