Trait holochain_state::prelude::LinkTypesHelper
source · pub trait LinkTypesHelper: Sized {
type Error;
// Required method
fn from_type<Z, I>(
zome_index: Z,
link_type: I
) -> Result<Option<Self>, Self::Error>
where Z: Into<ZomeIndex>,
I: Into<LinkType>;
}
Expand description
A helper trait for finding the app defined link type
from a ZomeIndex
and LinkType
.
If the zome id is a dependency of the calling zome and the link type is out of range (greater than the number of defined link types) then a guest error is return (which will invalidate an op if used in the validation callback).
If the zome id is not a dependency of the calling zome then
this will return None
.
Required Associated Types§
Required Methods§
Object Safety§
This trait is not object safe.