19 #ifndef __ICUBCLIENT_ENTITY_H__ 20 #define __ICUBCLIENT_ENTITY_H__ 22 #include <yarp/os/all.h> 48 std::map<std::string, std::string > m_properties;
51 yarp::os::Bottle m_original_entity;
52 yarp::os::Bottle asBottleOnlyModifiedProperties()
const;
61 Entity(yarp::os::Bottle &b);
67 virtual bool isType(std::string _entityType)
const 76 virtual yarp::os::Bottle
asBottle()
const;
82 virtual bool fromBottle(
const yarp::os::Bottle &b);
87 virtual std::string
toString()
const;
94 return m_name.c_str();
110 if (m_properties.find(p)!=m_properties.end()) {
111 return m_properties.find(p)->second;
int opc_id() const
Return the id of an entity (which has to be unique within the OPC) Typically, modules should employ t...
virtual bool fromBottle(const yarp::os::Bottle &b)
Fill entity fields from a bottle representation.
Represent any entity that can be stored within the OPC.
virtual bool isType(std::string _entityType) const
Test if an entity is inheriting a given type.
std::string properties(const std::string &p) const
Returns the name of an entity contained in a property, returns the string "NULL" if property is not s...
void changeName(std::string sName)
bool operator==(const Entity &b) const
An OPC client using the datastructures defined within the icub-client library.
virtual std::string toString() const
Return a human readable description of the entity.
std::string name() const
Return the name of an entity (which has to be unique within the OPC)
virtual yarp::os::Bottle asBottle() const
Return the entity as a bottle.
bool operator<(const Entity &b) const
std::string m_entity_type
std::string entity_type() const
Return the specific type of an entity.
bool operator>(const Entity &b) const