pub struct Rpc { /* private fields */ }Implementations§
Source§impl Rpc
impl Rpc
pub fn new( id: &u64, method_name: &str, target_did: Vec<String>, metadata: IdentityToken, target_public_key: String, service_id: String, ) -> Rpc
pub fn encode_payload( &self, payload_type: &u8, payload_json: &str, meta_json: Option<&str>, ) -> Vec<u8> ⓘ
pub fn send(&mut self, payload: String) -> Vec<u8> ⓘ
pub fn receive(&mut self, bin_message: BinaryMessage) -> Result<String, String>
pub fn end(&mut self) -> Vec<u8> ⓘ
Sourcepub fn pending_payload(&mut self) -> Vec<u8> ⓘ
pub fn pending_payload(&mut self) -> Vec<u8> ⓘ
Get the next pending payload to send - there may be none. This is used to send payloads that were queued while waiting for the key exchange to complete. @returns The next pending payload to send, or an empty array if there are no pending payloads.
pub fn drop(self)
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Rpc
impl RefUnwindSafe for Rpc
impl Send for Rpc
impl Sync for Rpc
impl Unpin for Rpc
impl UnwindSafe for Rpc
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more