Struct faimm::Fai[][src]

pub struct Fai { /* fields omitted */ }

The object that stores the parsed fasta index file. You can use it to map chromosome names to indexes and lookup offsets for chr-start:end coordinates

Methods

impl Fai
[src]

Open a fasta index file from path P.

Calculate the slice coordinates (byte offsets). tid is the index of the chromosome (lookup with Fai::tid if necessary. start, end: zero based coordinates of the requested range.

Returns an tuple (start, end) if successful. io::Error otherwise.

Calculate the slice coordinates (byte offsets). tid is the index of the chromosome (lookup with Fai::tid if necessary.

Returns an tuple (start, end) if successful. io::Error otherwise.

Return the index of the chromosome by name in the fasta index.

Returns the position of chr name if succesful, None otherwise.

Return the index of a chromosome in the fasta index.

Returns the size in bases as usize.

Return the name of the chromomsome at index tid

Return the names of the chromosomes from the fasta index in the same order as in the .fai. You can use Fai::tid to map it back to an index.

Returns a Vec<&str> with the chromosome names.

Trait Implementations

impl Debug for Fai
[src]

Formats the value using the given formatter. Read more

impl Clone for Fai
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl Send for Fai

impl Sync for Fai