bipedal locomotion framework
A suite of libraries for achieving bipedal locomotion on humanoid robots
BipedalLocomotion::ParametersHandler::IParametersHandler Class Referenceabstract

Parameters handler interface. More...

#include <ParametersHandler/include/BipedalLocomotion/ParametersHandler/IParametersHandler.h>

Public Types

using unique_ptr = std::unique_ptr< IParametersHandler >
 
using shared_ptr = std::shared_ptr< IParametersHandler >
 
using weak_ptr = std::weak_ptr< IParametersHandler >
 

Public Member Functions

virtual bool getParameter (const std::string &parameterName, int &parameter) const =0
 Get a parameter [int]. More...
 
virtual bool getParameter (const std::string &parameterName, double &parameter) const =0
 Get a parameter [double]. More...
 
virtual bool getParameter (const std::string &parameterName, std::string &parameter) const =0
 Get a parameter [std::string]. More...
 
virtual bool getParameter (const std::string &parameterName, bool &parameter) const =0
 Get a parameter [bool]. More...
 
virtual bool getParameter (const std::string &parameterName, std::chrono::nanoseconds &parameter) const =0
 Get a parameter [int]. More...
 
virtual bool getParameter (const std::string &parameterName, std::vector< bool > &parameter) const =0
 Get a parameter [std::vector<bool>]. More...
 
virtual bool getParameter (const std::string &parameterName, GenericContainer::Vector< int >::Ref parameter) const =0
 Get a parameter [GenericContainer::Vector<int>]. More...
 
virtual bool getParameter (const std::string &parameterName, GenericContainer::Vector< double >::Ref parameter) const =0
 Get a parameter [GenericContainer::Vector<double>]. More...
 
virtual bool getParameter (const std::string &parameterName, GenericContainer::Vector< std::string >::Ref parameter) const =0
 Get a parameter [GenericContainer::Vector<std::string>]. More...
 
virtual bool getParameter (const std::string &parameterName, GenericContainer::Vector< std::chrono::nanoseconds >::Ref parameter) const =0
 Get a parameter [GenericContainer::Vector<std::chrono::nanoseconds>]. More...
 
virtual void setParameter (const std::string &parameterName, const int &parameter)=0
 Set a parameter [int]. More...
 
virtual void setParameter (const std::string &parameterName, const double &parameter)=0
 Set a parameter [double]. More...
 
virtual void setParameter (const std::string &parameterName, const std::string &parameter)=0
 Set a parameter [std::string]. More...
 
virtual void setParameter (const std::string &parameterName, const char *parameter)=0
 Set a parameter [const char*]. More...
 
virtual void setParameter (const std::string &parameterName, const bool &parameter)=0
 Set a parameter [bool]. More...
 
virtual void setParameter (const std::string &parameterName, const std::chrono::nanoseconds &parameter)=0
 Set a parameter [std::chrono::nanoseconds]. More...
 
virtual void setParameter (const std::string &parameterName, const std::vector< bool > &parameter)=0
 Set a parameter [std::vector<bool>]. More...
 
virtual void setParameter (const std::string &parameterName, const GenericContainer::Vector< const int >::Ref parameter)=0
 Set a parameter [GenericContainer::Vector<int>]. More...
 
virtual void setParameter (const std::string &parameterName, const GenericContainer::Vector< const double >::Ref parameter)=0
 Set a parameter [GenericContainer::Vector<double>]. More...
 
virtual void setParameter (const std::string &parameterName, const GenericContainer::Vector< const std::string >::Ref parameter)=0
 Set a parameter [GenericContainer::Vector<std::string>]. More...
 
virtual void setParameter (const std::string &parameterName, const GenericContainer::Vector< const std::chrono::nanoseconds >::Ref parameter)=0
 Get a parameter [GenericContainer::Vector<std::chrono::nanoseconds>]. More...
 
virtual weak_ptr getGroup (const std::string &name) const =0
 Get a Group from the handler. More...
 
virtual bool setGroup (const std::string &name, shared_ptr newGroup)=0
 Set a new group on the handler. More...
 
virtual std::string toString () const =0
 Return a standard text representation of the content of the object. More...
 
virtual bool isEmpty () const =0
 Check if the handler contains parameters. More...
 
virtual void clear ()=0
 Clears the handler from all the parameters. More...
 
virtual shared_ptr clone () const =0
 Clone the content of the content. More...
 
virtual ~IParametersHandler ()=default
 Destructor.
 

Detailed Description

Parameters handler interface.

Member Function Documentation

◆ getParameter() [1/10]

virtual bool BipedalLocomotion::ParametersHandler::IParametersHandler::getParameter ( const std::string &  parameterName,
int &  parameter 
) const
pure virtual

