AbstractFileEntityWrapper Class Reference

#include <MemoryX/core/entity/AbstractEntityWrapper.h>

+ Inheritance diagram for AbstractFileEntityWrapper:

Public Member Functions

 AbstractFileEntityWrapper (GridFileManagerPtr fileManager)
 
- Public Member Functions inherited from AbstractEntityWrapper
 AbstractEntityWrapper ()
 
EntityBasePtr getEntity () const
 Get the stored name of the stored entity. More...
 
std::string getId () const
 Get the identifier of the stored entity. More...
 
std::string getName () const
 Get the name of the stored entity. More...
 
void setEntity (const EntityBasePtr &entity)
 Replace the stored entity with a new one. More...
 
 ~AbstractEntityWrapper () override
 

Protected Member Functions

std::string cacheAttributeFile (const std::string &attrName, bool preserveOriginalFName=false) const
 
void cleanUpAttributeFiles (EntityAttributeBasePtr oldAttr, EntityAttributeBasePtr newAttr)
 cleanUpAttributeFiles compares the files attached to the two given attributes and removes the files of the oldAttr, if they dont match. More...
 
void removeAttributeFiles (const memoryx::EntityAttributeBasePtr &attr)
 removes all files of an attribute from the gridfs More...
 

Protected Attributes

GridFileManagerPtr fileManager
 

Detailed Description

Definition at line 82 of file AbstractEntityWrapper.h.

Constructor & Destructor Documentation

◆ AbstractFileEntityWrapper()

Definition at line 142 of file AbstractEntityWrapper.cpp.

Member Function Documentation

◆ cacheAttributeFile()

std::string cacheAttributeFile ( const std::string &  attrName,
bool  preserveOriginalFName = false 
) const
protected

Definition at line 129 of file AbstractEntityWrapper.cpp.

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

◆ cleanUpAttributeFiles()

void cleanUpAttributeFiles ( EntityAttributeBasePtr  oldAttr,
EntityAttributeBasePtr  newAttr 
)
protected

cleanUpAttributeFiles compares the files attached to the two given attributes and removes the files of the oldAttr, if they dont match.

Thus, this function should only be called with attributes of the same kind (e.g. Attribute for texture files). If multiple files are attached to that attribute, they must appear in the same order.

Parameters
oldAttr
newAttr

Definition at line 64 of file AbstractEntityWrapper.cpp.

+ Here is the caller graph for this function:

◆ removeAttributeFiles()

void removeAttributeFiles ( const memoryx::EntityAttributeBasePtr &  attr)
protected

removes all files of an attribute from the gridfs

Parameters
attr

Definition at line 102 of file AbstractEntityWrapper.cpp.

Member Data Documentation

◆ fileManager

GridFileManagerPtr fileManager
protected

Definition at line 106 of file AbstractEntityWrapper.h.


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