ARB
Public Member Functions | Static Public Member Functions | List of all members
RootSynchronizer Class Reference

#include <SyncRoot.hxx>

Inheritance diagram for RootSynchronizer:
Inheritance graph
[legend]
Collaboration diagram for RootSynchronizer:
Collaboration graph
[legend]

Public Member Functions

 RootSynchronizer ()
 
int add (SizeAwareTree *&tree, const char *treename)
 
SizeAwareTree * take_tree (int idx)
 
void beginDeconstructionPhase ()
 
bool deconstructionPhase () const
 
GB_ERROR deconstruct_all_trees (bool provideProgress)
 
bool allTreesDeconstructed () const
 
ErrorOrSizeAwareTreePtr find_best_root_candidate (int inTree, int accordingToTree, int &best_dist, bool provideProgress)
 
MultirootPtr get_innermost_edges () const
 
ErrorOrMultirootPtr get_current_roots () const
 
ErrorOrMultirootPtr find_good_roots_for_trees (const int MAX_DEPTH, arb_progress *progress=NULp)
 
const SpeciesSpaceget_SpeciesSpace () const
 
ErrorOrDeconstructedTreePtr get_DeconstructedTree (int treeIdx)
 
const PARTget_tree_PART (int treeIdx) const
 
const PARTget_edge_PART (int treeIdx, const SizeAwareTree *sonOfEdge) const
 
int calcEdgeDistance (int i1, const SizeAwareTree *n1, int i2, const SizeAwareTree *n2) const
 
int calcTreeDistance (int i1, int i2) const
 
int minDistanceSum () const
 
- Public Member Functions inherited from TreeContainer
 ~TreeContainer ()
 
size_t get_tree_count () const
 
bool valid_tree_index (int idx) const
 
const TreeInfoget_tree_info (int idx) const
 
const SizeAwareTree * get_tree (int idx) const
 
SizeAwareTree * take_tree (int idx)
 
void get_species_names (ConstStrArray &species_names) const
 
size_t get_species_count () const
 
int add (SizeAwareTree *&tree, const char *treename)
 

Static Public Member Functions

static void find_best_matching_PART_in (int &best_dist, int &best_idx, const PART *part, const DeconstructedTree &in, const PART *tree_part, const PART *tree_in, bool provideProgress)
 
static void find_worst_matching_PART_in (int &worst_dist, int &worst_idx, const PART *part, const DeconstructedTree &in, const PART *tree_part, const PART *tree_in)
 

Detailed Description

Definition at line 100 of file SyncRoot.hxx.

Constructor & Destructor Documentation

RootSynchronizer::RootSynchronizer ( )
inline

Definition at line 116 of file SyncRoot.hxx.

Member Function Documentation

int RootSynchronizer::add ( SizeAwareTree *&  tree,
const char treename 
)
inline

Definition at line 118 of file SyncRoot.hxx.

References TreeContainer::add(), arb_assert, and deconstructionPhase().

Referenced by load_and_add_tree().

SizeAwareTree* RootSynchronizer::take_tree ( int  idx)
inline

Definition at line 122 of file SyncRoot.hxx.

References deconstructionPhase(), and TreeContainer::take_tree().

Referenced by adjustTreeRoot().

void RootSynchronizer::beginDeconstructionPhase ( )

Definition at line 18 of file SyncRoot.cxx.

References arb_assert.

bool RootSynchronizer::deconstructionPhase ( ) const
inline
GB_ERROR RootSynchronizer::deconstruct_all_trees ( bool  provideProgress)
bool RootSynchronizer::allTreesDeconstructed ( ) const
inline

Definition at line 135 of file SyncRoot.hxx.

References arb_assert, deconstructionPhase(), and TreeContainer::get_tree_count().

Referenced by get_edge_PART().

ErrorOrSizeAwareTreePtr RootSynchronizer::find_best_root_candidate ( int  inTree,
int  accordingToTree,
int best_dist,
bool  provideProgress 
)
MultirootPtr RootSynchronizer::get_innermost_edges ( ) const

Definition at line 419 of file SyncRoot.cxx.

References arb_assert, DOWNCAST, and PART_FWD::get_origin().

ErrorOrMultirootPtr RootSynchronizer::get_current_roots ( ) const

Definition at line 407 of file SyncRoot.cxx.

References NULp, and result.

Referenced by multiroot_sync_subsetTrees().

ErrorOrMultirootPtr RootSynchronizer::find_good_roots_for_trees ( const int  MAX_DEPTH,
arb_progress progress = NULp 
)
const SpeciesSpace& RootSynchronizer::get_SpeciesSpace ( ) const
inline

Definition at line 149 of file SyncRoot.hxx.

References arb_assert, and deconstructionPhase().

ErrorOrDeconstructedTreePtr RootSynchronizer::get_DeconstructedTree ( int  treeIdx)
inline

Definition at line 153 of file SyncRoot.hxx.

References error().

const PART* RootSynchronizer::get_tree_PART ( int  treeIdx) const
inline

Definition at line 157 of file SyncRoot.hxx.

References arb_assert, deconstructionPhase(), and TreeParts::get_tree_PART().

const PART* RootSynchronizer::get_edge_PART ( int  treeIdx,
const SizeAwareTree *  sonOfEdge 
) const
inline
int RootSynchronizer::calcEdgeDistance ( int  i1,
const SizeAwareTree *  n1,
int  i2,
const SizeAwareTree *  n2 
) const

Definition at line 436 of file SyncRoot.cxx.

References arb_assert, and PART_FWD::calcDistance().

int RootSynchronizer::calcTreeDistance ( int  i1,
int  i2 
) const

Definition at line 457 of file SyncRoot.cxx.

References PART_FWD::calcDistance().

int RootSynchronizer::minDistanceSum ( ) const

Definition at line 464 of file SyncRoot.cxx.

void RootSynchronizer::find_best_matching_PART_in ( int best_dist,
int best_idx,
const PART part,
const DeconstructedTree in,
const PART tree_part,
const PART tree_in,
bool  provideProgress 
)
static
void RootSynchronizer::find_worst_matching_PART_in ( int worst_dist,
int worst_idx,
const PART part,
const DeconstructedTree in,
const PART tree_part,
const PART tree_in 
)
static

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