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.   | |
| virtual ParameterResult | DeclareParameter (const std::string &_parameterName, const google::protobuf::Message &_msg)=0 | 
| Declare a new parameter.   | |
| virtual gz::msgs::ParameterDeclarations | ListParameters () const =0 | 
| List all existing parameters.   | |
| virtual ParameterResult | Parameter (const std::string &_parameterName, google::protobuf::Message &_parameter) const =0 | 
| Request the value of a parameter.   | |
| 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.   | |
| virtual ParameterResult | SetParameter (const std::string &_parameterName, const google::protobuf::Message &_msg)=0 | 
| Set the value of a parameter.   | |
Detailed Description
Common interface, implemented by ParametersRegistry (local updates) and by ParametersClients (remote requests).
Constructor & Destructor Documentation
◆ ~ParametersInterface()
      
  | 
  virtualdefault | 
Default virtual destructor.
Member Function Documentation
◆ DeclareParameter()
      
  | 
  pure virtual | 
Declare a new parameter.
- Parameters
 - 
  
[in] _parameterName Name of the parameter to be declared. [in] _msg Protobuf message to be used as the initial parameter value.  
- Returns
 - A ParameterResult return code, can return error types:
- ParameterResultType::AlreadyDeclared if the parameter was already declared.
 - ParameterResultType::InvalidType if the parameter type is not valid.
 
 
Implemented in ParametersClient, and ParametersRegistry.
◆ ListParameters()
      
  | 
  pure virtual | 
List all existing parameters.
- Returns
 - The name and types of existing parameters.
 
Implemented in ParametersClient, and ParametersRegistry.
◆ Parameter() [1/2]
      
  | 
  pure virtual | 
Request the value of a parameter.
- Parameters
 - 
  
[in] _parameterName Name of the parameter to be requested. [out] _parameter Output were the parameter value will be set.  
- Returns
 - A ParameterResult return code, can return error types:
- ParameterResultType::NotDeclared if the parameter was not declared.
 - ParameterResultType::InvalidType if the parameter type was invalid.
 - ParameterResultType::Unexpected, if an unexpected error happened.
 
 
Implemented in ParametersClient, and ParametersRegistry.
◆ Parameter() [2/2]
      
  | 
  pure virtual | 
Request the value of a parameter. Similar to the other overload, but it allocates a message of the right type.
- Parameters
 - 
  
[in] _parameterName Name of the parameter to be requested. [out] _parameter Output were the parameter value will be set.  
- Returns
 - A ParameterResult return code, can return error types:
- ParameterResultType::NotDeclared if the parameter was not declared.
 - ParameterResultType::Unexpected, if an unexpected error happened.
 
 
Implemented in ParametersClient, and ParametersRegistry.
◆ SetParameter()
      
  | 
  pure virtual | 
Set the value of a parameter.
- Parameters
 - 
  
[in] _parameterName Name of the parameter to be set. [in] _msg Protobuf message to be used as the parameter value.  
- Returns
 - A ParameterResult return code, can return error types:
- ParameterResultType::NotDeclared if the parameter was not declared.
 - ParameterResultType::InvalidType if the parameter type was invalid.
 
 
Implemented in ParametersClient, and ParametersRegistry.
The documentation for this class was generated from the following file: