EnvironmentalPrimitiveSegment Class Reference

#include <MemoryX/libraries/memorytypes/segment/EnvironmentalPrimitiveSegment.h>

+ Inheritance diagram for EnvironmentalPrimitiveSegment:

Public Member Functions

 EnvironmentalPrimitiveSegment ()
 
BoxPrimitiveBasePtr getBoxById (const std::string &id, const ::Ice::Current &c=Ice::emptyCurrent) const override
 
BoxPrimitiveBaseList getBoxes (const ::Ice::Current &c=Ice::emptyCurrent) const override
 
BoxPrimitiveBaseList getBoxesByTimestamp (const armarx::TimestampBasePtr &timestamp, const ::Ice::Current &c=Ice::emptyCurrent) const override
 
CylinderPrimitiveBasePtr getCylinderById (const std::string &id, const ::Ice::Current &c=Ice::emptyCurrent) const override
 
CylinderPrimitiveBaseList getCylinders (const ::Ice::Current &c=Ice::emptyCurrent) const override
 
CylinderPrimitiveBaseList getCylindersByTimestamp (const armarx::TimestampBasePtr &timestamp, const ::Ice::Current &c=Ice::emptyCurrent) const override
 
EnvironmentalPrimitiveBasePtr getEnvironmentalPrimitiveById (const std::string &id, const ::Ice::Current &c=Ice::emptyCurrent) const override
 
EnvironmentalPrimitiveBaseList getEnvironmentalPrimitives (const ::Ice::Current &c=Ice::emptyCurrent) const override
 
EnvironmentalPrimitiveBaseList getEnvironmentalPrimitivesByTimestamp (const armarx::TimestampBasePtr &timestamp, const ::Ice::Current &c=Ice::emptyCurrent) const override
 
BoxPrimitiveBaseList getMostRecentBoxes (const ::Ice::Current &c=Ice::emptyCurrent) const override
 
CylinderPrimitiveBaseList getMostRecentCylinders (const ::Ice::Current &c=Ice::emptyCurrent) const override
 
EnvironmentalPrimitiveBaseList getMostRecentEnvironmentalPrimitives (const ::Ice::Current &c=Ice::emptyCurrent) const override
 
PlanePrimitiveBaseList getMostRecentPlanes (const ::Ice::Current &c=Ice::emptyCurrent) const override
 
SpherePrimitiveBaseList getMostRecentSpheres (const ::Ice::Current &c=Ice::emptyCurrent) const override
 
PlanePrimitiveBasePtr getPlaneById (const std::string &id, const ::Ice::Current &c=Ice::emptyCurrent) const override
 
PlanePrimitiveBaseList getPlanes (const ::Ice::Current &c=Ice::emptyCurrent) const override
 
PlanePrimitiveBaseList getPlanesByTimestamp (const armarx::TimestampBasePtr &timestamp, const ::Ice::Current &c=Ice::emptyCurrent) const override
 
SpherePrimitiveBasePtr getSphereById (const std::string &id, const ::Ice::Current &c=Ice::emptyCurrent) const override
 
SpherePrimitiveBaseList getSpheres (const ::Ice::Current &c=Ice::emptyCurrent) const override
 
SpherePrimitiveBaseList getSpheresByTimestamp (const armarx::TimestampBasePtr &timestamp, const ::Ice::Current &c=Ice::emptyCurrent) const override
 
void removeOlderPrimitives (const armarx::TimestampBasePtr &olderThan, const ::Ice::Current &c=Ice::emptyCurrent) override
 
void removePrimitivesByTimestamp (const armarx::TimestampBasePtr &timestamp, const ::Ice::Current &c=Ice::emptyCurrent) override
 
- Public Member Functions inherited from WorkingMemoryEntitySegment< EnvironmentalPrimitive >
std::string addEntity (const EntityBasePtr &entity, const ::Ice::Current &c=Ice::emptyCurrent) override
 addEntity addes an entity to this segment. The registered fusion methods are applied in order to fuse the entity entry. More...
 
EntityIdList addEntityList (const EntityBaseList &entityList, const ::Ice::Current &c) override
 
void addFusionMethod (const ::memoryx::EntityFusionMethodBasePtr &fusionMethod, const ::Ice::Current &c=Ice::emptyCurrent) override
 
void clear (const ::Ice::Current &c=Ice::emptyCurrent) override
 
EntityBaseList getAllEntities (const Ice::Current &c=Ice::emptyCurrent) const override
 
EntityIdList getAllEntityIds (const Ice::Current &c=Ice::emptyCurrent) const override
 
EntityBaseList getEntitiesByAttrValue (const ::std::string &attrName, const ::std::string &attrValue) const
 
EntityBaseList getEntitiesByAttrValue (const ::std::string &attrName, const ::std::string &attrValue, const ::Ice::Current &c) const override
 
EntityBaseList getEntitiesByAttrValueList (const ::std::string &attrName, const NameList &attrValueList) const
 
EntityBaseList getEntitiesByAttrValueList (const ::std::string &attrName, const NameList &attrValueList, const ::Ice::Current &c) const override
 
EntityBasePtr getEntityById (const ::std::string &id) const
 
EntityBasePtr getEntityById (const ::std::string &id, const ::Ice::Current &c) const override
 
EntityBasePtr getEntityByName (const ::std::string &name) const
 
EntityBasePtr getEntityByName (const ::std::string &name, const ::Ice::Current &c) const override
 
EntityRefBasePtr getEntityRefById (const std::string &id, const Ice::Current &c) const override
 
EntityRefBasePtr getEntityRefByName (const std::string &name, const Ice::Current &c) const override
 
Ice::Identity getIceId (const ::Ice::Current &c) const override
 
IdEntityMap getIdEntityMap (const Ice::Current &c=Ice::emptyCurrent) const override
 
WorkingMemoryListenerInterfacePrx getListenerProxy (const ::Ice::Current &c=Ice::emptyCurrent) override
 getListener The topic on which changes are reported. More...
 
std::string getObjectTypeId (const ::Ice::Current &c=Ice::emptyCurrent) const override
 getObjectTypeId returns the ice_staticId() of the entities stored inside this WorkingMemorySegment More...
 
std::string getSegmentName (const ::Ice::Current &c=Ice::emptyCurrent) const override
 
bool hasEntityById (const std::string &entityId, const ::Ice::Current &c) const override
 
bool hasEntityByName (const std::string &entityName, const ::Ice::Current &c) const override
 
void print (const ::Ice::Current &c=Ice::emptyCurrent) const override
 
void removeAllEntities (const ::Ice::Current &c=Ice::emptyCurrent) override
 
void removeEntity (const ::std::string &id, const ::Ice::Current &c=Ice::emptyCurrent) override
 
void setEntityAttribute (const std::string &entityId, const EntityAttributeBasePtr &attribute, const ::Ice::Current &c) override
 
void setEntityAttributes (const std::string &entityId, const EntityAttributeList &attributeMap, const ::Ice::Current &c) override
 
Ice::Int size (const ::Ice::Current &c=Ice::emptyCurrent) const override
 
void updateEntity (const std::string &entityId, const EntityBasePtr &update, const ::Ice::Current &c=Ice::emptyCurrent) override
 
void updateEntity (const std::string &entityId, const EntityBasePtr &update, const Ice::StringSeq &deactivatedFusionMethods, const ::Ice::Current &c=Ice::emptyCurrent)
 
std::string upsertEntity (const std::string &entityId, const EntityBasePtr &newEntity, const ::Ice::Current &c=Ice::emptyCurrent) override
 
std::string upsertEntityByName (const std::string &entityName, const EntityBasePtr &newEntity, const ::Ice::Current &c=Ice::emptyCurrent) override
 
EntityIdList upsertEntityList (const EntityBaseList &entityList, const ::Ice::Current &c) override
 
 WorkingMemoryEntitySegment ()
 
- Public Member Functions inherited from SegmentUtilImplementations
EntityBaseList getEntityWithChildrenById (const std::string &id, bool includeMetaEntities, const Ice::Current &c=Ice::emptyCurrent) const override
 
EntityBaseList getEntityWithChildrenByName (const std::string &, bool includeMetaEntities, const Ice::Current &c=Ice::emptyCurrent) const override
 
std::string getJSONEntityById (const std::string &id, const Ice::Current &) const override
 
ScopedSharedLockPtr getReadLock (const Ice::Current &c) const
 
ScopedUniqueLockPtr getWriteLock (const Ice::Current &c) const
 
bool keepLockAlive (const std::string &token, const Ice::Current &) override
 
