icub-client
Functions

A container library containing defines and structures to formalize knowledge within an objectPropertiesCollector module. More...

+ Collaboration diagram for Helper Routines:

Functions

yarp::os::Bottle icubclient::opcGetIdsFromAsk (const yarp::os::Bottle &reply)
 Allow retrieving the list of unique identifiers of those items verifying the set of conditions queried to the database through a [ask] request. More...
 
void icubclient::replace_all (std::string &in, const std::string &plain, const std::string &tok)
 Simple search and replace function for strings;. More...
 
std::string icubclient::grammarToString (const std::string &sPath)
 Get the context path of a .grxml grammar, and return it as a string. More...
 

Detailed Description

A container library containing defines and structures to formalize knowledge within an objectPropertiesCollector module.

Author
Ugo Pattacini & Stéphane Lallée

Function Documentation

◆ grammarToString()

std::string icubclient::grammarToString ( const std::string &  sPath)

Get the context path of a .grxml grammar, and return it as a string.

Parameters
sPathPath to the grammar file
Returns
Grammar as string

Definition at line 58 of file functions.cpp.

◆ opcGetIdsFromAsk()

yarp::os::Bottle icubclient::opcGetIdsFromAsk ( const yarp::os::Bottle &  reply)

Allow retrieving the list of unique identifiers of those items verifying the set of conditions queried to the database through a [ask] request.

Parameters
replythe bottle received from the database
Returns
the list of items identifiers as a Bottle

Definition at line 29 of file functions.cpp.

◆ replace_all()

void icubclient::replace_all ( std::string &  in,
const std::string &  plain,
const std::string &  tok 
)

Simple search and replace function for strings;.

Parameters
inthe input and output string
plainthe substring to be replaced
tokthe replacement

Definition at line 42 of file functions.cpp.