00001 #ifndef PLAYA_OPT_CONVERGENCE_TEST_BASE_H 00002 #define PLAYA_OPT_CONVERGENCE_TEST_BASE_H 00003 00004 00005 #include "PlayaObjectWithVerbosity.hpp" 00006 #include "PlayaPrintable.hpp" 00007 #include "Teuchos_ParameterList.hpp" 00008 #include "PlayaOptState.hpp" 00009 00010 00011 namespace Playa 00012 { 00013 class OptState; 00014 using Teuchos::ParameterList; 00015 00016 /** 00017 * Base class for convergence tests for optimization algorithms 00018 * 00019 * @author Kevin Long 00020 */ 00021 class OptConvergenceTestBase : public ObjectWithVerbosity, 00022 public Printable 00023 { 00024 public: 00025 /** */ 00026 OptConvergenceTestBase(const ParameterList& params) 00027 { 00028 int verb = params.get<int>("Verbosity"); 00029 setVerb(verb); 00030 } 00031 00032 /** */ 00033 virtual ~OptConvergenceTestBase() {} 00034 00035 /** */ 00036 virtual OptStatus test(const OptState& state) const = 0 ; 00037 }; 00038 00039 } 00040 00041 #endif