18 #ifndef FUNCTORBASE_IMPL_H 19 #define FUNCTORBASE_IMPL_H 34 if(param_name < param_.size())
36 param_[param_name] = param_value;
40 param_.push_back(param_value);
48 unsigned int n = func->
param_.size();
52 for(
unsigned int i=0; i < n; i++)
55 param_[i] = func->
param(i);
62 OLD_ASSERT(param_name < param_.size(),
"Parameter of the functor was not set.");
64 return param_[param_name];
84 #endif //FUNCTORBASE_IMPL_H void set_param(unsigned int param_name, double param_value)
Sets a functor's parameter.
std::vector< double > param_
Class provides common functionality for functors.
FunctorBase()
Constructor.
IFunctorBase()
Constructor.
virtual ~FunctorBase()
Destructor.
Global macros to enhance readability and debugging, general constants.
FunctorCommon()
Constructor.
virtual ~IFunctorBase()
Destructor.
void set_param_from_func(FunctorCommon< TType > *func)
Sets a functor's parameters from another functor.
virtual ~FunctorCommon()
Destructor.
double param(unsigned int param_name)
Returns parameter.