pub struct DigestCache {
pub sequences: Vec<CachedDigest>,
}Expand description
Pre-computed digest cache for a FASTA file.
Written as {fasta_path}.refget.json. When present and up-to-date,
the server skips digest computation at startup.
Fields§
§sequences: Vec<CachedDigest>Implementations§
Source§impl DigestCache
impl DigestCache
Sourcepub fn from_fasta<P: AsRef<Path>>(path: P) -> StoreResult<Self>
pub fn from_fasta<P: AsRef<Path>>(path: P) -> StoreResult<Self>
Compute digests for all sequences in a FASTA file.
Trait Implementations§
Source§impl Clone for DigestCache
impl Clone for DigestCache
Source§fn clone(&self) -> DigestCache
fn clone(&self) -> DigestCache
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for DigestCache
impl Debug for DigestCache
Source§impl<'de> Deserialize<'de> for DigestCache
impl<'de> Deserialize<'de> for DigestCache
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for DigestCache
impl Serialize for DigestCache
Source§impl SidecarCache for DigestCache
impl SidecarCache for DigestCache
Source§const EXTENSION: &str = "refget.json"
const EXTENSION: &str = "refget.json"
The sidecar file extension (e.g.
"refget.json", "seqcol.json").Source§fn cache_path_for<P: AsRef<Path>>(fasta_path: P) -> PathBuf
fn cache_path_for<P: AsRef<Path>>(fasta_path: P) -> PathBuf
Return the standard cache path for a given FASTA file.
Auto Trait Implementations§
impl Freeze for DigestCache
impl RefUnwindSafe for DigestCache
impl Send for DigestCache
impl Sync for DigestCache
impl Unpin for DigestCache
impl UnsafeUnpin for DigestCache
impl UnwindSafe for DigestCache
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