Chain

Struct Chain 

Source
pub struct Chain {
    pub variable: Vec<Arc<Germline>>,
    pub joining: Vec<Arc<Germline>>,
    pub c: Vec<Arc<Germline>>,
    pub a: Vec<Arc<Germline>>,
    pub d: Vec<Arc<Germline>>,
    pub e: Vec<Arc<Germline>>,
    pub g: Vec<Arc<Germline>>,
    pub m: Vec<Arc<Germline>>,
    pub o: Vec<Arc<Germline>>,
    pub t: Vec<Arc<Germline>>,
}
Expand description

The intermediate representation for a chain

Fields§

§variable: Vec<Arc<Germline>>

All V/variable germlines

§joining: Vec<Arc<Germline>>

All J/joining germlines

§c: Vec<Arc<Germline>>

All C/constant germlines

§a: Vec<Arc<Germline>>

All A constant germlines

§d: Vec<Arc<Germline>>

All D constant germlines

§e: Vec<Arc<Germline>>

All E constant germlines

§g: Vec<Arc<Germline>>

All G constant germlines

§m: Vec<Arc<Germline>>

All M constant germlines

§o: Vec<Arc<Germline>>

All O constant germlines

§t: Vec<Arc<Germline>>

All T constant germlines

Implementations§

Source§

impl Chain

Source

pub fn insert(&mut self, germline: Germline)

§Panics

It panics when it inserts an allele it has already placed (has to be filtered and ranked before)

Source

pub fn doc_row(&self) -> String

Create a row for use in the documentation of the numbers of different sequences available

Source§

impl Chain

Source

pub fn iter( &self, ) -> impl DoubleEndedIterator<Item = (GeneType, &[Arc<Germline>])> + ExactSizeIterator + '_

Iterate over the genes

Trait Implementations§

Source§

impl<'__de, __Context> BorrowDecode<'__de, __Context> for Chain

Source§

fn borrow_decode<__D: BorrowDecoder<'__de, Context = __Context>>( decoder: &mut __D, ) -> Result<Self, DecodeError>

Attempt to decode this type with the given BorrowDecode.
Source§

impl Debug for Chain

Source§

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

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

impl<__Context> Decode<__Context> for Chain

Source§

fn decode<__D: Decoder<Context = __Context>>( decoder: &mut __D, ) -> Result<Self, DecodeError>

Attempt to decode this type with the given Decode.
Source§

impl Default for Chain

Source§

fn default() -> Chain

Returns the “default value” for a type. Read more
Source§

impl<'de> Deserialize<'de> for Chain

Source§

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 Encode for Chain

Source§

fn encode<__E: Encoder>(&self, encoder: &mut __E) -> Result<(), EncodeError>

Encode a given type.
Source§

impl<'a> IntoIterator for &'a Chain

Source§

type IntoIter = IntoIter<(GeneType, &'a [Arc<Germline>]), 10>

Which kind of iterator are we turning this into?
Source§

type Item = (GeneType, &'a [Arc<Germline>])

The type of the elements being iterated over.
Source§

fn into_iter(self) -> Self::IntoIter

Creates an iterator from a value. Read more
Source§

impl<'a> IntoParallelIterator for &'a Chain

Available on crate feature rayon only.
Source§

type Iter = IntoIter<(GeneType, &'a [Arc<Germline>]), 10>

The parallel iterator type that will be created.
Source§

type Item = (GeneType, &'a [Arc<Germline>])

The type of item that the parallel iterator will produce.
Source§

fn into_par_iter(self) -> Self::Iter

Converts self into a parallel iterator. Read more
Source§

impl Serialize for Chain

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

§

impl Freeze for Chain

§

impl !RefUnwindSafe for Chain

§

impl Send for Chain

§

impl Sync for Chain

§

impl Unpin for Chain

§

impl !UnwindSafe for Chain

Blanket Implementations§

Source§

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

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

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

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

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

Source§

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

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> HighestOf<T> for T

Source§

type HighestLevel = T

This is the highest complexity level out of Self and the type parameter
Source§

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

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> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<'data, I> IntoParallelRefIterator<'data> for I
where I: 'data + ?Sized, &'data I: IntoParallelIterator,

Source§

type Iter = <&'data I as IntoParallelIterator>::Iter

The type of the parallel iterator that will be returned.
Source§

type Item = <&'data I as IntoParallelIterator>::Item

The type of item that the parallel iterator will produce. This will typically be an &'data T reference type.
Source§

fn par_iter(&'data self) -> <I as IntoParallelRefIterator<'data>>::Iter

Converts self into a parallel iterator. Read more
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

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

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

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

Performs the conversion.
Source§

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

Source§

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

The type returned in the event of a conversion error.
Source§

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

Performs the conversion.
Source§

impl<T> AtLeast<T> for T

Source§

impl<T> AtMax<T> for T

Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,