SegmentLockBasePtr lockSegment (const Ice::Current &c) override
 
 SegmentUtilImplementations ()
 
bool unlockSegment (const SegmentLockBasePtr &lock, const Ice::Current &c) override
 
bool unlockSegmentWithToken (const std::string &token, const Ice::Current &c) override
 

Protected Member Functions

template<typename EntityPtrType >
Ice::Long getMostRecentTimestamp (const std::vector< EntityPtrType > &primitives, const ::Ice::Current &c=Ice::emptyCurrent) const
 
- Protected Member Functions inherited from WorkingMemoryEntitySegment< EnvironmentalPrimitive >
std::string addEntityThreadUnsafe (const EntityBasePtr &newEntity)
 adds the entity to the segment. More...
 
void fuseEntity (const EntityBasePtr &entity)
 
EntityBasePtr getEntityByIdUnsafe (const ::std::string &id) const
 
EntityBasePtr getEntityByNameThreadUnsafe (const ::std::string &name) const
 
bool hasEntityByIdThreadUnsafe (const std::string &entityId) const
 
void setListenerProxy (const WorkingMemoryListenerInterfacePrx &listenerProxy, const ::Ice::Current &c=Ice::emptyCurrent) override
 
void setParentMemory (const MemoryInterfacePtr &memory, const ::Ice::Current &c) override
 
void setSegmentName (const std::string &segmentName, const ::Ice::Current &c=Ice::emptyCurrent) override
 
void updateEntityThreadUnsafe (const std::string &entityId, const EntityBasePtr &update, const Ice::StringSeq &deactivatedFusionMethods)
 
- Protected Member Functions inherited from SegmentUtilImplementations
void keepAliveCheck ()
 

Additional Inherited Members

- Public Types inherited from SegmentUtilImplementations
using ScopedSharedLock = std::unique_lock< std::shared_mutex >
 
using ScopedSharedLockPtr = std::unique_ptr< ScopedSharedLock >
 
using ScopedUniqueLock = std::unique_lock< std::shared_mutex >
 
using ScopedUniqueLockPtr = std::unique_ptr< ScopedSharedLock >
 
- Protected Attributes inherited from WorkingMemoryEntitySegment< EnvironmentalPrimitive >
IdEntityMap entityMap
 
EntityFusionMethodPtr fusionMethod
 
int lastEntityId
 
MemoryInterfacePtr parentMemory
 
std::string segmentName
 
- Protected Attributes inherited from SegmentUtilImplementations
armarx::PeriodicTask< SegmentUtilImplementations >::pointer_type keepAliveCheckTask
 
IceUtil::Time keepAliveTimestamp
 
std::mutex keepAliveTimestampMutex
 
std::string lockToken
 
std::mutex mutex
 
ScopedSharedLockPtr readLock
 
std::shared_mutex segmentMutex
 
EntityMemorySegmentInterfacePrx selfProxy
 
std::mutex tokenMutex
 
ScopedUniqueLockPtr writeLock
 

Detailed Description

Definition at line 36 of file EnvironmentalPrimitiveSegment.h.

Constructor & Destructor Documentation

◆ EnvironmentalPrimitiveSegment()

Member Function Documentation

◆ getBoxById()

BoxPrimitiveBasePtr getBoxById ( const std::string &  id,
const ::Ice::Current &  c = Ice::emptyCurrent 
) const
override

Definition at line 167 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ getBoxes()

BoxPrimitiveBaseList getBoxes ( const ::Ice::Current &  c = Ice::emptyCurrent) const
override

Definition at line 103 of file EnvironmentalPrimitiveSegment.cpp.

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

◆ getBoxesByTimestamp()

BoxPrimitiveBaseList getBoxesByTimestamp ( const armarx::TimestampBasePtr &  timestamp,
const ::Ice::Current &  c = Ice::emptyCurrent 
) const
override

Definition at line 249 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ getCylinderById()

CylinderPrimitiveBasePtr getCylinderById ( const std::string &  id,
const ::Ice::Current &  c = Ice::emptyCurrent 
) const
override

Definition at line 153 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ getCylinders()

CylinderPrimitiveBaseList getCylinders ( const ::Ice::Current &  c = Ice::emptyCurrent) const
override

Definition at line 85 of file EnvironmentalPrimitiveSegment.cpp.

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

◆ getCylindersByTimestamp()

