pub trait SequenceRead<'a> {
    fn sequence_lengths(&'a self) -> Result<&[SequenceLength], Box<dyn Error>>;
    fn nucleotides(
        &self,
        chr: &str
    ) -> Result<Box<dyn Nucleotides>, Box<dyn Error>>; fn soft_masked_blocks(
        &'a self,
        chr: &str
    ) -> Result<&'a [Range<usize>], Box<dyn Error>>; fn hard_masked_blocks(
        &'a self,
        chr: &str
    ) -> Result<&'a [Range<usize>], Box<dyn Error>>; }
Expand description

Trait for readers of other file formats

This trait is used in the function to_2bit to retrieve the needed information to produce a 2bit file from another file format.

This trait uses generic Errs, so that implementors can use any error type they might need when they process data.

Required Methods

Return the names and lengths of the sequences (ideally in a stable order for reproducibility)

Return pieces of the actual nucleotide sequence

Return the soft masked blocks for a sequence

Return the hard masked blocks for a sequence

Implementors