|
|
AbstractEntityWrapper is a superclass for all covenience classes, which provide typed access to entity attributes. More...
#include <MemoryX/core/entity/AbstractEntityWrapper.h>
Inheritance diagram for AbstractEntityWrapper:Public Member Functions | |
| AbstractEntityWrapper () | |
| EntityBasePtr | getEntity () const |
| Get the stored name of the stored entity. | |
| std::string | getId () const |
| Get the identifier of the stored entity. | |
| std::string | getName () const |
| Get the name of the stored entity. | |
| void | setEntity (const EntityBasePtr &entity) |
| Replace the stored entity with a new one. | |
| ~AbstractEntityWrapper () override | |
AbstractEntityWrapper is a superclass for all covenience classes, which provide typed access to entity attributes.
See memoryx::EntityWrappers::SimoxObjectWrapper for sample implementation.
Apart of convenience, such wrapper classes give a maintance advantage, since they encapsulate all the implementation details (attribute names, storing formats), avoiding the need to duplicate them in multiple places in client code. So it's recommended to use this approach whenever possible.
|
override |
| EntityBasePtr getEntity | ( | ) | const |
Get the stored name of the stored entity.
| std::string getId | ( | ) | const |
Get the identifier of the stored entity.
| std::string getName | ( | ) | const |
Get the name of the stored entity.
| void setEntity | ( | const EntityBasePtr & | entity | ) |
Replace the stored entity with a new one.
| entity | entity to set |