Map2D_nwc_yarp
: A device which allows a client application to store/retrieve user maps device in a map server.
More...
#include <map2D_nwc_yarp/Map2D_nwc_yarp.h>
Public Member Functions | |
bool | open (yarp::os::Searchable &config) override |
Open the DeviceDriver. More... | |
bool | close () override |
Close the DeviceDriver. More... | |
bool | clearAllMaps () override |
Removes all the registered maps from the server. More... | |
bool | remove_map (std::string map_name) override |
Removes a map from the map server. More... | |
bool | store_map (const yarp::dev::Nav2D::MapGrid2D &map) override |
Stores a map into the map server. More... | |
bool | get_map (std::string map_name, yarp::dev::Nav2D::MapGrid2D &map) override |
Gets a map from the map server. More... | |
bool | get_map_names (std::vector< std::string > &map_names) override |
Gets a list containing the names of all registered maps. More... | |
bool | storeLocation (std::string location_name, yarp::dev::Nav2D::Map2DLocation loc) override |
Store a location specified by the user in the world reference frame. More... | |
bool | storeArea (std::string area_name, yarp::dev::Nav2D::Map2DArea area) override |
Store an area. More... | |
bool | storePath (std::string path_name, yarp::dev::Nav2D::Map2DPath path) override |
Store a path. More... | |
bool | getLocation (std::string location_name, yarp::dev::Nav2D::Map2DLocation &loc) override |
Retrieves a location specified by the user in the world reference frame. More... | |
bool | getArea (std::string location_name, yarp::dev::Nav2D::Map2DArea &area) override |
Retrieves an area. More... | |
bool | getPath (std::string path_name, yarp::dev::Nav2D::Map2DPath &path) override |
Retrieves a path. More... | |
bool | renameLocation (std::string original_name, std::string new_name) override |
Searches for a location and renames it. More... | |
bool | renameArea (std::string original_name, std::string new_name) override |
Searches for an area and renames it. More... | |
bool | renamePath (std::string original_name, std::string new_name) override |
Searches for a path and renames it. More... | |
bool | deleteLocation (std::string location_name) override |
Delete a location. More... | |
bool | deleteArea (std::string location_name) override |
Delete an area. More... | |
bool | deletePath (std::string path_name) override |
Delete a path. More... | |
bool | getLocationsList (std::vector< std::string > &locations) override |
Get a list of the names of all stored locations. More... | |
bool | getAreasList (std::vector< std::string > &locations) override |
Get a list of the names of all stored areas. More... | |
bool | getPathsList (std::vector< std::string > &paths) override |
Get a list of the names of all stored paths. More... | |
bool | getAllLocations (std::vector< yarp::dev::Nav2D::Map2DLocation > &locations) override |
Get a list of all stored locations. More... | |
bool | getAllAreas (std::vector< yarp::dev::Nav2D::Map2DArea > &areas) override |
Get a list of all stored areas. More... | |
bool | getAllPaths (std::vector< yarp::dev::Nav2D::Map2DPath > &paths) override |
Get a list of all stored paths. More... | |
bool | clearAllLocations () override |
Delete all stored locations. More... | |
bool | clearAllAreas () override |
Delete all stored areas. More... | |
bool | clearAllPaths () override |
Delete all stored paths. More... | |
bool | clearAllMapsTemporaryFlags () override |
Clear all temporary flags from all stored maps. More... | |
bool | clearMapTemporaryFlags (std::string map_name) override |
Clear all temporary flags from a specific map. More... | |
bool | saveMapsCollection (std::string maps_collection_file) override |
Save a collection of maps to disk. More... | |
bool | loadMapsCollection (std::string maps_collection_file) override |
Load a collection of maps from disk. More... | |
bool | saveLocationsAndExtras (std::string locations_collection_file) override |
Save a collection of locations/area/paths etc to disk. More... | |
bool | loadLocationsAndExtras (std::string locations_collection_file) override |
Load a collection of locations/areas/paths etc from disk. More... | |
bool | saveMapToDisk (std::string map_name, std::string file_name) override |
Save a map to disk. More... | |
bool | loadMapFromDisk (std::string file_name) override |
Load a map from disk. More... | |
bool | enableMapsCompression (bool enable) override |
99999999999 More... | |
![]() | |
DeviceDriver () | |
DeviceDriver (const DeviceDriver &other)=delete | |
DeviceDriver (DeviceDriver &&other) noexcept=delete | |
DeviceDriver & | operator= (const DeviceDriver &other)=delete |
DeviceDriver & | operator= (DeviceDriver &&other) noexcept=delete |
~DeviceDriver () override | |
bool | open (yarp::os::Searchable &config) override |
Open the DeviceDriver. More... | |
bool | close () override |
Close the DeviceDriver. More... | |
virtual std::string | id () const |
Return the id assigned to the PolyDriver. More... | |
virtual void | setId (const std::string &id) |
Set the id for this device. More... | |
template<class T > | |
bool | view (T *&x) |
Get an interface to the device driver. More... | |
virtual DeviceDriver * | getImplementation () |
Some drivers are bureaucrats, pointing at others. More... | |
![]() | |
virtual | ~IConfig () |
Destructor. More... | |
virtual bool | open (Searchable &config) |
Initialize the object. More... | |
virtual bool | close () |
Shut the object down. More... | |
virtual bool | configure (Searchable &config) |
Change online parameters. More... | |
![]() | |
virtual | ~IMap2D () |
Destructor. More... | |
virtual bool | clearAllMaps ()=0 |
Removes all the registered maps from the server. More... | |
virtual bool | store_map (const yarp::dev::Nav2D::MapGrid2D &map)=0 |
Stores a map into the map server. More... | |
virtual bool | get_map (std::string map_name, yarp::dev::Nav2D::MapGrid2D &map)=0 |
Gets a map from the map server. More... | |
virtual bool | get_map_names (std::vector< std::string > &map_names)=0 |
Gets a list containing the names of all registered maps. More... | |
virtual bool | remove_map (std::string map_name)=0 |
Removes a map from the map server. More... | |
virtual bool | storeLocation (std::string location_name, yarp::dev::Nav2D::Map2DLocation loc)=0 |
Store a location specified by the user in the world reference frame. More... | |
virtual bool | storeArea (std::string area_name, yarp::dev::Nav2D::Map2DArea area)=0 |
Store an area. More... | |
virtual bool | storePath (std::string path_name, yarp::dev::Nav2D::Map2DPath path)=0 |
Store a path. More... | |
virtual bool | getLocation (std::string location_name, yarp::dev::Nav2D::Map2DLocation &loc)=0 |
Retrieves a location specified by the user in the world reference frame. More... | |
virtual bool | getArea (std::string area_name, yarp::dev::Nav2D::Map2DArea &area)=0 |
Retrieves an area. More... | |
virtual bool | getPath (std::string path_name, yarp::dev::Nav2D::Map2DPath &path)=0 |
Retrieves a path. More... | |
virtual bool | getLocationsList (std::vector< std::string > &locations)=0 |
Get a list of the names of all stored locations. More... | |
virtual bool | getAreasList (std::vector< std::string > &areas)=0 |
Get a list of the names of all stored areas. More... | |
virtual bool | getPathsList (std::vector< std::string > &paths)=0 |
Get a list of the names of all stored paths. More... | |
virtual bool | getAllLocations (std::vector< yarp::dev::Nav2D::Map2DLocation > &locations)=0 |
Get a list of all stored locations. More... | |
virtual bool | getAllAreas (std::vector< yarp::dev::Nav2D::Map2DArea > &areas)=0 |
Get a list of all stored areas. More... | |
virtual bool | getAllPaths (std::vector< yarp::dev::Nav2D::Map2DPath > &paths)=0 |
Get a list of all stored paths. More... | |
virtual bool | renameLocation (std::string original_name, std::string new_name)=0 |
Searches for a location and renames it. More... | |
virtual bool | deleteLocation (std::string location_name)=0 |
Delete a location. More... | |
virtual bool | deletePath (std::string path_name)=0 |
Delete a path. More... | |
virtual bool | renameArea (std::string original_name, std::string new_name)=0 |
Searches for an area and renames it. More... | |
virtual bool | renamePath (std::string original_name, std::string new_name)=0 |
Searches for a path and renames it. More... | |
virtual bool | deleteArea (std::string area_name)=0 |
Delete an area. More... | |
virtual bool | clearAllLocations ()=0 |
Delete all stored locations. More... | |
virtual bool | clearAllAreas ()=0 |
Delete all stored areas. More... | |
virtual bool | clearAllPaths ()=0 |
Delete all stored paths. More... | |
virtual bool | clearAllMapsTemporaryFlags ()=0 |
Clear all temporary flags from all stored maps. More... | |
virtual bool | clearMapTemporaryFlags (std::string map_name)=0 |
Clear all temporary flags from a specific map. More... | |
virtual bool | saveMapToDisk (std::string map_name, std::string file_name)=0 |
Save a map to disk. More... | |
virtual bool | loadMapFromDisk (std::string file_name)=0 |
Load a map from disk. More... | |
virtual bool | saveMapsCollection (std::string file_name)=0 |
Save a collection of maps to disk. More... | |
virtual bool | loadMapsCollection (std::string file_name)=0 |
Load a collection of maps from disk. More... | |
virtual bool | saveLocationsAndExtras (std::string file_name)=0 |
Save a collection of locations/area/paths etc to disk. More... | |
virtual bool | loadLocationsAndExtras (std::string file_name)=0 |
Load a collection of locations/areas/paths etc from disk. More... | |
virtual bool | enableMapsCompression (bool enable)=0 |
99999999999 More... | |
Protected Attributes | |
yarp::os::Port | m_rpcPort_to_Map2D_nws |
std::string | m_local_name |
std::string | m_map_server |
std::string | m_carrier |
IMap2DMsgs | m_map_RPC |
std::mutex | m_mutex |
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:
Parameter name | SubParameter | Type | Units | Default Value | Required | Description | Notes |
---|---|---|---|---|---|---|---|
local | - | string | - | - | Yes | Full port name opened by the Map2D_nwc_yarp device. | |
remote | - | string | - | - | Yes | Full port name of the port remotely opened by the Map2D_nws_yarp, to which the Map2D_nwc_yarp connects to. | |
carrier | - | string | - | tcp | No | The carier used for the connection with the server. |
Definition at line 37 of file Map2D_nwc_yarp.h.
|
overridevirtual |
Delete all stored areas.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 297 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Delete all stored locations.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 291 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Removes all the registered maps from the server.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 95 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Clear all temporary flags from all stored maps.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 303 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Delete all stored paths.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 315 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Clear all temporary flags from a specific map.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 309 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Close the DeviceDriver.
Reimplemented from yarp::dev::DeviceDriver.
Definition at line 321 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 267 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 255 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 273 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
99999999999
enable |
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 362 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Gets a map from the map server.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 82 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 101 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 190 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 177 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 203 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 229 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 151 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 216 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 138 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 242 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 164 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 344 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 356 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 332 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 114 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 279 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 261 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 285 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 338 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 326 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 350 of file Map2D_nwc_yarp.cpp.
|
overridevirtual |
Stores a map into the map server.
Implements yarp::dev::Nav2D::IMap2D.
Definition at line 76 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 126 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 120 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 132 of file Map2D_nwc_yarp.cpp.
|
protected |
Definition at line 45 of file Map2D_nwc_yarp.h.
|
protected |
Definition at line 43 of file Map2D_nwc_yarp.h.
|
protected |
Definition at line 46 of file Map2D_nwc_yarp.h.
|
protected |
Definition at line 44 of file Map2D_nwc_yarp.h.
|
protected |
Definition at line 47 of file Map2D_nwc_yarp.h.
|
protected |
Definition at line 42 of file Map2D_nwc_yarp.h.