pub struct BtConnectionPool { /* private fields */ }Implementations§
Source§impl BtConnectionPool
impl BtConnectionPool
pub fn new() -> Self
pub fn with_max_idle(self, n: usize) -> Self
pub fn with_connect_timeout(self, d: Duration) -> Self
pub fn with_stale_threshold(self, d: Duration) -> Self
pub async fn prewarm(&mut self, addr: SocketAddr) -> Result<bool, String>
pub fn try_take(&mut self, addr: &SocketAddr) -> Option<ReadyConnection>
pub fn return_connection(&mut self, conn: ReadyConnection)
pub fn contains_addr(&self, addr: &SocketAddr) -> bool
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
pub async fn evict_stale(&mut self) -> usize
Trait Implementations§
Auto Trait Implementations§
impl Freeze for BtConnectionPool
impl RefUnwindSafe for BtConnectionPool
impl Send for BtConnectionPool
impl Sync for BtConnectionPool
impl Unpin for BtConnectionPool
impl UnsafeUnpin for BtConnectionPool
impl UnwindSafe for BtConnectionPool
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