Get a parameter [int].

Parameters
parameterNamename of the parameter
parameterparameter
Returns
true/false in case of success/failure

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ getParameter() [2/10]

virtual bool BipedalLocomotion::ParametersHandler::IParametersHandler::getParameter ( const std::string &  parameterName,
double &  parameter 
) const
pure virtual

Get a parameter [double].

Parameters
parameterNamename of the parameter
parameterparameter
Returns
true/false in case of success/failure

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ getParameter() [3/10]

virtual bool BipedalLocomotion::ParametersHandler::IParametersHandler::getParameter ( const std::string &  parameterName,
std::string &  parameter 
) const
pure virtual

Get a parameter [std::string].

Parameters
parameterNamename of the parameter
parameterparameter
Returns
true/false in case of success/failure

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ getParameter() [4/10]

virtual bool BipedalLocomotion::ParametersHandler::IParametersHandler::getParameter ( const std::string &  parameterName,
bool &  parameter 
) const
pure virtual

Get a parameter [bool].

Parameters
parameterNamename of the parameter
parameterparameter
Returns
true/false in case of success/failure

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ getParameter() [5/10]

virtual bool BipedalLocomotion::ParametersHandler::IParametersHandler::getParameter ( const std::string &  parameterName,
std::chrono::nanoseconds &  parameter 
) const
pure virtual

Get a parameter [int].

Parameters
parameterNamename of the parameter
parameterparameter
Returns
true/false in case of success/failure

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ getParameter() [6/10]

virtual bool BipedalLocomotion::ParametersHandler::IParametersHandler::getParameter ( const std::string &  parameterName,
std::vector< bool > &  parameter 
) const
pure virtual

Get a parameter [std::vector<bool>].

Parameters
parameterNamename of the parameter
parameterparameter
Returns
true/false in case of success/failure

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ getParameter() [7/10]

virtual bool BipedalLocomotion::ParametersHandler::IParametersHandler::getParameter ( const std::string &  parameterName,
GenericContainer::Vector< int >::Ref  parameter 
) const
pure virtual

Get a parameter [GenericContainer::Vector<int>].

Parameters
parameterNamename of the parameter
parameterparameter
Returns
true/false in case of success/failure

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ getParameter() [8/10]

virtual bool BipedalLocomotion::ParametersHandler::IParametersHandler::getParameter ( const std::string &  parameterName,
GenericContainer::Vector< double >::Ref  parameter 
) const
pure virtual

Get a parameter [GenericContainer::Vector<double>].

Parameters
parameterNamename of the parameter
parameterparameter
Returns
true/false in case of success/failure

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ getParameter() [9/10]

virtual bool BipedalLocomotion::ParametersHandler::IParametersHandler::getParameter ( const std::string &  parameterName,
GenericContainer::Vector< std::string >::Ref  parameter 
) const
pure virtual

Get a parameter [GenericContainer::Vector<std::string>].

Parameters
parameterNamename of the parameter
parameterparameter
Returns
true/false in case of success/failure

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ getParameter() [10/10]

virtual bool BipedalLocomotion::ParametersHandler::IParametersHandler::getParameter ( const std::string &  parameterName,
GenericContainer::Vector< std::chrono::nanoseconds >::Ref  parameter 
) const
pure virtual

Get a parameter [GenericContainer::Vector<std::chrono::nanoseconds>].

Parameters
parameterNamename of the parameter
parameterparameter
Returns
true/false in case of success/failure

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ setParameter() [1/11]

virtual void BipedalLocomotion::ParametersHandler::IParametersHandler::setParameter ( const std::string &  parameterName,
const int &  parameter 
)
pure virtual

Set a parameter [int].

Parameters
parameterNamename of the parameter
parameterparameter

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ setParameter() [2/11]

virtual void BipedalLocomotion::ParametersHandler::IParametersHandler::setParameter ( const std::string &  parameterName,
const double &  parameter 
)
pure virtual

Set a parameter [double].

Parameters
parameterNamename of the parameter
parameterparameter

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ setParameter() [3/11]

virtual void BipedalLocomotion::ParametersHandler::IParametersHandler::setParameter ( const std::string &  parameterName,
const std::string &  parameter 
)
pure virtual

Set a parameter [std::string].

Parameters
parameterNamename of the parameter
parameterparameter

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ setParameter() [4/11]

virtual void BipedalLocomotion::ParametersHandler::IParametersHandler::setParameter ( const std::string &  parameterName,
const char *  parameter 
)
pure virtual

◆ setParameter() [5/11]

