The following does not inherently check for type:
this->parameter_map_.set_parameter_value(parameter_name, parameter_value);
|
void set_parameter_value(const std::string& name, const T& value); |
Use of this function does not check for type, only directly inserts or assigns the value. To be fair, it is mentioned right below that the validation part should be overwritten:
|
virtual void validate_and_set_parameter(const std::shared_ptr<ParameterInterface>& parameter); |
But probably it could be made more clear. The current workaround is to get the parameter interface and then assign the value:
this->parameter_map_.get_parameter(parameter_name)->set_parameter_value<T>(parameter_value);
The following does not inherently check for type:
this->parameter_map_.set_parameter_value(parameter_name, parameter_value);control-libraries/source/state_representation/include/state_representation/parameters/ParameterMap.hpp
Line 91 in 3922662
Use of this function does not check for type, only directly inserts or assigns the value. To be fair, it is mentioned right below that the validation part should be overwritten:
control-libraries/source/state_representation/include/state_representation/parameters/ParameterMap.hpp
Line 107 in 3922662
But probably it could be made more clear. The current workaround is to get the parameter interface and then assign the value:
this->parameter_map_.get_parameter(parameter_name)->set_parameter_value<T>(parameter_value);