pub struct PreparedCallCache { /* private fields */ }Expand description
Fixed-capacity, zero-heap cache mapping call-path FNV-1a hashes to PreparedCallHandles.
Implementations§
Source§impl PreparedCallCache
impl PreparedCallCache
Sourcepub fn get(
&self,
path_hash: u64,
current_gen: RegistryGeneration,
) -> Option<PreparedCallHandle>
pub fn get( &self, path_hash: u64, current_gen: RegistryGeneration, ) -> Option<PreparedCallHandle>
Looks up a cached PreparedCallHandle for (path_hash, current_gen).
Sourcepub fn insert(&mut self, path_hash: u64, handle: PreparedCallHandle)
pub fn insert(&mut self, path_hash: u64, handle: PreparedCallHandle)
Inserts a PreparedCallHandle into the ring cache.
Trait Implementations§
Source§impl Clone for PreparedCallCache
impl Clone for PreparedCallCache
impl Copy for PreparedCallCache
Auto Trait Implementations§
impl Freeze for PreparedCallCache
impl RefUnwindSafe for PreparedCallCache
impl Send for PreparedCallCache
impl Sync for PreparedCallCache
impl Unpin for PreparedCallCache
impl UnsafeUnpin for PreparedCallCache
impl UnwindSafe for PreparedCallCache
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