virtual void BipedalLocomotion::ParametersHandler::IParametersHandler::setParameter ( const std::string &  parameterName,
const bool &  parameter 
)
pure virtual

Set a parameter [bool].

Parameters
parameterNamename of the parameter
parameterparameter

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ setParameter() [6/11]

virtual void BipedalLocomotion::ParametersHandler::IParametersHandler::setParameter ( const std::string &  parameterName,
const std::chrono::nanoseconds &  parameter 
)
pure virtual

Set a parameter [std::chrono::nanoseconds].

Parameters
parameterNamename of the parameter
parameterparameter

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ setParameter() [7/11]

virtual void BipedalLocomotion::ParametersHandler::IParametersHandler::setParameter ( const std::string &  parameterName,
const std::vector< bool > &  parameter 
)
pure virtual

Set a parameter [std::vector<bool>].

Parameters
parameterNamename of the parameter
parameterparameter

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ setParameter() [8/11]

virtual void BipedalLocomotion::ParametersHandler::IParametersHandler::setParameter ( const std::string &  parameterName,
const GenericContainer::Vector< const int >::Ref  parameter 
)
pure virtual

Set a parameter [GenericContainer::Vector<int>].

Parameters
parameterNamename of the parameter
parameterparameter

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ setParameter() [9/11]

virtual void BipedalLocomotion::ParametersHandler::IParametersHandler::setParameter ( const std::string &  parameterName,
const GenericContainer::Vector< const double >::Ref  parameter 
)
pure virtual

Set a parameter [GenericContainer::Vector<double>].

Parameters
parameterNamename of the parameter
parameterparameter

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ setParameter() [10/11]

virtual void BipedalLocomotion::ParametersHandler::IParametersHandler::setParameter ( const std::string &  parameterName,
const GenericContainer::Vector< const std::string >::Ref  parameter 
)
pure virtual

Set a parameter [GenericContainer::Vector<std::string>].

Parameters
parameterNamename of the parameter
parameterparameter

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ setParameter() [11/11]

virtual void BipedalLocomotion::ParametersHandler::IParametersHandler::setParameter ( const std::string &  parameterName,
const GenericContainer::Vector< const std::chrono::nanoseconds >::Ref  parameter 
)
pure virtual

Get a parameter [GenericContainer::Vector<std::chrono::nanoseconds>].

Parameters
parameterNamename of the parameter
parameterparameter

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ getGroup()

virtual weak_ptr BipedalLocomotion::ParametersHandler::IParametersHandler::getGroup ( const std::string &  name) const
pure virtual

Get a Group from the handler.

Parameters
namename of the group
Returns
A pointer to IParametersHandler, if the group is not found the weak pointer cannot be locked
Warning
Please implement the specific version of this method in the Derived class. Please check YarpImplementation::getGroup

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ setGroup()

virtual bool BipedalLocomotion::ParametersHandler::IParametersHandler::setGroup ( const std::string &  name,
shared_ptr  newGroup 
)
pure virtual

Set a new group on the handler.

Parameters
namename of the group
newGroupshared pointer to the new group
Warning
Please implement the specific version of this method in the Derived class. Please check YarpImplementation::setGroup
Returns
true/false in case of success/failure

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ toString()

virtual std::string BipedalLocomotion::ParametersHandler::IParametersHandler::toString ( ) const
pure virtual

Return a standard text representation of the content of the object.

Returns
a string containing the standard text representation of the content of the object.
Warning
Please implement the specific version of this method in the Derived class. Please check YarpImplementation::toString

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ isEmpty()

virtual bool BipedalLocomotion::ParametersHandler::IParametersHandler::isEmpty ( ) const
pure virtual

Check if the handler contains parameters.

Returns
true if the handler does not contain any parameters, false otherwise
Warning
Please implement the specific version of this method in the Derived class. Please check YarpImplementation::isEmpty

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ clear()

virtual void BipedalLocomotion::ParametersHandler::IParametersHandler::clear ( )
pure virtual

Clears the handler from all the parameters.

Warning
Please implement the specific version of this method in the Derived class. Please check YarpImplementation::clear

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.

◆ clone()

virtual shared_ptr BipedalLocomotion::ParametersHandler::IParametersHandler::clone ( ) const
pure virtual

Clone the content of the content.

Returns
a IParametersHandler::shared_ptr clone of the current handler.
Warning
Please implement the specific version of this method in the Derived class. Please check YarpImplementation::clone

Implemented in BipedalLocomotion::ParametersHandler::YarpImplementation, BipedalLocomotion::ParametersHandler::TomlImplementation, and BipedalLocomotion::ParametersHandler::StdImplementation.


The documentation for this class was generated from the following file: