MDA
|
Represents a set of domains. More...
#include <DomainArchitecture.hpp>
Public Member Functions | |
void | add_domain (const Domain &domain) |
Appends a Domain to the architecture. More... | |
size_t | size () const |
void | resize (size_t new_size) |
size_t | length () const |
Domain & | operator[] (unsigned int index) |
const Domain & | operator[] (unsigned int index) const |
int | id () const |
Returns the id architecture. More... | |
void | id (int id) |
Sets the id of the architecture. More... | |
size_t | n_members () const |
Returns the number of sequences with this architecture. More... | |
void | n_members (size_t value) |
Sets the number of sequences having this architecture. More... | |
void | clean_up (unsigned char options) |
solves several problems of a domain architecture. More... | |
void | sort () |
Sorts the domains in the architecture according to their start. More... | |
void | insert_gaps (std::string edit_string) |
Inserts a GapDomain at the given positions. More... | |
void | collapse_repeats () |
Merges repeats to together. | |
Constructores & Destructors | |
DomainArchitecture () | |
Creates an empty DomainArchitecture. | |
virtual | ~DomainArchitecture () |
Destructor. | |
Friends | |
bool | operator== (const DomainArchitecture &dom1, const DomainArchitecture &dom2) |
Checks if to architectures are the same. More... | |
bool | operator!= (DomainArchitecture &dom1, DomainArchitecture &dom2) |
Checks if to architectures are different. More... | |
std::ostream & | operator<< (std::ostream &out, const DomainArchitecture &archi) |
Represents a set of domains.
|
inline |
Appends a Domain to the architecture.
domain | The domain |
void MDAT::DomainArchitecture::clean_up | ( | unsigned char | options | ) |
solves several problems of a domain architecture.
Function to solve conflicting domains.
Several problems can appear when
options | The options to be used ( |
This function can solve several problems which appear after domain annotation, this includes nested domains, overlapping domains and split domains
options | Determines which problem(s) have to be solved. |
|
inline |
Returns the id architecture.
|
inline |
Sets the id of the architecture.
id | The id of the architecture. |
void MDAT::DomainArchitecture::insert_gaps | ( | std::string | edit_string | ) |
Inserts a GapDomain at the given positions.
The edit_string has to be of the form "m-mm-" where '-' denote the gaps to introduce.
edit_string | String noting gap positions. |
|
inline |
Length of the architecture.
|
inline |
Returns the number of sequences with this architecture.
|
inline |
Sets the number of sequences having this architecture.
value | The number of sequences having this architecture. |
|
inline |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
|
inline |
Length of the architecture.
void MDAT::DomainArchitecture::sort | ( | ) |
Sorts the domains in the architecture according to their start.
Sorts the Domain architectures by domain start.
|
friend |
Checks if to architectures are different.
dom1 | The first architecture. |
dom2 | The second architecture. |
|
friend |
Checks if to architectures are the same.
dom1 | The first architecture. |
dom2 | The second architecture. |