[][src]Trait holochain_wasmer_host::prelude::LikeNamespace

pub trait LikeNamespace {
    pub fn get_export(&self, name: &str) -> Option<Export>;
pub fn get_exports(&self) -> Vec<(String, Export), Global>;
pub fn maybe_insert(&mut self, name: &str, export: Export) -> Option<()>; }

This trait represents objects that act as a namespace for imports. For example, an Instance or ImportObject could be considered namespaces that could provide imports to an instance.

Required methods

pub fn get_export(&self, name: &str) -> Option<Export>[src]

Gets an export by name.

pub fn get_exports(&self) -> Vec<(String, Export), Global>[src]

Gets all exports in the namespace.

pub fn maybe_insert(&mut self, name: &str, export: Export) -> Option<()>[src]

Maybe insert an Export by name into the namespace.

Loading content...

Implementations on Foreign Types

impl LikeNamespace for Rc<Instance>[src]

impl LikeNamespace for Arc<Mutex<Instance>>[src]

Loading content...

Implementors

impl LikeNamespace for Instance[src]

impl LikeNamespace for Namespace[src]

Loading content...