CylinderPrimitiveBaseList getCylindersByTimestamp ( const armarx::TimestampBasePtr &  timestamp,
const ::Ice::Current &  c = Ice::emptyCurrent 
) const
override

Definition at line 232 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ getEnvironmentalPrimitiveById()

EnvironmentalPrimitiveBasePtr getEnvironmentalPrimitiveById ( const std::string &  id,
const ::Ice::Current &  c = Ice::emptyCurrent 
) const
override

Definition at line 120 of file EnvironmentalPrimitiveSegment.cpp.

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

◆ getEnvironmentalPrimitives()

EnvironmentalPrimitiveBaseList getEnvironmentalPrimitives ( const ::Ice::Current &  c = Ice::emptyCurrent) const
override

Definition at line 34 of file EnvironmentalPrimitiveSegment.cpp.

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

◆ getEnvironmentalPrimitivesByTimestamp()

EnvironmentalPrimitiveBaseList getEnvironmentalPrimitivesByTimestamp ( const armarx::TimestampBasePtr &  timestamp,
const ::Ice::Current &  c = Ice::emptyCurrent 
) const
override

Definition at line 181 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ getMostRecentBoxes()

BoxPrimitiveBaseList getMostRecentBoxes ( const ::Ice::Current &  c = Ice::emptyCurrent) const
override

Definition at line 334 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ getMostRecentCylinders()

CylinderPrimitiveBaseList getMostRecentCylinders ( const ::Ice::Current &  c = Ice::emptyCurrent) const
override

Definition at line 317 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ getMostRecentEnvironmentalPrimitives()

EnvironmentalPrimitiveBaseList getMostRecentEnvironmentalPrimitives ( const ::Ice::Current &  c = Ice::emptyCurrent) const
override

Definition at line 266 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ getMostRecentPlanes()

PlanePrimitiveBaseList getMostRecentPlanes ( const ::Ice::Current &  c = Ice::emptyCurrent) const
override

Definition at line 283 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ getMostRecentSpheres()

SpherePrimitiveBaseList getMostRecentSpheres ( const ::Ice::Current &  c = Ice::emptyCurrent) const
override

Definition at line 300 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ getMostRecentTimestamp()

Ice::Long getMostRecentTimestamp ( const std::vector< EntityPtrType > &  primitives,
const ::Ice::Current &  c = Ice::emptyCurrent 
) const
inlineprotected

Definition at line 71 of file EnvironmentalPrimitiveSegment.h.

◆ getPlaneById()

PlanePrimitiveBasePtr getPlaneById ( const std::string &  id,
const ::Ice::Current &  c = Ice::emptyCurrent 
) const
override

Definition at line 125 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ getPlanes()

PlanePrimitiveBaseList getPlanes ( const ::Ice::Current &  c = Ice::emptyCurrent) const
override

Definition at line 51 of file EnvironmentalPrimitiveSegment.cpp.

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

◆ getPlanesByTimestamp()

PlanePrimitiveBaseList getPlanesByTimestamp ( const armarx::TimestampBasePtr &  timestamp,
const ::Ice::Current &  c = Ice::emptyCurrent 
) const
override

Definition at line 198 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ getSphereById()

SpherePrimitiveBasePtr getSphereById ( const std::string &  id,
const ::Ice::Current &  c = Ice::emptyCurrent 
) const
override

Definition at line 139 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ getSpheres()

SpherePrimitiveBaseList getSpheres ( const ::Ice::Current &  c = Ice::emptyCurrent) const
override

Definition at line 68 of file EnvironmentalPrimitiveSegment.cpp.

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

◆ getSpheresByTimestamp()

SpherePrimitiveBaseList getSpheresByTimestamp ( const armarx::TimestampBasePtr &  timestamp,
const ::Ice::Current &  c = Ice::emptyCurrent 
) const
override

Definition at line 215 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ removeOlderPrimitives()

void removeOlderPrimitives ( const armarx::TimestampBasePtr &  olderThan,
const ::Ice::Current &  c = Ice::emptyCurrent 
)
override

Definition at line 364 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

◆ removePrimitivesByTimestamp()

void removePrimitivesByTimestamp ( const armarx::TimestampBasePtr &  timestamp,
const ::Ice::Current &  c = Ice::emptyCurrent 
)
override

Definition at line 351 of file EnvironmentalPrimitiveSegment.cpp.

+ Here is the call graph for this function:

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