18#define DEFAULT_THREAD_PERIOD 0.01
21#define M_PI 3.14159265358979323846
28#define CHECK_POINTER(xxx) {if (xxx==nullptr) {yCError(MAP2D_RPC, "Invalid interface"); return false;}}
32 std::lock_guard <std::mutex>
lg(m_mutex);
44 std::lock_guard <std::mutex>
lg(m_mutex);
56 std::lock_guard <std::mutex>
lg(m_mutex);
74 std::lock_guard <std::mutex>
lg(m_mutex);
77 std::vector<string> map_names;
85 ret.map_names = map_names;
92 std::lock_guard <std::mutex>
lg(m_mutex);
104 std::lock_guard <std::mutex>
lg(m_mutex);
116 std::lock_guard <std::mutex>
lg(m_mutex);
128 std::lock_guard <std::mutex>
lg(m_mutex);
140 std::lock_guard <std::mutex>
lg(m_mutex);
152 std::lock_guard <std::mutex>
lg(m_mutex);
164 std::lock_guard <std::mutex>
lg(m_mutex);
176 std::lock_guard <std::mutex>
lg(m_mutex);
188 std::lock_guard <std::mutex>
lg(m_mutex);
200 std::lock_guard <std::mutex>
lg(m_mutex);
212 std::lock_guard <std::mutex>
lg(m_mutex);
224 std::lock_guard <std::mutex>
lg(m_mutex);
236 std::lock_guard <std::mutex>
lg(m_mutex);
248 std::lock_guard <std::mutex>
lg(m_mutex);
260 std::lock_guard <std::mutex>
lg(m_mutex);
272 std::lock_guard <std::mutex>
lg(m_mutex);
284 std::lock_guard <std::mutex>
lg(m_mutex);
296 std::lock_guard <std::mutex>
lg(m_mutex);
308 std::lock_guard <std::mutex>
lg(m_mutex);
320 std::lock_guard <std::mutex>
lg(m_mutex);
339 std::lock_guard <std::mutex>
lg(m_mutex);
344 ret.retval = m_iMap->
getArea(area_name, area);
358 std::lock_guard <std::mutex>
lg(m_mutex);
362 ret.retval = m_iMap->
getPath(path_name, path);
376 std::lock_guard <std::mutex>
lg(m_mutex);
394 std::lock_guard <std::mutex>
lg(m_mutex);
412 std::lock_guard <std::mutex>
lg(m_mutex);
return_get_map_names get_map_names_RPC() override
yarp::dev::ReturnValue clear_all_areas_RPC() override
yarp::dev::ReturnValue rename_path_RPC(const std::string &original_name, const std::string &new_name) override
return_get_path get_path_RPC(const std::string &path_name) override
yarp::dev::ReturnValue store_area_RPC(const std::string &area_name, const yarp::dev::Nav2D::Map2DArea &area) override
yarp::dev::ReturnValue load_locations_and_extras_RPC(const std::string &locations_collection_file) override
yarp::dev::ReturnValue store_map_RPC(const yarp::dev::Nav2D::MapGrid2D &themap) override
yarp::dev::ReturnValue save_locations_and_extras_RPC(const std::string &locations_collection_file) override
yarp::dev::ReturnValue rename_area_RPC(const std::string &original_name, const std::string &new_name) override
yarp::dev::ReturnValue rename_location_RPC(const std::string &original_name, const std::string &new_name) override
yarp::dev::ReturnValue save_maps_collection_RPC(const std::string &maps_collection_file) override
yarp::dev::ReturnValue delete_area_RPC(const std::string &area_name) override
return_get_location get_location_RPC(const std::string &location_name) override
yarp::dev::ReturnValue delete_path_RPC(const std::string &path_name) override
return_get_areas_list get_areas_list_RPC() override
yarp::dev::ReturnValue clear_map_temporary_flags_RPC(const std::string &map_name) override
yarp::dev::ReturnValue store_path_RPC(const std::string &path_name, const yarp::dev::Nav2D::Map2DPath &path) override
yarp::dev::ReturnValue clear_all_maps_temporary_flags_RPC() override
return_get_paths_list get_paths_list_RPC() override
return_get_locations_list get_locations_list_RPC() override
return_get_area get_area_RPC(const std::string &area_name) override
yarp::dev::ReturnValue clear_all_locations_RPC() override
yarp::dev::ReturnValue clear_all_paths_RPC() override
yarp::dev::ReturnValue clear_all_maps_RPC() override
return_get_map get_map_RPC(const std::string &map_name) override
yarp::dev::ReturnValue store_location_RPC(const std::string &location_name, const yarp::dev::Nav2D::Map2DLocation &loc) override
yarp::dev::ReturnValue remove_map_RPC(const std::string &map_name) override
yarp::dev::ReturnValue load_maps_collection_RPC(const std::string &maps_collection_file) override
yarp::dev::ReturnValue delete_location_RPC(const std::string &location_name) override
virtual yarp::dev::ReturnValue storeLocation(std::string location_name, yarp::dev::Nav2D::Map2DLocation loc)=0
Store a location specified by the user in the world reference frame.
virtual yarp::dev::ReturnValue storePath(std::string path_name, yarp::dev::Nav2D::Map2DPath path)=0
Store a path.
virtual yarp::dev::ReturnValue deleteLocation(std::string location_name)=0
Delete a location.
virtual yarp::dev::ReturnValue get_map_names(std::vector< std::string > &map_names)=0
Gets a list containing the names of all registered maps.
virtual yarp::dev::ReturnValue loadMapsCollection(std::string file_name)=0
Load a collection of maps from disk.
virtual yarp::dev::ReturnValue saveMapsCollection(std::string file_name)=0
Save a collection of maps to disk.
virtual yarp::dev::ReturnValue getPath(std::string path_name, yarp::dev::Nav2D::Map2DPath &path)=0
Retrieves a path.
virtual yarp::dev::ReturnValue renamePath(std::string original_name, std::string new_name)=0
Searches for a path and renames it.
virtual yarp::dev::ReturnValue saveLocationsAndExtras(std::string file_name)=0
Save a collection of locations/area/paths etc to disk.
virtual yarp::dev::ReturnValue deleteArea(std::string area_name)=0
Delete an area.
virtual yarp::dev::ReturnValue getLocationsList(std::vector< std::string > &locations)=0
Get a list of the names of all stored locations.
virtual yarp::dev::ReturnValue loadLocationsAndExtras(std::string file_name)=0
Load a collection of locations/areas/paths etc from disk.
virtual yarp::dev::ReturnValue store_map(const yarp::dev::Nav2D::MapGrid2D &map)=0
Stores a map into the map server.
virtual yarp::dev::ReturnValue clearAllMaps()=0
Removes all the registered maps from the server.
virtual yarp::dev::ReturnValue clearAllMapsTemporaryFlags()=0
Clear all temporary flags from all stored maps.
virtual yarp::dev::ReturnValue clearMapTemporaryFlags(std::string map_name)=0
Clear all temporary flags from a specific map.
virtual yarp::dev::ReturnValue clearAllAreas()=0
Delete all stored areas.
virtual yarp::dev::ReturnValue renameLocation(std::string original_name, std::string new_name)=0
Searches for a location and renames it.
virtual yarp::dev::ReturnValue get_map(std::string map_name, yarp::dev::Nav2D::MapGrid2D &map)=0
Gets a map from the map server.
virtual yarp::dev::ReturnValue getAreasList(std::vector< std::string > &areas)=0
Get a list of the names of all stored areas.
virtual yarp::dev::ReturnValue storeArea(std::string area_name, yarp::dev::Nav2D::Map2DArea area)=0
Store an area.
virtual yarp::dev::ReturnValue clearAllLocations()=0
Delete all stored locations.
virtual yarp::dev::ReturnValue getPathsList(std::vector< std::string > &paths)=0
Get a list of the names of all stored paths.
virtual yarp::dev::ReturnValue getArea(std::string area_name, yarp::dev::Nav2D::Map2DArea &area)=0
Retrieves an area.
virtual yarp::dev::ReturnValue deletePath(std::string path_name)=0
Delete a path.
virtual yarp::dev::ReturnValue remove_map(std::string map_name)=0
Removes a map from the map server.
virtual yarp::dev::ReturnValue renameArea(std::string original_name, std::string new_name)=0
Searches for an area and renames it.
virtual yarp::dev::ReturnValue getLocation(std::string location_name, yarp::dev::Nav2D::Map2DLocation &loc)=0
Retrieves a location specified by the user in the world reference frame.
virtual yarp::dev::ReturnValue clearAllPaths()=0
Delete all stored paths.
A mini-server for performing network communication in the background.
#define yCError(component,...)
#define YARP_LOG_COMPONENT(name,...)
For streams capable of holding different kinds of content, check what they actually have.
An interface to the operating system, including Port based communication.