yat
0.20.3pre
|
class handling the INFO field in an VCF entry More...
#include <yat/omic/VCF.h>
Public Member Functions | |
Info (void)=default | |
default constructor | |
void | add (const std::string &key) |
template<typename T > | |
void | add (const std::string &key, const T &value) |
void | clear (void) |
size_t | count (const std::string &key) const |
template<typename T > | |
void | get (T &result, const std::string &key) const |
void | remove (const std::string &key) |
remove Info entry with key key | |
void | set (const std::string &s) |
void | set (std::string &&s) |
const std::string & | str (void) const |
template<typename T > | |
void | set (const std::string &key, const T &value) |
Friends | |
class | VCF |
std::ostream & | operator<< (std::ostream &, const VCF::Info &) |
Related Functions | |
(Note that these are not member functions.) | |
std::ostream & | operator<< (std::ostream &os, const VCF::Info &info) |
output operator for VCF::Info More... | |
class handling the INFO field in an VCF entry
void theplu::yat::omic::VCF::Info::add | ( | const std::string & | key | ) |
Add entry key to semicolon-delimited list of entries.
If key is already present, the behaviour is undefined.
void theplu::yat::omic::VCF::Info::add | ( | const std::string & | key, |
const T & | value | ||
) |
T is either string or numeric or a std::vector with strings or numerics.
If key is already present, the behaviour is undefined.
void theplu::yat::omic::VCF::Info::clear | ( | void | ) |
Clear Info field.
size_t theplu::yat::omic::VCF::Info::count | ( | const std::string & | key | ) | const |
void theplu::yat::omic::VCF::Info::get | ( | T & | result, |
const std::string & | key | ||
) | const |
get value corresponding to key. If key is not present, result is as value is empty string.
T is string, numeric, vector<string> or vector<numeric>
void theplu::yat::omic::VCF::Info::set | ( | const std::string & | s | ) |
Set info to s
void theplu::yat::omic::VCF::Info::set | ( | std::string && | s | ) |
Set info to s
void theplu::yat::omic::VCF::Info::set | ( | const std::string & | key, |
const T & | value | ||
) |
If key is absent, equivalent to call add(key, value). If key present, erase its value and set to value.
T is either string or numeric or a std::vector with strings or numerics.
const std::string& theplu::yat::omic::VCF::Info::str | ( | void | ) | const |
|
related |
output operator for VCF::Info