Module storage

Module storage 

Source
Expand description

Utilities to help manage canister stable memory.

ic-cdk gives only low-level interface to canister stable memory, with no memory manager or allocator.

To help with easy access:

  • StableStorage supports sequential read & write of bytes by implementing io::Read and io::Write traits.

  • StorageStack provides a stack interface allowing arbitrary values to be pushed onto and popped off the stable memory. StableStorage implements this trait. Being a trait it allows alternative implementations, for example in testing code.

Modules§

test

Structs§

StableStorage
Reader/Writer of the canister stable memory.

Enums§

StorageError
Possible errors when dealing with stable memory.

Traits§

StorageStack
Stack interface for stable memory that supports push and pop of arbitrary values that implement the Candid interface.

Type Aliases§

Offset
Representation of a memory address.