10 #ifndef YARP_OS_SEARCHABLE_H
11 #define YARP_OS_SEARCHABLE_H
18 #ifndef YARP_NO_DEPRECATED
19 #define YARP_INCLUDING_DEPRECATED_HEADER_ON_PURPOSE
21 #undef YARP_INCLUDING_DEPRECATED_HEADER_ON_PURPOSE
35 #ifndef DOXYGEN_SHOULD_SKIP_THIS
47 explicit SearchReport();
53 virtual ~SearchMonitor();
54 virtual void report(
const SearchReport& report,
const char* context) = 0;
71 SearchMonitor* monitor;
111 virtual bool check(
const std::string& key)
const = 0;
121 virtual bool check(
const std::string& key,
122 const std::string& comment)
const;
157 Bottle&
findGroup(
const std::string& key,
const std::string& comment)
const;
184 virtual bool check(
const std::string& key,
186 const std::string& comment =
"")
const;
198 virtual Value check(
const std::string& key,
199 const Value& fallback,
200 const std::string& comment =
"")
const;
206 virtual bool isNull()
const;
217 #ifndef DOXYGEN_SHOULD_SKIP_THIS
218 virtual void setMonitor(SearchMonitor* monitor,
const char* context =
"");
219 virtual SearchMonitor* getMonitor()
const;
220 virtual std::string getMonitorContext()
const;
221 virtual void reportToMonitor(
const SearchReport& report)
const;
A simple collection of objects that can be described and transmitted in a portable way.
A base class for nested structures that can be searched.
virtual Value & find(const std::string &key) const =0
Gets a value corresponding to a given keyword.
Searchable(const Searchable &rhs)=default
Copy constructor.
Searchable(Searchable &&rhs) noexcept=default
Move constructor.
Searchable & operator=(const Searchable &rhs)=default
Copy assignment operator.
virtual ~Searchable()
Destructor.
virtual bool check(const std::string &key) const =0
Check if there exists a property of the given name.
virtual std::string toString() const =0
Return a standard text representation of the content of the object.
virtual Bottle & findGroup(const std::string &key) const =0
Gets a list corresponding to a given keyword.
Searchable & operator=(Searchable &&rhs) noexcept=default
Move assignment operator.
A single value (typically within a Bottle).
std::string findGroup(const robotinterface::experimental::ParamList &list, const std::string &name)
The main, catch-all namespace for YARP.
#define YARP_SUPPRESS_DLL_INTERFACE_WARNING_ARG(x)
Suppress MSVC C4251 warning for the declaration.