pub struct PairedFastqReader<R1, R2> { /* private fields */ }Expand description
Stateful reader for ordered separate-file paired-end FASTQ streams.
This reader validates matching records as it advances both streams. It does not reorder or synchronize mates that appear in different orders.
Implementations§
Source§impl<R1: Read, R2: Read> PairedFastqReader<R1, R2>
impl<R1: Read, R2: Read> PairedFastqReader<R1, R2>
Sourcepub fn new(first: R1, second: R2) -> Self
pub fn new(first: R1, second: R2) -> Self
Create a paired reader with default FASTQ configuration.
Sourcepub fn with_config(first: R1, second: R2, config: FastqConfig) -> Self
pub fn with_config(first: R1, second: R2, config: FastqConfig) -> Self
Create a paired reader using the same configuration for both streams.
Sourcepub fn with_configs(
first: R1,
first_config: FastqConfig,
second: R2,
second_config: FastqConfig,
) -> Self
pub fn with_configs( first: R1, first_config: FastqConfig, second: R2, second_config: FastqConfig, ) -> Self
Create a paired reader with separate per-stream configurations.
Sourcepub fn from_fastq_readers(
first: FastqReader<R1>,
second: FastqReader<R2>,
) -> Self
pub fn from_fastq_readers( first: FastqReader<R1>, second: FastqReader<R2>, ) -> Self
Create a paired reader from two existing FastqReader values.
Sourcepub fn with_pair_validation(self, pair_validation: PairValidation) -> Self
pub fn with_pair_validation(self, pair_validation: PairValidation) -> Self
Override the paired identifier validation policy.
Sourcepub fn next_pair_batch(&mut self) -> Result<Option<PairedFastqBatch<'_>>>
pub fn next_pair_batch(&mut self) -> Result<Option<PairedFastqBatch<'_>>>
Read the next validated paired batch.
Returns Ok(None) when both streams end together.
Trait Implementations§
Auto Trait Implementations§
impl<R1, R2> Freeze for PairedFastqReader<R1, R2>
impl<R1, R2> RefUnwindSafe for PairedFastqReader<R1, R2>where
R1: RefUnwindSafe,
R2: RefUnwindSafe,
impl<R1, R2> Send for PairedFastqReader<R1, R2>
impl<R1, R2> Sync for PairedFastqReader<R1, R2>
impl<R1, R2> Unpin for PairedFastqReader<R1, R2>
impl<R1, R2> UnsafeUnpin for PairedFastqReader<R1, R2>where
R1: UnsafeUnpin,
R2: UnsafeUnpin,
impl<R1, R2> UnwindSafe for PairedFastqReader<R1, R2>where
R1: UnwindSafe,
R2: UnwindSafe,
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