]> Creatis software - clitk.git/blobdiff - registration/clitkLBFGSBOptimizer.h
Debug RTStruct conversion with empty struc
[clitk.git] / registration / clitkLBFGSBOptimizer.h
index 8eec63a1f32046891728d3cfc7c29cad4e3666b7..4ea8924b270a95c8bd5553a4a84ad2ca6386dd1b 100644 (file)
@@ -19,6 +19,8 @@
 #define __clitkLBFGSBOptimizer_h
 #include "itkSingleValuedNonLinearVnlOptimizer.h"
 
+#include "clitkCommon.h"
+
 namespace clitk
 {
 
@@ -93,10 +95,10 @@ public:
 
 
   /** Start optimization with an initial value. */
-  void StartOptimization( void );
+  virtual void StartOptimization( void ) ITK_OVERRIDE;
 
   /** Plug in a Cost Function into the optimizer  */
-  virtual void SetCostFunction( itk::SingleValuedCostFunction * costFunction );
+  virtual void SetCostFunction( itk::SingleValuedCostFunction * costFunction ) ITK_OVERRIDE;
 
   /** Set the lower bound value for each variable. */
   virtual void SetLowerBound( const BoundValueType & value );
@@ -160,12 +162,12 @@ public:
   itkGetConstReferenceMacro( InfinityNormOfProjectedGradient, double );
 
   /** Get the reason for termination */
-  const std::string GetStopConditionDescription() const;
+  virtual const std::string GetStopConditionDescription() const ITK_OVERRIDE;
 
 protected:
   LBFGSBOptimizer();
   virtual ~LBFGSBOptimizer();
-  void PrintSelf(std::ostream& os, itk::Indent indent) const;
+  void PrintSelf(std::ostream& os, itk::Indent indent) const ITK_OVERRIDE;
 
   typedef Superclass::CostFunctionAdaptorType   CostFunctionAdaptorType;
 
@@ -179,11 +181,7 @@ private:
 
   bool                     m_OptimizerInitialized;
   InternalOptimizerType  * m_VnlOptimizer;
-#if ITK_VERSION_MAJOR > 3
   mutable std::ostringstream    m_StopConditionDescription;
-#else
-  mutable itk::OStringStream    m_StopConditionDescription;
-#endif
   BoundValueType           m_LowerBound;
   BoundValueType           m_UpperBound;
   BoundSelectionType       m_BoundSelection;