Reader Class Reference

#include <armarx/navigation/memory/client/graph/Reader.h>

+ Inheritance diagram for Reader:

Public Member Functions

void connect (armarx::armem::client::MemoryNameSystem &mns) override
 
Properties defaultProperties () const override
 
std::vector< armarx::navigation::core::Graphgraphs ()
 
std::map< std::string, core::Locationlocations ()
 
std::string propertyPrefix () const override
 
core::Location resolveLocationId (const std::string &locationId)
 
ResolveLocationNameResult resolveLocationName (const std::string &locationName, double minMatchRatio, std::ostream *log=nullptr)
 Resolve a location by human-readable name. More...
 
- Public Member Functions inherited from SimpleReaderBase
const Propertiesproperties () const
 
void registerPropertyDefinitions (armarx::PropertyDefinitionsPtr &def)
 
void setProperties (const Properties &p)
 
 SimpleReaderBase ()
 
virtual ~SimpleReaderBase ()=default
 

Static Public Member Functions

static ResolveLocationNameResult ResolveLocationName (const std::map< armem::MemoryID, location::arondto::Location > &locations, const std::string &locationName, double minMatchRatio, std::ostream *log=nullptr)
 Resolve a location by human-readable name. More...
 

Protected Member Functions

armem::wm::CoreSegment allGraphs ()
 
armem::wm::CoreSegment allLocations ()
 
std::map< armem::MemoryID, location::arondto::Location > queryLocations ()
 
- Protected Member Functions inherited from SimpleReaderBase
const armem::client::ReadermemoryReader () const
 

Detailed Description

Definition at line 46 of file Reader.h.

Member Function Documentation

◆ allGraphs()

armem::wm::CoreSegment allGraphs ( )
protected

Definition at line 123 of file Reader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ allLocations()

armem::wm::CoreSegment allLocations ( )
protected

Definition at line 93 of file Reader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ connect()

void connect ( armarx::armem::client::MemoryNameSystem mns)
overridevirtual

Reimplemented from SimpleReaderBase.

Definition at line 264 of file Reader.cpp.

+ Here is the call graph for this function:

◆ defaultProperties()

Reader::Properties defaultProperties ( ) const
overridevirtual

Implements SimpleReaderBase.

Definition at line 32 of file Reader.cpp.

◆ graphs()

std::vector< armarx::navigation::core::Graph > graphs ( )

Definition at line 61 of file Reader.cpp.

+ Here is the call graph for this function:

◆ locations()

std::map< std::string, core::Location > locations ( )

Definition at line 39 of file Reader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ propertyPrefix()

std::string propertyPrefix ( ) const
overridevirtual

Implements SimpleReaderBase.

Definition at line 26 of file Reader.cpp.

◆ queryLocations()

std::map< armem::MemoryID, location::arondto::Location > queryLocations ( )
protected

Definition at line 153 of file Reader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ resolveLocationId()

core::Location resolveLocationId ( const std::string &  locationId)

Definition at line 193 of file Reader.cpp.

+ Here is the call graph for this function:

◆ ResolveLocationName()

ResolveLocationNameResult ResolveLocationName ( const std::map< armem::MemoryID, location::arondto::Location > &  locations,
const std::string &  locationName,
double  minMatchRatio,
std::ostream *  log = nullptr 
)
static

Resolve a location by human-readable name.

Matches the given name to the locations' names, and returns the ID of the location with the best match.

Parameters
locationsLocations, e.g. as returned by Reader::queryLocations().
locationNameThe human-readable name.
minMatchRatioThe minimum match ratio required to accept a match.
logOptional out-stream for logging about the matching.
Returns
Resolved location name or error message.

Definition at line 209 of file Reader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ resolveLocationName()

ResolveLocationNameResult resolveLocationName ( const std::string &  locationName,
double  minMatchRatio,
std::ostream *  log = nullptr 
)

Resolve a location by human-readable name.

Queries location names from the navigation memory, matches the given name to the locations' names, and returns the ID of the location with the best match.

Parameters
locationNameThe human-readable name.
minMatchRatioThe minimum match ratio required to accept a match.
logOptional out-stream for logging about the matching.
Returns
Resolved location name or error message.

Definition at line 200 of file Reader.cpp.

+ Here is the call graph for this function:

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