pub struct FragmentGeomDesc {
    pub read1_desc: Vec<GeomPiece>,
    pub read2_desc: Vec<GeomPiece>,
}
Expand description

This structure holds our representation of the parsed fragment geometry description.

Fields§

§read1_desc: Vec<GeomPiece>

The sequence of GeomPieces describing read 1 of this fragment in left-to-right order.

§read2_desc: Vec<GeomPiece>

The sequence of GeomPieces describing read 2 of this fragment in left-to-right order.

Implementations§

source§

impl FragmentGeomDesc

source

pub fn is_complex_geometry(&self) -> bool

A “complex” geometry is one that contains a FixedSeq piece, and/or a BoundedRange piece

source

pub fn is_simple_geometry(&self) -> bool

A “simple” geometry is one that contains only fixed length pieces (but doesn’t include any fixed seq segments) and unbounded pieces.

Trait Implementations§

source§

impl Debug for FragmentGeomDesc

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Display for FragmentGeomDesc

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Write back a geometry fragment specification as exactly the type of string the parser should accept in the first place. This is the canonical representation of the geometry.

source§

impl<'a> TryFrom<&'a str> for FragmentGeomDesc

source§

fn try_from(arg: &'a str) -> Result<Self, Self::Error>

This is the main entry point to obtain a FragmentGeomDesc structure. This function parses the FGDL description string provided as arg, and returns either Ok(FragGeomDesc), if the parse is succesful or an anyhow::Error if the parsing fails.

Currently, the FGDL makes a structural assumption that is reflected in the way this function works. The description string will describe the fragment geometry for a fragment consisting of a pair of reads (i.e. currently there is no support for single-end reads or fragments containing > 2 reads).

§

type Error = Error

The type returned in the event of a conversion error.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

const: unstable · source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

const: unstable · source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

const: unstable · source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere U: From<T>,

const: unstable · source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToString for Twhere T: Display + ?Sized,

source§

default fn to_string(&self) -> String

Converts the given value to a String. Read more
source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
const: unstable · source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
const: unstable · source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.