canic_core/api/runtime/mod.rs
1use crate::{dto::error::Error, ops::runtime::memory::MemoryRegistryOps};
2
3///
4/// MemoryRuntimeApi
5///
6
7pub struct MemoryRuntimeApi;
8
9impl MemoryRuntimeApi {
10 /// Bootstrap Canic's reserved stable-memory range and flush deferred registrations.
11 pub fn bootstrap_registry() -> Result<(), Error> {
12 let _ = MemoryRegistryOps::bootstrap_registry().map_err(Error::from)?;
13
14 Ok(())
15 }
16}