pub struct FastaContig {
pub name: String,
pub length: u64,
pub md5: String,
pub sort_order: u32,
pub report_contig_id: Option<u32>,
pub aliases: Vec<String>,
}Expand description
A contig in a FASTA distribution
Fields§
§name: StringContig name as it appears in the FASTA
length: u64Sequence length
md5: StringMD5 checksum (required for matching)
sort_order: u32Sort order (position in original file)
report_contig_id: Option<u32>Link to ReportContig (None for decoy/HLA not in assembly report)
aliases: Vec<String>Alternative names
Implementations§
Source§impl FastaContig
impl FastaContig
Sourcepub fn merge(&mut self, other: &FastaContig) -> Result<(), ContigMergeError>
pub fn merge(&mut self, other: &FastaContig) -> Result<(), ContigMergeError>
Merge another contig’s metadata into this one
Used when building from multiple input files (e.g., dict + NCBI report)
§Errors
Returns an error if:
- Names don’t match (
ContigMergeError::NameMismatch) - Lengths don’t match (
ContigMergeError::LengthMismatch) - Both contigs have different non-empty MD5 checksums (
ContigMergeError::Md5Conflict)
Trait Implementations§
Source§impl Clone for FastaContig
impl Clone for FastaContig
Source§fn clone(&self) -> FastaContig
fn clone(&self) -> FastaContig
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 FastaContig
impl Debug for FastaContig
Source§impl<'de> Deserialize<'de> for FastaContig
impl<'de> Deserialize<'de> for FastaContig
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 PartialEq for FastaContig
impl PartialEq for FastaContig
Source§impl Serialize for FastaContig
impl Serialize for FastaContig
impl StructuralPartialEq for FastaContig
Auto Trait Implementations§
impl Freeze for FastaContig
impl RefUnwindSafe for FastaContig
impl Send for FastaContig
impl Sync for FastaContig
impl Unpin for FastaContig
impl UnwindSafe for FastaContig
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