pub struct CacheInvalidator<'a> { /* private fields */ }Expand description
What: Builder for cache invalidation operations.
Inputs: None (created via ArchClient::invalidate_cache())
Output:
CacheInvalidatorthat provides methods to invalidate cache entries
Details:
- Provides methods to invalidate specific operations or all caches
- No-op if caching is not enabled
Implementations§
Source§impl<'a> CacheInvalidator<'a>
impl<'a> CacheInvalidator<'a>
Sourcepub fn search(&self, query: &str) -> &Self
pub fn search(&self, query: &str) -> &Self
What: Invalidate search cache for a specific query.
Inputs:
query: Search query to invalidate
Output:
&Selffor method chaining
Details:
- Removes the search cache entry for the given query
- No-op if caching is not enabled
Sourcepub fn info(&self, names: &[&str]) -> &Self
pub fn info(&self, names: &[&str]) -> &Self
What: Invalidate info cache for specific packages.
Inputs:
names: Package names to invalidate
Output:
&Selffor method chaining
Details:
- Removes the info cache entry for the given packages
- No-op if caching is not enabled
Sourcepub fn comments(&self, pkgname: &str) -> &Self
pub fn comments(&self, pkgname: &str) -> &Self
What: Invalidate comments cache for a specific package.
Inputs:
pkgname: Package name to invalidate
Output:
&Selffor method chaining
Details:
- Removes the comments cache entry for the given package
- No-op if caching is not enabled
Sourcepub fn pkgbuild(&self, package: &str) -> &Self
pub fn pkgbuild(&self, package: &str) -> &Self
What: Invalidate pkgbuild cache for a specific package.
Inputs:
package: Package name to invalidate
Output:
&Selffor method chaining
Details:
- Removes the pkgbuild cache entry for the given package
- No-op if caching is not enabled
Auto Trait Implementations§
impl<'a> Freeze for CacheInvalidator<'a>
impl<'a> !RefUnwindSafe for CacheInvalidator<'a>
impl<'a> Send for CacheInvalidator<'a>
impl<'a> Sync for CacheInvalidator<'a>
impl<'a> Unpin for CacheInvalidator<'a>
impl<'a> !UnwindSafe for CacheInvalidator<'a>
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