pub struct BauClient<const RETRIES: usize> { /* private fields */ }
Expand description
Implementations§
Source§impl<const RETRIES: usize> BauClient<RETRIES>
impl<const RETRIES: usize> BauClient<RETRIES>
Sourcepub fn new(addr: SocketAddr) -> Self
pub fn new(addr: SocketAddr) -> Self
Sourcepub async fn send_string(
&self,
request: String,
) -> Result<BauServerResponseReceiver, SendError>
pub async fn send_string( &self, request: String, ) -> Result<BauServerResponseReceiver, SendError>
Sends a String payload through the BauClient to the BauServer and returns a BauServerResponseReceiver that we can poll for responses.
Sourcepub async fn send(
&self,
bau_message: BauMessage,
) -> Result<BauServerResponseReceiver, SendError>
pub async fn send( &self, bau_message: BauMessage, ) -> Result<BauServerResponseReceiver, SendError>
Sends a BauMessage through the BauClient to the BauServer and returns a BauServerResponseReceiver that we can poll for responses.
Note: Caller should not provide any handlers. They will be ignored.
Auto Trait Implementations§
impl<const RETRIES: usize> Freeze for BauClient<RETRIES>
impl<const RETRIES: usize> RefUnwindSafe for BauClient<RETRIES>
impl<const RETRIES: usize> Send for BauClient<RETRIES>
impl<const RETRIES: usize> Sync for BauClient<RETRIES>
impl<const RETRIES: usize> Unpin for BauClient<RETRIES>
impl<const RETRIES: usize> UnwindSafe for BauClient<RETRIES>
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
§impl<T> Erasable for T
impl<T> Erasable for T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more