Gazebo Transport

API Reference

12.2.1
ParametersInterface Class Referenceabstract

Common interface, implemented by ParametersRegistry (local updates) and by ParametersClients (remote requests). More...

#include <Interface.hh>

Public Member Functions

virtual ~ParametersInterface ()=default
 Default virtual destructor. More...
 
virtual ParameterResult DeclareParameter (const std::string &_parameterName, const google::protobuf::Message &_msg)=0
 Declare a new parameter. More...
 
virtual gz::msgs::ParameterDeclarations ListParameters () const =0
 List all existing parameters. More...
 
virtual ParameterResult Parameter (const std::string &_parameterName, google::protobuf::Message &_parameter) const =0
 Request the value of a parameter. More...
 
virtual ParameterResult Parameter (const std::string &_parameterName, std::unique_ptr< google::protobuf::Message > &_parameter) const =0
 Request the value of a parameter. Similar to the other overload, but it allocates a message of the right type. More...
 
virtual ParameterResult SetParameter (const std::string &_parameterName, const google::protobuf::Message &_msg)=0
 Set the value of a parameter. More...
 

Detailed Description

Common interface, implemented by ParametersRegistry (local updates) and by ParametersClients (remote requests).

Constructor & Destructor Documentation

◆ ~ParametersInterface()

virtual ~ParametersInterface ( )
virtualdefault

Default virtual destructor.

Member Function Documentation

◆ DeclareParameter()

virtual ParameterResult DeclareParameter ( const std::string _parameterName,
const google::protobuf::Message &  _msg 
)
pure virtual

Declare a new parameter.

Parameters
[in]_parameterNameName of the parameter to be declared.
[in]_msgProtobuf message to be used as the initial parameter value.
Returns
A ParameterResult return code, can return error types:

Implemented in ParametersRegistry, and ParametersClient.

◆ ListParameters()

virtual gz::msgs::ParameterDeclarations ListParameters ( ) const
pure virtual

List all existing parameters.

Returns
The name and types of existing parameters.

Implemented in ParametersRegistry, and ParametersClient.

◆ Parameter() [1/2]

virtual ParameterResult Parameter ( const std::string _parameterName,
google::protobuf::Message &  _parameter 
) const
pure virtual

Request the value of a parameter.

Parameters
[in]_parameterNameName of the parameter to be requested.
[out]_parameterOutput were the parameter value will be set.
Returns
A ParameterResult return code, can return error types:

Implemented in ParametersRegistry, and ParametersClient.

◆ Parameter() [2/2]

virtual ParameterResult Parameter ( const std::string _parameterName,
std::unique_ptr< google::protobuf::Message > &  _parameter 
) const
pure virtual

Request the value of a parameter. Similar to the other overload, but it allocates a message of the right type.

Parameters
[in]_parameterNameName of the parameter to be requested.
[out]_parameterOutput were the parameter value will be set.
Returns
A ParameterResult return code, can return error types:

Implemented in ParametersRegistry, and ParametersClient.

◆ SetParameter()

virtual ParameterResult SetParameter ( const std::string _parameterName,
const google::protobuf::Message &  _msg 
)
pure virtual

Set the value of a parameter.

Parameters
[in]_parameterNameName of the parameter to be set.
[in]_msgProtobuf message to be used as the parameter value.
Returns
A ParameterResult return code, can return error types:

Implemented in ParametersRegistry, and ParametersClient.


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