NxsTreesBlock Class Reference

This class handles reading and storage for the NEXUS block TREES. More...

#include <nxstreesblock.h>

List of all members.

Public Member Functions

 NxsTreesBlock (NxsTaxaBlockAPI *tb)
virtual ~NxsTreesBlock ()
void ReplaceTaxaBlockPtr (NxsTaxaBlockAPI *tb)
unsigned GetNumDefaultTree ()
unsigned GetNumTrees ()
unsigned GetNumTrees () const
const NxsFullTreeDescriptionGetFullTreeDescription (unsigned i) const
unsigned TreeLabelToNumber (const std::string &name) const
NxsString GetTreeName (unsigned i)
NxsString GetTreeDescription (unsigned i)
NxsString GetTranslatedTreeDescription (unsigned i)
bool IsDefaultTree (unsigned i)
bool IsRootedTree (unsigned i)
virtual void Report (std::ostream &out) NCL_COULD_BE_CONST
virtual void BriefReport (NxsString &s) NCL_COULD_BE_CONST
virtual void Reset ()
void SetNexus (NxsReader *nxsptr)
virtual const std::string & GetBlockName () const
void WriteAsNexus (std::ostream &out) const
virtual VecBlockPtr GetImpliedBlocks ()
virtual void HandleLinkCommand (NxsToken &token)
virtual void WriteLinkCommand (std::ostream &out) const
unsigned GetIndicesForLabel (const std::string &label, NxsUnsignedSet *inds) const
bool AddNewPartition (const std::string &label, const NxsPartition &inds)
bool GetProcessAllTreesDuringParse () const
void SetProcessAllTreesDuringParse (bool s)
void setValidationCallbacks (ProcessedTreeValidationFunction func, void *blob)

Protected Member Functions

virtual void Read (NxsToken &token)

Protected Attributes

bool processAllTreesDuringParse
bool constructingTaxaBlock
bool writeFromNodeEdgeDataStructure
std::vector
< NxsFullTreeDescription
trees

Detailed Description

This class handles reading and storage for the NEXUS block TREES.

The class can read the TRANSLATE and TREE commands.

The tree is validated during the parse and then stored as a NxsFullTreeDescription object which will hold the newick string. This newick string will have numbers rather than names. The numbers in the tree string start at 1 (like other NEXUS numbering), but they are simply 1 + the taxon index.

In previous versions of NCL (before v2.1), the client code would have to use the translate table to convert the newick string into the taxon numbers.

As of v2.1, NCL now does this translation.

Definition at line 553 of file nxstreesblock.h.


The documentation for this class was generated from the following files:
 All Classes Functions Variables Enumerations Enumerator Friends
Generated on Mon Mar 29 16:37:13 2010 for NCL by  doxygen 1.6.3