Skip to content

FastqBatch

Mojo struct 🡭

@memory_only
struct FastqBatch

AnyType, Copyable, Deinitable, Movable, Sized, Writable

fn def __init__(out self, batch_size: Int = Int(4096), avg_record_size: Int = Int(150), quality_offset: UInt8 = UInt8(33))

Args:

  • batch_size (Int)
  • avg_record_size (Int)
  • quality_offset (UInt8)
  • self (Self)

Returns:

Self

fn def __init__(out self, records: List[FastqRecord], avg_record_size: Int = Int(150), quality_offset: UInt8 = UInt8(33))

Args:

  • records (List[FastqRecord])
  • avg_record_size (Int)
  • quality_offset (UInt8)
  • self (Self)

Returns:

Self

Raises:

fn def add(mut self, record: FastqRecord)

Args:

  • self (Self)
  • record (FastqRecord)
fn def add[origin: MutOrigin](mut self, record: FastqView[origin])

Parameters:

  • origin (MutOrigin)

Args:

  • self (Self)
  • record (FastqView[origin])
fn def num_records(self) -> Int

Args:

  • self (Self)

Returns:

Int

fn def seq_len(self) -> Int

Args:

  • self (Self)

Returns:

Int

fn def quality_offset(self) -> UInt8

Args:

  • self (Self)

Returns:

UInt8

fn def __len__(self) -> Int

Args:

  • self (Self)

Returns:

Int

fn def __repr__(self) -> String

Args:

  • self (Self)

Returns:

String

fn def get_record(self, index: Int) -> FastqRecord

Args:

  • self (Self)
  • index (Int)

Returns:

FastqRecord

Raises:

fn def get_ref(self, index: Int) -> FastqView[origin_of(self)]

Args:

  • self (Self)
  • index (Int)

Returns:

FastqView[origin_of(self)]

Raises:

fn def to_records(self) -> List[FastqRecord]

Args:

  • self (Self)

Returns:

List[FastqRecord]

Raises:

fn def write_to(self, mut w: T)

Args:

  • self (Self)
  • w (T)

Raises: