yat
0.11.3pre
|
#include <yat/omic/BamFile.h>
Public Member Functions | |
OutBamFile (void) | |
OutBamFile (const std::string &, const BamHeader &header) | |
Create an output bam file. | |
void | open (const std::string &fn, const BamHeader &hdr) |
Open an output bam file. | |
void | write (const BamRead &read) |
write a read to output file | |
void | close (void) |
close file | |
bool | is_open (void) const |
Protected Member Functions | |
void | open_base (const std::string &fn, const std::string &mode, const void *aux) |
const std::string & | filename (void) const |
filename of bam file | |
Protected Attributes | |
samfile_t * | sf_ |
This class supports writing to a bam file.
theplu::yat::omic::OutBamFile::OutBamFile | ( | void | ) |
Create an output bam file
theplu::yat::omic::OutBamFile::OutBamFile | ( | const std::string & | , |
const BamHeader & | header | ||
) |
Create an output bam file.
Equivalent to default constructor followed by a call to open(2).
|
inlineprotectedinherited |
filename of bam file
The filename is set in open_base().
|
inherited |
true
iff open void theplu::yat::omic::OutBamFile::open | ( | const std::string & | fn, |
const BamHeader & | hdr | ||
) |
Open an output bam file.
Opens an output bam file and writes the header contained in hdr. If fn is "-", stdout
is used.
fn | string specifying the filename |
hdr | header |
|
protectedinherited |
open a bam file named fn with mode mode
void theplu::yat::omic::OutBamFile::write | ( | const BamRead & | read | ) |
write a read to output file
utility::runtime_error | if write failed |
|
protectedinherited |
bam file handler