Storage#
- class Storage#
An abstract class that allows saving Savable objects to storage and loading them from storage.
- load(self: pyhelayers.Storage, arg0: pyhelayers.HeContext, arg1: str) pyhelayers.Saveable #
Loads a Saveable object from a buffer
- Parameters:
context (HeContext) – Context object
name (string) – Buffer name in the storage
- save(self: pyhelayers.Storage, arg0: pyhelayers.Saveable, arg1: str) None #
Saves a Saveable object into a buffer
- Parameters:
sav (Savable) – Savable object
name (string) – Buffer name in the storage
-
class Storage#
A class implementing a storage system for large objects.
Concrete implementations can use memory, file system, or network for storing buffers.
Subclassed by helayers::FileStorage, helayers::MemoryStorage
Public Functions
-
inline virtual ~Storage()#
-
virtual Buffer openForRead(const std::string &name) = 0#
-
virtual Buffer openForWrite(const std::string &name) = 0#
-
void save(Saveable &sav, const std::string &name)#
Saves a Saveable object into a buffer.
- Parameters:
sav – Saveable object
name – buffer name
-
inline virtual ~Storage()#