pub struct Proxy { /* private fields */ }Implementations§
source§impl Proxy
impl Proxy
pub fn addr(&self) -> Addr
pub fn send<M: Message>(&self, message: M) -> impl Future<Output = ()> + '_
pub fn try_send<M: Message>(&self, message: M) -> Result<(), TrySendError<M>>
pub fn send_to<M: Message>( &self, recipient: Addr, message: M ) -> impl Future<Output = ()> + '_
pub fn request<R: Request>( &self, request: R ) -> impl Future<Output = R::Response> + '_
pub fn respond<R: Request>( &self, token: ResponseToken<R>, response: R::Response )
pub fn recv(&mut self) -> impl Future<Output = Envelope> + '_
pub async fn try_recv(&mut self) -> Option<Envelope>
sourcepub async fn sync(&mut self)
pub async fn sync(&mut self)
Waits until the testable actor handles all previously sent messages.
Now it’s implemented as multiple calls yield_now(),
but the implementation can be changed in the future.
sourcepub fn set_recv_timeout(&mut self, recv_timeout: Duration)
pub fn set_recv_timeout(&mut self, recv_timeout: Duration)
Sets message wait time for recv call.
Auto Trait Implementations§
impl !RefUnwindSafe for Proxy
impl Send for Proxy
impl !Sync for Proxy
impl Unpin for Proxy
impl !UnwindSafe for Proxy
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