pub type InlineCoordinatorZome = InlineZome<CoordinatorZomeMarker>;

Aliased Type§

struct InlineCoordinatorZome { /* private fields */ }

Implementations§

source§

impl<T> InlineZome<T>

source

pub fn functions(&self) -> Vec<FunctionName, Global>

source

pub fn function<F, I, O>(self, name: &str, f: F) -> InlineZome<T>where F: Fn(Box<dyn HostFnApiT, Global>, I) -> Result<O, InlineZomeError> + 'static + Send + Sync, I: DeserializeOwned + Debug, O: Serialize + Debug,

Define a new zome function or callback with the given name

source

pub fn callback<F, I, O>(self, name: &str, f: F) -> InlineZome<T>where F: Fn(Box<dyn HostFnApiT, Global>, I) -> Result<O, InlineZomeError> + 'static + Send + Sync, I: DeserializeOwned + Debug, O: Serialize + Debug,

👎Deprecated: Alias for function

Alias for function

source

pub fn maybe_call( &self, api: Box<dyn HostFnApiT, Global>, name: &FunctionName, input: ExternIO ) -> Result<Option<ExternIO>, InlineZomeError>

Make a call to an inline zome callback. If the callback doesn’t exist, return None.

source

pub fn uuid(&self) -> String

Accessor

source

pub fn set_global(self, name: impl Into<String>, val: u8) -> InlineZome<T>

Set a global value for this zome.

source§

impl InlineZome<CoordinatorZomeMarker>

source

pub fn new<S>(uuid: S) -> InlineZome<CoordinatorZomeMarker>where S: Into<String>,

Create a new coordinator zome with the given network seed

source

pub fn new_unique() -> InlineZome<CoordinatorZomeMarker>

Create a new coordinator zome with a unique random network seed

Trait Implementations§

source§

impl<T> Debug for InlineZome<T>where T: Debug,

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl<T> Hash for InlineZome<T>where T: Hash,

source§

fn hash<H>(&self, state: &mut H)where H: Hasher,

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl<T> InlineZomeT for InlineZome<T>where T: Debug,

source§

fn functions(&self) -> Vec<FunctionName, Global>

Get the functions for this InlineZome.
source§

fn maybe_call( &self, api: Box<dyn HostFnApiT, Global>, name: &FunctionName, input: ExternIO ) -> Result<Option<ExternIO>, InlineZomeError>

Make a call to an inline zome function. If the function doesn’t exist, return None.
source§

fn uuid(&self) -> String

Accessor
source§

fn get_global(&self, name: &str) -> Option<u8>

Get a global value for this zome.
source§

impl<T> Ord for InlineZome<T>where T: Ord,

source§

fn cmp(&self, other: &InlineZome<T>) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · source§

fn max(self, other: Self) -> Selfwhere Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · source§

fn min(self, other: Self) -> Selfwhere Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · source§

fn clamp(self, min: Self, max: Self) -> Selfwhere Self: Sized + PartialOrd<Self>,

Restrict a value to a certain interval. Read more
source§

impl<T> PartialEq<InlineZome<T>> for InlineZome<T>where T: PartialEq<T>,

source§

fn eq(&self, other: &InlineZome<T>) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl<T> PartialOrd<InlineZome<T>> for InlineZome<T>where T: PartialOrd<T>,

source§

fn partial_cmp(&self, other: &InlineZome<T>) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl<T> Eq for InlineZome<T>where T: Eq,