pub(crate) fn db_init(
ctx: FunctionEnvMut<'_, Env>,
ptr: WasmPtr<u8>,
ptr_len: u32,
) -> i64
Expand description
Create a new database instance for the calling contract.
This function expects to receive a pointer from which a ContractId
and the db_name
will be read.
This function should only be allowed in ContractSection::Deploy
, as that
is called when a contract is being (re)deployed and databases have to be created.
Permissions: deploy