NVBIO
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Types | Public Methods | Public Members | List of all members
nvbio::io::ReadDataRAM Struct Reference

Detailed description

a read batch in host memory

Definition at line 415 of file reads.h.

#include <reads.h>

Inheritance diagram for nvbio::io::ReadDataRAM:
nvbio::io::ReadData nvbio::io::ReadDataView< IndexIterator, ReadStorageIterator, QualStorageIterator, NameStorageIterator >

Public Types

enum  StrandOp { NO_OP = 0x0000, REVERSE_OP = 0x0001, COMPLEMENT_OP = 0x0002, REVERSE_COMPLEMENT_OP = 0x0003 }
 
- Public Types inherited from nvbio::io::ReadData
typedef ReadDataView< uint32
*, uint32 *, char *, char * > 
plain_view_type
 
typedef ReadDataView< const
uint32 *, const uint32
*, const char *, const char * > 
const_plain_view_type
 
- Public Types inherited from nvbio::io::ReadDataView< IndexIterator, ReadStorageIterator, QualStorageIterator, NameStorageIterator >
typedef IndexIterator index_iterator
 the index iterator More...
 
typedef to_const
< index_iterator >::type 
const_index_iterator
 the const index iterator More...
 
typedef ReadStorageIterator read_storage_iterator
 the read storage iterator More...
 
typedef to_const
< read_storage_iterator >
::type 
const_read_storage_iterator
 the const read storage iterator More...
 
typedef QualStorageIterator qual_storage_iterator
 the qualities iterator More...
 
typedef to_const
< qual_storage_iterator >
::type 
const_qual_storage_iterator
 the const qualities iterator More...
 
typedef NameStorageIterator name_storage_iterator
 the names string iterator More...
 
typedef to_const
< name_storage_iterator >
::type 
const_name_storage_iterator
 the names string iterator More...
 
typedef PackedStream
< read_storage_iterator, uint8,
READ_BITS, READ_BIG_ENDIAN
read_stream_type
 the packed read-stream type More...
 
typedef PackedStream
< const_read_storage_iterator,
uint8, READ_BITS,
READ_BIG_ENDIAN
const_read_stream_type
 the const packed read-stream type More...
 
typedef read_stream_type::iterator read_stream_iterator
 the read-stream iterator More...
 
typedef
const_read_stream_type::iterator 
const_read_stream_iterator
 the const read-stream iterator More...
 
typedef vector_view
< read_stream_iterator
read_string
 the read string type More...
 
typedef vector_view
< const_read_stream_iterator
const_read_string
 the const read string type More...
 
typedef ConcatenatedStringSet
< read_stream_iterator,
index_iterator
read_string_set_type
 string-set type More...
 
typedef ConcatenatedStringSet
< const_read_stream_iterator,
const_index_iterator
const_read_string_set_type
 const string-set type More...
 
typedef ConcatenatedStringSet
< qual_storage_iterator,
index_iterator
qual_string_set_type
 quality string-set type More...
 
typedef ConcatenatedStringSet
< const_qual_storage_iterator,
const_index_iterator
const_qual_string_set_type
 const quality string-set type More...
 
typedef ConcatenatedStringSet
< name_storage_iterator,
index_iterator
name_string_set_type
 name string-set type More...
 
typedef ConcatenatedStringSet
< const_name_storage_iterator,
const_index_iterator
const_name_string_set_type
 const name string-set type More...
 

Public Methods

 ReadDataRAM ()
 
void reserve (const uint32 n_reads, const uint32 n_bps)
 
void push_back (uint32 read_len, const char *name, const uint8 *base_pairs, const uint8 *quality, const QualityEncoding quality_encoding, const uint32 truncate_read_len, const StrandOp conversion_flags)
 
void end_batch (void)
 
- Public Methods inherited from nvbio::io::ReadData
 ReadData ()
 
virtual ~ReadData ()
 
- Public Methods inherited from nvbio::io::ReadDataView< IndexIterator, ReadStorageIterator, QualStorageIterator, NameStorageIterator >
NVBIO_HOST_DEVICE NVBIO_FORCEINLINE ReadDataView ()
 
