pub struct ServerPrepared { /* private fields */ }Expand description
Tracks which canonical prepared statements exist on a specific server connection, with LRU eviction when the configured limit is reached.
Lives next to ServerConn because it’s “state that follows a
connection through its lifetime” — created at connect_server
time, travels with the connection through checkout and checkin,
consulted by the transaction forwarder’s
prepared-statement-rewriting path.
Implementations§
Source§impl ServerPrepared
impl ServerPrepared
pub fn new(max: u32) -> Self
Sourcepub fn contains(&self, canon: &str) -> bool
pub fn contains(&self, canon: &str) -> bool
Check whether the canonical statement is already prepared on this server.
Auto Trait Implementations§
impl Freeze for ServerPrepared
impl RefUnwindSafe for ServerPrepared
impl Send for ServerPrepared
impl Sync for ServerPrepared
impl Unpin for ServerPrepared
impl UnsafeUnpin for ServerPrepared
impl UnwindSafe for ServerPrepared
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