Public Member Functions | Private Member Functions | Private Attributes | List of all members
AlpsSubTreePool Class Reference

The subtree pool is used to store subtrees. More...

#include <AlpsSubTreePool.h>

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

Public Member Functions

 AlpsSubTreePool ()
 
virtual ~AlpsSubTreePool ()
 
int getNumKnowledges () const
 Query the number of subtrees in the pool. More...
 
bool hasKnowledge () const
 Check whether there is a subtree in the subtree pool. More...
 
std::pair< AlpsKnowledge
*, double > 
getKnowledge () const
 Get a subtree from subtree pool, doesn't remove it from the pool. More...
 
void popKnowledge ()
 Remove a subtree from the pool. More...
 
void addKnowledge (AlpsKnowledge *subTree, double priority)
 Add a subtree to the subtree pool. More...
 
const AlpsPriorityQueue
< AlpsSubTree * > & 
getSubTreeList () const
 Return the container of subtrees. More...
 
void setComparison (AlpsSearchStrategy< AlpsSubTree * > &compare)
 Set comparison function and resort heap. More...
 
void deleteGuts ()
 Delete the subtrees in the pool. More...
 
double getBestQuality ()
 Get the quality of the best subtree. More...
 
- Public Member Functions inherited from AlpsKnowledgePool
 AlpsKnowledgePool ()
 
virtual ~AlpsKnowledgePool ()
 
virtual void setMaxNumKnowledges (int num)
 Set the quantity limit of knowledges that can be stored in the pool. More...
 
virtual int getMaxNumKnowledges () const
 Query the quantity limit of knowledges. More...
 
virtual std::pair
< AlpsKnowledge *, double > 
getBestKnowledge () const
 Query the best knowledge in the pool. More...
 
virtual void getAllKnowledges (std::vector< std::pair< AlpsKnowledge *, double > > &kls) const
 Get a reference to all the knowledges in the pool. More...
 

Private Member Functions

 AlpsSubTreePool (const AlpsSubTreePool &)
 
AlpsSubTreePooloperator= (const AlpsSubTreePool &)
 

Private Attributes

AlpsPriorityQueue< AlpsSubTree * > subTreeList_
 

Detailed Description

The subtree pool is used to store subtrees.

Definition at line 32 of file AlpsSubTreePool.h.

Constructor & Destructor Documentation

AlpsSubTreePool::AlpsSubTreePool ( const AlpsSubTreePool )
private
AlpsSubTreePool::AlpsSubTreePool ( )
inline

Definition at line 41 of file AlpsSubTreePool.h.

virtual AlpsSubTreePool::~AlpsSubTreePool ( )
inlinevirtual

Definition at line 42 of file AlpsSubTreePool.h.

Member Function Documentation

AlpsSubTreePool& AlpsSubTreePool::operator= ( const AlpsSubTreePool )
private
int AlpsSubTreePool::getNumKnowledges ( ) const
inlinevirtual

Query the number of subtrees in the pool.

Implements AlpsKnowledgePool.

Definition at line 49 of file AlpsSubTreePool.h.

bool AlpsSubTreePool::hasKnowledge ( ) const
inlinevirtual

Check whether there is a subtree in the subtree pool.

Reimplemented from AlpsKnowledgePool.

Definition at line 52 of file AlpsSubTreePool.h.

std::pair<AlpsKnowledge*, double> AlpsSubTreePool::getKnowledge ( ) const
inlinevirtual

Get a subtree from subtree pool, doesn't remove it from the pool.

Implements AlpsKnowledgePool.

Definition at line 55 of file AlpsSubTreePool.h.

void AlpsSubTreePool::popKnowledge ( )
inlinevirtual

Remove a subtree from the pool.

Reimplemented from AlpsKnowledgePool.

Definition at line 62 of file AlpsSubTreePool.h.

void AlpsSubTreePool::addKnowledge ( AlpsKnowledge subTree,
double  priority 
)
inlinevirtual

Add a subtree to the subtree pool.

Implements AlpsKnowledgePool.

Definition at line 67 of file AlpsSubTreePool.h.

const AlpsPriorityQueue< AlpsSubTree*>& AlpsSubTreePool::getSubTreeList ( ) const
inline

Return the container of subtrees.

Definition at line 74 of file AlpsSubTreePool.h.

void AlpsSubTreePool::setComparison ( AlpsSearchStrategy< AlpsSubTree * > &  compare)
inline

Set comparison function and resort heap.

Definition at line 77 of file AlpsSubTreePool.h.

void AlpsSubTreePool::deleteGuts ( )
inline

Delete the subtrees in the pool.

Definition at line 82 of file AlpsSubTreePool.h.

double AlpsSubTreePool::getBestQuality ( )
inline

Get the quality of the best subtree.

Definition at line 90 of file AlpsSubTreePool.h.

Member Data Documentation

AlpsPriorityQueue<AlpsSubTree*> AlpsSubTreePool::subTreeList_
private

Definition at line 38 of file AlpsSubTreePool.h.


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