Struct noodles_bgzf::async::reader::Builder
source · pub struct Builder { /* private fields */ }
Expand description
An async BGZF reader builder.
Implementations§
source§impl Builder
impl Builder
sourcepub fn set_worker_count(self, worker_count: NonZeroUsize) -> Self
pub fn set_worker_count(self, worker_count: NonZeroUsize) -> Self
Sets a worker count.
By default, the worker count is set to the number of available logical CPUs.
§Examples
use std::num::NonZeroUsize;
use noodles_bgzf as bgzf;
let worker_count = NonZeroUsize::try_from(1)?;
let builder = bgzf::r#async::reader::Builder::default()
.set_worker_count(worker_count);
sourcepub fn build_with_reader<R>(self, reader: R) -> Reader<R>where
R: AsyncRead,
pub fn build_with_reader<R>(self, reader: R) -> Reader<R>where
R: AsyncRead,
Builds an async BGZF reader with an async reader.
§Examples
use noodles_bgzf as bgzf;
let reader = bgzf::r#async::reader::Builder::default()
.build_with_reader(io::empty());
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Builder
impl RefUnwindSafe for Builder
impl Send for Builder
impl Sync for Builder
impl Unpin for Builder
impl UnwindSafe for Builder
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