pub(crate) fn db_lookup(
ctx: FunctionEnvMut<'_, Env>,
ptr: WasmPtr<u8>,
ptr_len: u32,
) -> i64
Expand description
Lookup a database handle from its name. If it exists, push it to the Vector of db_handles.
Returns the index of the DbHandle in the db_handles Vector on success. Otherwise, returns an error value.
This function can be called from any ContractSection
.
Permissions: deploy, metadata, exec, update