pub trait RpcInvocable: Invocable {
// Required method
fn invoke(
&self,
obj: Arc<dyn Object>,
method: Box<dyn DynMethod>,
ctx: Arc<dyn Context>,
sink: BoxedUpdateSink,
) -> Result<RpcResultFuture, InvokeError>;
}
Expand description
Subtrait of Invocable
that requires its outputs to be serializable as RPC replies.
Required Methods§
Sourcefn invoke(
&self,
obj: Arc<dyn Object>,
method: Box<dyn DynMethod>,
ctx: Arc<dyn Context>,
sink: BoxedUpdateSink,
) -> Result<RpcResultFuture, InvokeError>
fn invoke( &self, obj: Arc<dyn Object>, method: Box<dyn DynMethod>, ctx: Arc<dyn Context>, sink: BoxedUpdateSink, ) -> Result<RpcResultFuture, InvokeError>
Invoke a method on an object.
Requires that obj
has the type self.object_type()
,
and that method
has the type self.method_type()
.