42 for (
size_t i = 0; i < site.
size(); ++i)
44 if (site[i] !=
operator[](i))
106 Site(
const std::vector<std::string>& site, std::shared_ptr<const Alphabet>&
alphabet) :
121 Site(
const std::vector<std::string>& site, std::shared_ptr<const Alphabet>&
alphabet,
int coordinate) :
135 Site(
const std::vector<int>& site, std::shared_ptr<const Alphabet>&
alphabet) :
150 Site(
const std::vector<int>& site, std::shared_ptr<const Alphabet>
alphabet,
int coordinate) :
190 return getAlphabet()->isResolvedIn((*
this)[sequencePosition], state) ? 1. : 0.;
A partial implementation of the CoreSite interface.
AbstractCoreSite & operator=(const CoreSiteInterface &site)
int getCoordinate() const override
Get the coordinate associated to this site.
A partial implementation of a SymbolList object.
const Alphabet & alphabet() const override
std::shared_ptr< const Alphabet > getAlphabet() const override
size_t size() const override
AbstractTemplateSymbolList< T > & operator=(const TemplateCoreSymbolListInterface< T > &list)
The generic assignment operator.
virtual int getCoordinate() const =0
Get the coordinate associated to this site.
virtual size_t size() const =0
Get the number of elements in the list.
The specific IntSymbolList interface.
A basic IntSymbolList object.
IntSymbolList & operator=(const IntSymbolListInterface &list)
The generic assignment operator.
virtual bool operator==(const SiteInterface &site)
SiteInterface * clone() const override=0
virtual bool operator<(const SiteInterface &site)
double getStateValueAt(size_t sequencePosition, int state) const
get value of a state at a position
Site & operator=(const Site &s)
The assignment operator.
Site(const std::vector< int > &site, std::shared_ptr< const Alphabet > alphabet, int coordinate)
Build a new Site object with the specified alphabet and position. The content of the site is initiali...
Site(const std::vector< std::string > &site, std::shared_ptr< const Alphabet > &alphabet)
Build a new Site object with the specified alphabet. The content of the site is initialized from a ve...
Site(const std::vector< int > &site, std::shared_ptr< const Alphabet > &alphabet)
Build a new Site object with the specified alphabet. The content of the site is initialized from a ve...
Site(const Site &site)
The copy constructor.
Site(std::shared_ptr< const Alphabet > &alphabet, int coordinate)
Build a new void Site object with the specified alphabet and position.
Site(const std::vector< std::string > &site, std::shared_ptr< const Alphabet > &alphabet, int coordinate)
Build a new Site object with the specified alphabet and position. The content of the site is initiali...
Site(std::shared_ptr< const Alphabet > &alphabet)
Build a new void Site object with the specified alphabet.
This alphabet is used to deal NumericAlphabet.