bpp-phyl  2.2.0
bpp::Mapping Class Referenceabstract

General interface for storing mapping data. More...

#include <Bpp/Phyl/Mapping/Mapping.h>

+ Inheritance diagram for bpp::Mapping:
+ Collaboration diagram for bpp::Mapping:

Public Member Functions

 Mapping ()
 
virtual ~Mapping ()
 
Mappingclone () const =0
 
virtual const TreegetTree () const =0
 
virtual bool isEmpty () const =0
 
virtual size_t getNumberOfSites () const =0
 
virtual size_t getNumberOfBranches () const =0
 
virtual int getSitePosition (size_t index) const =0
 
virtual std::vector< double > getBranchLengths () const =0
 
virtual size_t getNodeIndex (int nodeId) const =0 throw (NodeNotFoundException)
 
virtual void setSitePosition (size_t index, int position)=0
 Set the position of a given site. More...
 

Detailed Description

General interface for storing mapping data.

Definition at line 59 of file Mapping.h.

Constructor & Destructor Documentation

◆ Mapping()

bpp::Mapping::Mapping ( )
inline

Definition at line 64 of file Mapping.h.

◆ ~Mapping()

virtual bpp::Mapping::~Mapping ( )
inlinevirtual

Definition at line 65 of file Mapping.h.

Member Function Documentation

◆ clone()

◆ getBranchLengths()

virtual std::vector<double> bpp::Mapping::getBranchLengths ( ) const
pure virtual
Returns
A vector with all tree branch lengths.

Implemented in bpp::AbstractMapping.

◆ getNodeIndex()

virtual size_t bpp::Mapping::getNodeIndex ( int  nodeId) const
throw (NodeNotFoundException
)
pure virtual
Parameters
nodeIdAn id of the node to look for in the map.
Returns
The mapping index for the specified node id.

Implemented in bpp::AbstractMapping.

◆ getNumberOfBranches()

◆ getNumberOfSites()

virtual size_t bpp::Mapping::getNumberOfSites ( ) const
pure virtual

◆ getSitePosition()

virtual int bpp::Mapping::getSitePosition ( size_t  index) const
pure virtual
Parameters
indexThe site index.
Returns
The site position corresponding to the index.

Implemented in bpp::AbstractMapping.

◆ getTree()

virtual const Tree& bpp::Mapping::getTree ( ) const
pure virtual
Returns
Get the phylogenetic tree associated to this mapping.

Implemented in bpp::AbstractMapping.

◆ isEmpty()

virtual bool bpp::Mapping::isEmpty ( ) const
pure virtual
Returns
True is the map is empty, that is, if no tree is associated to the map yet.

Implemented in bpp::AbstractMapping.

◆ setSitePosition()

virtual void bpp::Mapping::setSitePosition ( size_t  index,
int  position 
)
pure virtual

Set the position of a given site.

Warning
No index checking is performed, use with care!
Parameters
indexThe site index.
positionThe position of the site.

Implemented in bpp::AbstractMapping.


The documentation for this class was generated from the following file: