From 9101817b0fd61d7bcccfaa8933e64d6e3787395d Mon Sep 17 00:00:00 2001 From: Daiki Mizukami Date: Mon, 27 Mar 2017 08:06:07 +0900 Subject: [PATCH] feat(client): add Client::handle --- src/client/mod.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/client/mod.rs b/src/client/mod.rs index 17f4416290..d8cec11c14 100644 --- a/src/client/mod.rs +++ b/src/client/mod.rs @@ -77,6 +77,12 @@ impl Client { } impl Client { + /// Return a reference to a handle to the event loop this Client is associated with. + #[inline] + pub fn handle<'a>(&'a self) -> &'a Handle { + &self.handle + } + /// Create a new client with a specific connector. #[inline] fn configured(config: Config, handle: &Handle) -> Client {