template<typename InIndexIterator , typename InReadIterator , typename InQualIterator , typename InNameIterator >
NVBIO_HOST_DEVICE NVBIO_FORCEINLINE ReadDataView (const ReadDataView< InIndexIterator, InReadIterator, InQualIterator, InNameIterator > &in)
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
index_iterator 
name_index ()
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
index_iterator 
read_index ()
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
name_storage_iterator 
name_stream ()
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
read_storage_iterator 
read_stream_storage ()
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
read_stream_type 
read_stream ()
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
qual_storage_iterator 
qual_stream ()
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_index_iterator 
const_name_index () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_index_iterator 
const_read_index () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_name_storage_iterator 
const_name_stream () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_read_storage_iterator 
const_read_stream_storage () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_read_stream_type 
const_read_stream () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_qual_storage_iterator 
const_qual_stream () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_index_iterator 
name_index () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_index_iterator 
read_index () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_name_storage_iterator 
name_stream () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_read_storage_iterator 
read_stream_storage () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_read_stream_type 
read_stream () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_qual_storage_iterator 
qual_stream () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE uint32 
size () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE uint32 
bps () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE uint32 
words () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE uint32 
name_stream_len () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE uint32 
max_read_len () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE uint32 
min_read_len () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE uint32 
avg_read_len () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE uint2 
get_range (const uint32 i) const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
read_string_set_type 
read_string_set ()
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_read_string_set_type 
read_string_set () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_read_string_set_type 
const_read_string_set () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE read_string 
get_read (const uint32 i)
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE read_string 
get_read (const uint32 i) const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
qual_string_set_type 
qual_string_set ()
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_qual_string_set_type 
qual_string_set () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_qual_string_set_type 
const_qual_string_set () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
name_string_set_type 
name_string_set ()
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_name_string_set_type 
name_string_set () const
 
NVBIO_HOST_DEVICE
NVBIO_FORCEINLINE
const_name_string_set_type 
const_name_string_set () const
 

Public Members

std::vector< uint32m_read_vec
 
std::vector< uint32m_read_index_vec
 
std::vector< char > m_qual_vec
 
std::vector< char > m_name_vec
 
std::vector< uint32m_name_index_vec
 

Additional Inherited Members

- Static Public Members inherited from nvbio::io::ReadDataView< IndexIterator, ReadStorageIterator, QualStorageIterator, NameStorageIterator >
static const uint32 READ_BITS = 4
 
static const bool HI_BITS = false
 
static const bool READ_BIG_ENDIAN = false
 
static const uint32 READ_SYMBOLS_PER_WORD = (4*sizeof(uint32))/READ_BITS
 

Member Enumeration Documentation

a set of flags describing the operators to apply to a given strand

Enumerator
NO_OP 

default, no operator applied

REVERSE_OP 

reverse operator

COMPLEMENT_OP 

complement operator

REVERSE_COMPLEMENT_OP 

convenience definition, same as StrandOp( REVERSE_OP | COMPLEMENT_OP )

Definition at line 419 of file reads.h.

Constructor & Destructor Documentation

nvbio::io::ReadDataRAM::ReadDataRAM ( )

Definition at line 275 of file reads.cpp.

Member Function Documentation

void nvbio::io::ReadDataRAM::end_batch ( void  )

signals that the batch is complete

Definition at line 322 of file reads.cpp.

void nvbio::io::ReadDataRAM::push_back ( uint32  read_len,
const char *  name,
const uint8 base_pairs,
const uint8 quality,
const QualityEncoding  quality_encoding,
const uint32  truncate_read_len,
const StrandOp  conversion_flags 
)

add a read to the end of this batch

Parameters
read_leninput read length
nameread name
base_pairslist of base pairs
qualitylist of base qualities
quality_encodingquality encoding scheme
truncate_read_lentruncate the read if longer than this
conversion_flagsconversion operators applied to the strand

Definition at line 466 of file reads.cpp.

void nvbio::io::ReadDataRAM::reserve ( const uint32  n_reads,
const uint32  n_bps 
)

reserve enough storage for a given number of reads and bps

Definition at line 303 of file reads.cpp.

Member Data Documentation

std::vector<uint32> nvbio::io::ReadDataRAM::m_name_index_vec

Definition at line 459 of file reads.h.

std::vector<char> nvbio::io::ReadDataRAM::m_name_vec

Definition at line 458 of file reads.h.

std::vector<char> nvbio::io::ReadDataRAM::m_qual_vec

Definition at line 457 of file reads.h.

std::vector<uint32> nvbio::io::ReadDataRAM::m_read_index_vec

Definition at line 456 of file reads.h.

std::vector<uint32> nvbio::io::ReadDataRAM::m_read_vec

Definition at line 455 of file reads.h.


The documentation for this struct was generated from the following files: