bpp-popgen3
3.0.0
|
The MonoAlleleMonolocusGenotype class. More...
#include <Bpp/PopGen/MonoAlleleMonolocusGenotype.h>
Public Member Functions | |
MonoAlleleMonolocusGenotype (size_t alleleIndex) | |
Build a monolocus genotype containing one allele. More... | |
MonoAlleleMonolocusGenotype (std::vector< size_t > alleleIndex) | |
Build a monolocus genotype containing one allele. More... | |
MonoAlleleMonolocusGenotype (const MonoAlleleMonolocusGenotype &mmg) | |
Copy constructor. More... | |
virtual | ~MonoAlleleMonolocusGenotype ()=default |
Destroy the MonoAlleleMonolocusGenotype. More... | |
MonoAlleleMonolocusGenotype & | operator= (const MonoAlleleMonolocusGenotype &mmg) |
The affectation operator. More... | |
virtual bool | operator== (const MonoAlleleMonolocusGenotype &mmg) const |
The == operator. More... | |
The MonolocusGenotype interface: | |
std::vector< size_t > | getAlleleIndex () const override |
Get the alleles' index. More... | |
The Clonable interface: | |
MonoAlleleMonolocusGenotype * | clone () const override |
Private Attributes | |
size_t | alleleIndex_ |
The MonoAlleleMonolocusGenotype class.
Definition at line 20 of file MonoAlleleMonolocusGenotype.h.
MonoAlleleMonolocusGenotype::MonoAlleleMonolocusGenotype | ( | size_t | alleleIndex | ) |
Build a monolocus genotype containing one allele.
Definition at line 12 of file MonoAlleleMonolocusGenotype.cpp.
Referenced by clone().
MonoAlleleMonolocusGenotype::MonoAlleleMonolocusGenotype | ( | std::vector< size_t > | alleleIndex | ) |
Build a monolocus genotype containing one allele.
Definition at line 15 of file MonoAlleleMonolocusGenotype.cpp.
References alleleIndex_.
MonoAlleleMonolocusGenotype::MonoAlleleMonolocusGenotype | ( | const MonoAlleleMonolocusGenotype & | mmg | ) |
Copy constructor.
Definition at line 22 of file MonoAlleleMonolocusGenotype.cpp.
|
virtualdefault |
Destroy the MonoAlleleMonolocusGenotype.
|
inlineoverridevirtual |
Implements bpp::MonolocusGenotypeInterface.
Definition at line 71 of file MonoAlleleMonolocusGenotype.h.
References MonoAlleleMonolocusGenotype().
|
overridevirtual |
Get the alleles' index.
The alleles' index are the position of the AlleleInfo in a LocusInfo object. If no LocusInfo is used, the index are just numbers to identify the alleles.
The size of the vector corresponds to the number of alleles at this locus.
Implements bpp::MonolocusGenotypeInterface.
Definition at line 38 of file MonoAlleleMonolocusGenotype.cpp.
References alleleIndex_.
Referenced by operator=(), and operator==().
MonoAlleleMonolocusGenotype & MonoAlleleMonolocusGenotype::operator= | ( | const MonoAlleleMonolocusGenotype & | mmg | ) |
The affectation operator.
Definition at line 27 of file MonoAlleleMonolocusGenotype.cpp.
References alleleIndex_, and getAlleleIndex().
|
virtual |
The == operator.
Definition at line 33 of file MonoAlleleMonolocusGenotype.cpp.
References alleleIndex_, and getAlleleIndex().
|
private |
Definition at line 24 of file MonoAlleleMonolocusGenotype.h.
Referenced by getAlleleIndex(), MonoAlleleMonolocusGenotype(), operator=(), and operator==().