YARP
Yet Another Robot Platform
 
Loading...
Searching...
No Matches
FakeLaserWithMotor_ParamsParser Class Reference

This class is the parameters parser for class FakeLaserWithMotor. More...

#include <fake/fakeLaserWithMotor/FakeLaserWithMotor_ParamsParser.h>

+ Inheritance diagram for FakeLaserWithMotor_ParamsParser:

Classes

struct  parser_version_type
 

Public Member Functions

 FakeLaserWithMotor_ParamsParser ()
 
 ~FakeLaserWithMotor_ParamsParser () override=default
 
bool parseParams (const yarp::os::Searchable &config) override
 Parse the DeviceDriver parameters.
 
std::string getDeviceClassName () const override
 Get the name of the DeviceDriver class.
 
std::string getDeviceName () const override
 Get the name of the device (i.e.
 
std::string getDocumentationOfDeviceParams () const override
 Get the documentation of the DeviceDriver's parameters.
 
std::vector< std::string > getListOfParams () const override
 Return a list of all params used by the device.
 
- Public Member Functions inherited from yarp::dev::IDeviceDriverParams
virtual ~IDeviceDriverParams ()
 

Public Attributes

const std::string m_device_classname = {"FakeLaserWithMotor"}
 
const std::string m_device_name = {"fakeLaserWithMotor"}
 
bool m_parser_is_strict = false
 
const parser_version_type m_parser_version = {}
 
const std::string m_test_defaultValue = {"use_pattern"}
 
const std::string m_localization_port_defaultValue = {"/fakeLaser/location:i"}
 
const std::string m_localization_server_defaultValue = {"/localizationServer"}
 
const std::string m_localization_client_defaultValue = {"/fakeLaser/localizationClient"}
 
const std::string m_localization_device_defaultValue = {"localization2DClient"}
 
const std::string m_MAP_MODE_map_file_defaultValue = {""}
 
const std::string m_MAP_MODE_map_context_defaultValue = {""}
 
const std::string m_clip_max_defaultValue = {"3.5"}
 
const std::string m_clip_min_defaultValue = {"0.1"}
 
const std::string m_GENERAL_period_defaultValue = {"0.02"}
 
const std::string m_CONSTANT_MODE_const_distance_defaultValue = {"1"}
 
std::string m_test = {"use_pattern"}
 
std::string m_localization_port = {"/fakeLaser/location:i"}
 
std::string m_localization_server = {"/localizationServer"}
 
std::string m_localization_client = {"/fakeLaser/localizationClient"}
 
std::string m_localization_device = {"localization2DClient"}
 
std::string m_MAP_MODE_map_file = {}
 
std::string m_MAP_MODE_map_context = {}
 
double m_clip_max = {3.5}
 
double m_clip_min = {0.1}
 
double m_GENERAL_period = {0.02}
 
double m_CONSTANT_MODE_const_distance = {1}
 

Detailed Description

This class is the parameters parser for class FakeLaserWithMotor.

These are the used parameters:

Group name Parameter name Type Units Default Value Required Description Notes
- test string - use_pattern 1 Choose the modality It can be one of the following: no_obstacles, use_pattern, use_mapfile, use_constant, use_square_trap
- localization_port string - /fakeLaser/location:i 0 Full name of the port to which device connects to receive the localization data -
- localization_server string - /localizationServer 0 Full name of the port to which device connects to receive the localization data -
- localization_client string - /fakeLaser/localizationClient 0 Full name of the local transformClient opened by the device It cannot be used togheter if localization_port parameter is set
- localization_device string - localization2DClient 0 Type of localization device, e.g. localization2DClient, localization2D_nwc_yarp It cannot be used togheter if localization_port parameter is set
MAP_MODE map_file string - - 0 Full path to a .map file Mandatory if –test use_mapfile option has been set
MAP_MODE map_context string - - 0 Full path to a .map file Mandatory if –test use_mapfile option has been set
- clip_max double m 3.5 0 Maximum detectable distance for an obstacle -
- clip_min double m 0.1 0 Minimum detectable distance for an obstacle -
GENERAL period double s 0.02 0 Thread period -
CONSTANT_MODE const_distance double m 1 0 Default const distance for mode use_constant -

The device can be launched by yarpdev using one of the following examples (with and without all optional parameters):

yarpdev --device fakeLaserWithMotor --test use_pattern --localization_port /fakeLaser/location:i --localization_server /localizationServer --localization_client /fakeLaser/localizationClient --localization_device localization2DClient --MAP_MODE::map_file <optional_value> --MAP_MODE::map_context <optional_value> --clip_max 3.5 --clip_min 0.1 --GENERAL::period 0.02 --CONSTANT_MODE::const_distance 1
yarpdev --device fakeLaserWithMotor --test use_pattern

Definition at line 51 of file FakeLaserWithMotor_ParamsParser.h.

Constructor & Destructor Documentation

◆ FakeLaserWithMotor_ParamsParser()

FakeLaserWithMotor_ParamsParser::FakeLaserWithMotor_ParamsParser ( )

Definition at line 23 of file FakeLaserWithMotor_ParamsParser.cpp.

◆ ~FakeLaserWithMotor_ParamsParser()

FakeLaserWithMotor_ParamsParser::~FakeLaserWithMotor_ParamsParser ( )
overridedefault

Member Function Documentation

◆ getDeviceClassName()

std::string FakeLaserWithMotor_ParamsParser::getDeviceClassName ( ) const
inlineoverridevirtual

Get the name of the DeviceDriver class.

Returns
A string containing the name of the class.

Implements yarp::dev::IDeviceDriverParams.

Definition at line 93 of file FakeLaserWithMotor_ParamsParser.h.

◆ getDeviceName()

std::string FakeLaserWithMotor_ParamsParser::getDeviceName ( ) const
inlineoverridevirtual

Get the name of the device (i.e.

the plugin name).

Returns
A string containing the name of the device.

Implements yarp::dev::IDeviceDriverParams.

Definition at line 94 of file FakeLaserWithMotor_ParamsParser.h.

◆ getDocumentationOfDeviceParams()

std::string FakeLaserWithMotor_ParamsParser::getDocumentationOfDeviceParams ( ) const
overridevirtual

Get the documentation of the DeviceDriver's parameters.

Returns
A string containing the documentation.

Implements yarp::dev::IDeviceDriverParams.

Definition at line 249 of file FakeLaserWithMotor_ParamsParser.cpp.

◆ getListOfParams()

std::vector< std::string > FakeLaserWithMotor_ParamsParser::getListOfParams ( ) const
overridevirtual

Return a list of all params used by the device.

Returns
A vector containing the names of parameters used by the device.

Implements yarp::dev::IDeviceDriverParams.

Definition at line 28 of file FakeLaserWithMotor_ParamsParser.cpp.

◆ parseParams()

bool FakeLaserWithMotor_ParamsParser::parseParams ( const yarp::os::Searchable config)
overridevirtual

Parse the DeviceDriver parameters.

Returns
true if the parsing is successful, false otherwise

Implements yarp::dev::IDeviceDriverParams.

Definition at line 46 of file FakeLaserWithMotor_ParamsParser.cpp.

Member Data Documentation

◆ m_clip_max

double FakeLaserWithMotor_ParamsParser::m_clip_max = {3.5}

Definition at line 87 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_clip_max_defaultValue

const std::string FakeLaserWithMotor_ParamsParser::m_clip_max_defaultValue = {"3.5"}

Definition at line 75 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_clip_min

double FakeLaserWithMotor_ParamsParser::m_clip_min = {0.1}

Definition at line 88 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_clip_min_defaultValue

const std::string FakeLaserWithMotor_ParamsParser::m_clip_min_defaultValue = {"0.1"}

Definition at line 76 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_CONSTANT_MODE_const_distance

double FakeLaserWithMotor_ParamsParser::m_CONSTANT_MODE_const_distance = {1}

Definition at line 90 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_CONSTANT_MODE_const_distance_defaultValue

const std::string FakeLaserWithMotor_ParamsParser::m_CONSTANT_MODE_const_distance_defaultValue = {"1"}

Definition at line 78 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_device_classname

const std::string FakeLaserWithMotor_ParamsParser::m_device_classname = {"FakeLaserWithMotor"}

Definition at line 58 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_device_name

const std::string FakeLaserWithMotor_ParamsParser::m_device_name = {"fakeLaserWithMotor"}

Definition at line 59 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_GENERAL_period

double FakeLaserWithMotor_ParamsParser::m_GENERAL_period = {0.02}

Definition at line 89 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_GENERAL_period_defaultValue

const std::string FakeLaserWithMotor_ParamsParser::m_GENERAL_period_defaultValue = {"0.02"}

Definition at line 77 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_localization_client

std::string FakeLaserWithMotor_ParamsParser::m_localization_client = {"/fakeLaser/localizationClient"}

Definition at line 83 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_localization_client_defaultValue

const std::string FakeLaserWithMotor_ParamsParser::m_localization_client_defaultValue = {"/fakeLaser/localizationClient"}

Definition at line 71 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_localization_device

std::string FakeLaserWithMotor_ParamsParser::m_localization_device = {"localization2DClient"}

Definition at line 84 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_localization_device_defaultValue

const std::string FakeLaserWithMotor_ParamsParser::m_localization_device_defaultValue = {"localization2DClient"}

Definition at line 72 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_localization_port

std::string FakeLaserWithMotor_ParamsParser::m_localization_port = {"/fakeLaser/location:i"}

Definition at line 81 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_localization_port_defaultValue

const std::string FakeLaserWithMotor_ParamsParser::m_localization_port_defaultValue = {"/fakeLaser/location:i"}

Definition at line 69 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_localization_server

std::string FakeLaserWithMotor_ParamsParser::m_localization_server = {"/localizationServer"}

Definition at line 82 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_localization_server_defaultValue

const std::string FakeLaserWithMotor_ParamsParser::m_localization_server_defaultValue = {"/localizationServer"}

Definition at line 70 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_MAP_MODE_map_context

std::string FakeLaserWithMotor_ParamsParser::m_MAP_MODE_map_context = {}

Definition at line 86 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_MAP_MODE_map_context_defaultValue

const std::string FakeLaserWithMotor_ParamsParser::m_MAP_MODE_map_context_defaultValue = {""}

Definition at line 74 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_MAP_MODE_map_file

std::string FakeLaserWithMotor_ParamsParser::m_MAP_MODE_map_file = {}

Definition at line 85 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_MAP_MODE_map_file_defaultValue

const std::string FakeLaserWithMotor_ParamsParser::m_MAP_MODE_map_file_defaultValue = {""}

Definition at line 73 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_parser_is_strict

bool FakeLaserWithMotor_ParamsParser::m_parser_is_strict = false

Definition at line 60 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_parser_version

const parser_version_type FakeLaserWithMotor_ParamsParser::m_parser_version = {}

Definition at line 66 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_test

std::string FakeLaserWithMotor_ParamsParser::m_test = {"use_pattern"}

Definition at line 80 of file FakeLaserWithMotor_ParamsParser.h.

◆ m_test_defaultValue

const std::string FakeLaserWithMotor_ParamsParser::m_test_defaultValue = {"use_pattern"}

Definition at line 68 of file FakeLaserWithMotor_ParamsParser.h.


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