pub struct ClientPool { /* private fields */ }Expand description
Manages a pool of LSP client connections
Implementations§
Source§impl ClientPool
impl ClientPool
Sourcepub async fn get_or_create(
&self,
config: LspServerConfig,
) -> Result<Arc<LspServerConfig>>
pub async fn get_or_create( &self, config: LspServerConfig, ) -> Result<Arc<LspServerConfig>>
Get or create a client for a language
Sourcepub async fn active_count(&self) -> usize
pub async fn active_count(&self) -> usize
Get the number of active clients
Sourcepub async fn referenced_count(&self) -> usize
pub async fn referenced_count(&self) -> usize
Get the number of clients with active references
Sourcepub async fn cleanup_idle(&self) -> usize
pub async fn cleanup_idle(&self) -> usize
Clean up idle clients
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ClientPool
impl !RefUnwindSafe for ClientPool
impl Send for ClientPool
impl Sync for ClientPool
impl Unpin for ClientPool
impl !UnwindSafe for ClientPool
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