[][src]Function holochain_wasmer_host::guest::call

pub fn call<I: TryInto<SerializedBytes, Error = IE>, IE, O: TryFrom<SerializedBytes, Error = OE>, OE>(
    instance: &mut Instance,
    call: &str,
    serializable: I
) -> Result<O, WasmError> where
    String: From<IE>,
    String: From<OE>, 

convenience wrapper around call_bytes to handling input and output of any struct that:

  • is commonly defined in both the host and guest (e.g. shared in a common crate)
  • implements standard JsonString round-tripping (e.g. DefaultJson)