Map2D_nwc_yarp
: A device which allows a client application to store/retrieve user maps device in a map server.
More...
#include <networkWrappers/map2D_nwc_yarp/Map2D_nwc_yarp.h>
Public Member Functions | |
bool | open (yarp::os::Searchable &config) override |
Open the DeviceDriver. | |
bool | close () override |
Close the DeviceDriver. | |
yarp::dev::ReturnValue | clearAllMaps () override |
Removes all the registered maps from the server. | |
yarp::dev::ReturnValue | remove_map (std::string map_name) override |
Removes a map from the map server. | |
yarp::dev::ReturnValue | store_map (const yarp::dev::Nav2D::MapGrid2D &map) override |
Stores a map into the map server. | |
yarp::dev::ReturnValue | get_map (std::string map_name, yarp::dev::Nav2D::MapGrid2D &map) override |
Gets a map from the map server. | |
yarp::dev::ReturnValue | get_map_names (std::vector< std::string > &map_names) override |
Gets a list containing the names of all registered maps. | |
yarp::dev::ReturnValue | storeLocation (std::string location_name, yarp::dev::Nav2D::Map2DLocation loc) override |
Store a location specified by the user in the world reference frame. | |
yarp::dev::ReturnValue | storeArea (std::string area_name, yarp::dev::Nav2D::Map2DArea area) override |
Store an area. | |
yarp::dev::ReturnValue | storePath (std::string path_name, yarp::dev::Nav2D::Map2DPath path) override |
Store a path. | |
yarp::dev::ReturnValue | getLocation (std::string location_name, yarp::dev::Nav2D::Map2DLocation &loc) override |
Retrieves a location specified by the user in the world reference frame. | |
yarp::dev::ReturnValue | getArea (std::string location_name, yarp::dev::Nav2D::Map2DArea &area) override |
Retrieves an area. | |
yarp::dev::ReturnValue | getPath (std::string path_name, yarp::dev::Nav2D::Map2DPath &path) override |
Retrieves a path. | |
yarp::dev::ReturnValue | renameLocation (std::string original_name, std::string new_name) override |
Searches for a location and renames it. | |
yarp::dev::ReturnValue | renameArea (std::string original_name, std::string new_name) override |
Searches for an area and renames it. | |
yarp::dev::ReturnValue | renamePath (std::string original_name, std::string new_name) override |
Searches for a path and renames it. | |
yarp::dev::ReturnValue | deleteLocation (std::string location_name) override |
Delete a location. | |
yarp::dev::ReturnValue | deleteArea (std::string location_name) override |
Delete an area. | |
yarp::dev::ReturnValue | deletePath (std::string path_name) override |
Delete a path. | |
yarp::dev::ReturnValue | getLocationsList (std::vector< std::string > &locations) override |
Get a list of the names of all stored locations. | |
yarp::dev::ReturnValue | getAreasList (std::vector< std::string > &locations) override |
Get a list of the names of all stored areas. | |
yarp::dev::ReturnValue | getPathsList (std::vector< std::string > &paths) override |
Get a list of the names of all stored paths. | |
yarp::dev::ReturnValue | getAllLocations (std::vector< yarp::dev::Nav2D::Map2DLocation > &locations) override |
Get a list of all stored locations. | |
yarp::dev::ReturnValue | getAllAreas (std::vector< yarp::dev::Nav2D::Map2DArea > &areas) override |
Get a list of all stored areas. | |
yarp::dev::ReturnValue | getAllPaths (std::vector< yarp::dev::Nav2D::Map2DPath > &paths) override |
Get a list of all stored paths. | |
yarp::dev::ReturnValue | clearAllLocations () override |
Delete all stored locations. | |
yarp::dev::ReturnValue | clearAllAreas () override |
Delete all stored areas. | |
yarp::dev::ReturnValue | clearAllPaths () override |
Delete all stored paths. | |
yarp::dev::ReturnValue | clearAllMapsTemporaryFlags () override |
Clear all temporary flags from all stored maps. | |
yarp::dev::ReturnValue | clearMapTemporaryFlags (std::string map_name) override |
Clear all temporary flags from a specific map. | |
yarp::dev::ReturnValue | saveMapsCollection (std::string maps_collection_file) override |
Save a collection of maps to disk. | |
yarp::dev::ReturnValue | loadMapsCollection (std::string maps_collection_file) override |
Load a collection of maps from disk. | |
yarp::dev::ReturnValue | saveLocationsAndExtras (std::string locations_collection_file) override |
Save a collection of locations/area/paths etc to disk. | |
yarp::dev::ReturnValue | loadLocationsAndExtras (std::string locations_collection_file) override |
Load a collection of locations/areas/paths etc from disk. | |
yarp::dev::ReturnValue | saveMapToDisk (std::string map_name, std::string file_name) override |
Save a map to disk. | |
yarp::dev::ReturnValue | loadMapFromDisk (std::string file_name) override |
Load a map from disk. | |
yarp::dev::ReturnValue | enableMapsCompression (bool enable) override |
Enable/disables maps compression over the network. | |
![]() | |
DeviceDriver () | |
DeviceDriver (const DeviceDriver &other)=delete | |
DeviceDriver (DeviceDriver &&other) noexcept=delete | |
DeviceDriver & | operator= (const DeviceDriver &other)=delete |
DeviceDriver & | operator= (DeviceDriver &&other) noexcept=delete |
virtual | ~DeviceDriver () |
virtual std::string | id () const |
Return the id assigned to the PolyDriver. | |
virtual void | setId (const std::string &id) |
Set the id for this device. | |
template<class T > | |
bool | view (T *&x) |
Get an interface to the device driver. | |
virtual DeviceDriver * | getImplementation () |
Some drivers are bureaucrats, pointing at others. | |
![]() | |
virtual | ~IMap2D () |
Destructor. | |
![]() | |
Map2D_nwc_yarp_ParamsParser () | |
~Map2D_nwc_yarp_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. | |
bool | getParamValue (const std::string ¶mName, std::string ¶mValue) const override |
Return the value (represented as a string) of the requested parameter. | |
std::string | getConfiguration () const override |
Return the configuration of the device. | |
![]() | |
virtual | ~IDeviceDriverParams () |
Protected Attributes | |
yarp::os::Port | m_rpcPort_to_Map2D_nws |
IMap2DMsgs | m_map_RPC |
std::mutex | m_mutex |
Additional Inherited Members | |
![]() | |
const std::string | m_device_classname = {"Map2D_nwc_yarp"} |
const std::string | m_device_name = {"map2D_nwc_yarp"} |
bool | m_parser_is_strict = false |
const parser_version_type | m_parser_version = {} |
std::string | m_provided_configuration |
const std::string | m_local_defaultValue = {""} |
const std::string | m_remote_defaultValue = {""} |
const std::string | m_carrier_defaultValue = {"fast_tcp"} |
std::string | m_local = {} |
std::string | m_remote = {} |
std::string | m_carrier = {"fast_tcp"} |
Map2D_nwc_yarp
: A device which allows a client application to store/retrieve user maps device in a map server.
Parameters required by this device are shown in class: Map2D_nwc_yarp_ParamsParser
Definition at line 35 of file Map2D_nwc_yarp.h.
|
overridevirtual |
Delete all stored areas.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 281 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Delete all stored locations.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 275 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Removes all the registered maps from the server.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 79 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Clear all temporary flags from all stored maps.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 287 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Delete all stored paths.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 299 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Clear all temporary flags from a specific map.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 293 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Close the DeviceDriver.
Reimplemented from yarp::dev::DeviceDriver.
Definition at line 305 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Delete an area.
area_name | the name of the area |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 251 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Delete a location.
location_name | the name of the location |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 239 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Delete a path.
path_name | the name of the path |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 257 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Enable/disables maps compression over the network.
enable |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 346 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Gets a map from the map server.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 66 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Gets a list containing the names of all registered maps.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 85 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Get a list of all stored areas.
the | returned list of areas |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 174 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Get a list of all stored locations.
the | returned list of locations |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 161 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Get a list of all stored paths.
the | returned list of paths |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 187 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Retrieves an area.
area_name | the name of the area |
area | the area |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 213 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Get a list of the names of all stored areas.
the | returned list of areas names |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 135 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Retrieves a location specified by the user in the world reference frame.
location_name | the name of the location |
loc | the location |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 200 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Get a list of the names of all stored locations.
the | returned list of locations names |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 122 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Retrieves a path.
path_name | the name of the path |
path | the path |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 226 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Get a list of the names of all stored paths.
the | returned list of paths names |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 148 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Load a collection of locations/areas/paths etc from disk.
file_name | file name with full path |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 328 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Load a map from disk.
file_name | file name with full path |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 340 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Load a collection of maps from disk.
file_name | file name with full path |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 316 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Open the DeviceDriver.
config | is a list of parameters for the device. Which parameters are effective for your device can vary. See device invocation examples. If there is no example for your device, you can run the "yarpdev" program with the verbose flag set to probe what parameters the device is checking. If that fails too, you'll need to read the source code (please nag one of the yarp developers to add documentation for your device). |
Reimplemented from yarp::dev::DeviceDriver.
Definition at line 27 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Removes a map from the map server.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 98 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Searches for an area and renames it.
original_name | the name of the area |
new_name | the new name of the area |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 263 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Searches for a location and renames it.
original_name | the name of the area |
new_name | the new name of the area |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 245 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Searches for a path and renames it.
original_name | the name of the path |
new_name | the new name of the path |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 269 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Save a collection of locations/area/paths etc to disk.
file_name | file name with full path |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 322 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Save a collection of maps to disk.
file_name | file name with full path |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 310 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Save a map to disk.
map_name | the name of the area |
file_name | file name with full path |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 334 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Stores a map into the map server.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 60 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Store an area.
area_name | the name of the area |
area | the area |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 110 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Store a location specified by the user in the world reference frame.
location_name | the name of the location |
loc | the location of the robot |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 104 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Store a path.
path_name | the name of the path |
path | the path |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 116 of file Map2D_nwc_yarp.cpp.
|
protected |
Definition at line 42 of file Map2D_nwc_yarp.h.
|
protected |
Definition at line 43 of file Map2D_nwc_yarp.h.
|
protected |
Definition at line 41 of file Map2D_nwc_yarp.h.