Struct varlink::Call [−][src]
Call is a struct, which is passed as the first argument to the interface methods in a derived form.
See also the CallTrait to use with the first Call parameter
#Examples
If your varlink method is called TestMethod
, the rust method to be implemented is called
test_method
. The first parameter is of type Call_TestMethod
, which has the method reply()
.
Examples
fn test_method(&self, call: &mut Call_TestMethod, /* more arguments */) -> varlink::Result<()> { /* ... */ return call.reply( /* more arguments */ ); }
Fields
request: Option<&'a Request<'a>>
Trait Implementations
impl<'a> CallTrait for Call<'a>
[src]
impl<'a> CallTrait for Call<'a>
fn reply_struct(&mut self, reply: Reply) -> Result<()>
[src]
fn reply_struct(&mut self, reply: Reply) -> Result<()>
Don't use this directly. Rather use the standard reply()
method.
fn set_continues(&mut self, cont: bool)
[src]
fn set_continues(&mut self, cont: bool)
Set this to true
to indicate, that more replies are following. Read more
fn is_oneway(&self) -> bool
[src]
fn is_oneway(&self) -> bool
True, if this request does not want a reply.
fn wants_more(&self) -> bool
[src]
fn wants_more(&self) -> bool
True, if this request accepts more than one reply.
fn get_request(&self) -> Option<&Request>
[src]
fn get_request(&self) -> Option<&Request>
fn reply_method_not_found(&mut self, method_name: String) -> Result<()>
[src]
fn reply_method_not_found(&mut self, method_name: String) -> Result<()>
reply with the standard varlink org.varlink.service.MethodNotFound
error
fn reply_method_not_implemented(&mut self, method_name: String) -> Result<()>
[src]
fn reply_method_not_implemented(&mut self, method_name: String) -> Result<()>
reply with the standard varlink org.varlink.service.MethodNotImplemented
error
fn reply_invalid_parameter(&mut self, parameter_name: String) -> Result<()>
[src]
fn reply_invalid_parameter(&mut self, parameter_name: String) -> Result<()>
reply with the standard varlink org.varlink.service.InvalidParameter
error