Alps  2.0.2
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:
+ Collaboration diagram for AlpsSubTreePool:

Public Member Functions

Constructor and destructor.
 AlpsSubTreePool ()
 Default constructor. More...
 
virtual ~AlpsSubTreePool ()
 Destructor. More...
 
Querry methods
virtual int getNumKnowledges () const
 Query the number of subtrees in the pool. More...
 
virtual std::pair< AlpsKnowledge *, double > getKnowledge () const
 Get a subtree from subtree pool, doesn't remove it from the pool. More...
 
virtual bool hasKnowledge () const
 Check whether there is a subtree in the subtree 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...
 
Knowledge manipulation
virtual void addKnowledge (AlpsKnowledge *subTree, double priority)
 Add a subtree to the subtree pool. More...
 
virtual void popKnowledge ()
 Remove a subtree from the pool. More...
 
- Public Member Functions inherited from AlpsKnowledgePool
 AlpsKnowledgePool (AlpsKnowledgePoolType type)
 Default constructor. More...
 
virtual ~AlpsKnowledgePool ()
 Destructor. More...
 

Private Attributes

AlpsPriorityQueue< AlpsSubTree * > subTreeList_
 

Other functions

virtual void setMaxNumKnowledges (int num)
 Set the quantity limit of knowledges that can be stored in the pool. More...
 
virtual 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...
 
 AlpsSubTreePool (AlpsSubTreePool const &)
 Disable copy constructor. More...
 
AlpsSubTreePooloperator= (const AlpsSubTreePool &)
 Disable copy assignment operator. More...
 

Detailed Description

The subtree pool is used to store subtrees.

Definition at line 39 of file AlpsSubTreePool.h.

Constructor & Destructor Documentation

◆ AlpsSubTreePool() [1/2]

AlpsSubTreePool::AlpsSubTreePool ( )

Default constructor.

◆ ~AlpsSubTreePool()

virtual AlpsSubTreePool::~AlpsSubTreePool ( )
virtual

Destructor.

◆ AlpsSubTreePool() [2/2]

AlpsSubTreePool::AlpsSubTreePool ( AlpsSubTreePool const &  )
private

Disable copy constructor.

Member Function Documentation

◆ getNumKnowledges()

virtual int AlpsSubTreePool::getNumKnowledges ( ) const
virtual

Query the number of subtrees in the pool.

Implements AlpsKnowledgePool.

◆ getKnowledge()

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

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

Implements AlpsKnowledgePool.

◆ hasKnowledge()

virtual bool AlpsSubTreePool::hasKnowledge ( ) const
inlinevirtual

Check whether there is a subtree in the subtree pool.

Implements AlpsKnowledgePool.

Definition at line 58 of file AlpsSubTreePool.h.

◆ getMaxNumKnowledges()

virtual int AlpsSubTreePool::getMaxNumKnowledges ( ) const
inlinevirtual

Query the quantity limit of knowledges.

Implements AlpsKnowledgePool.

Definition at line 60 of file AlpsSubTreePool.h.

◆ getBestKnowledge()

virtual std::pair<AlpsKnowledge*, double> AlpsSubTreePool::getBestKnowledge ( ) const
virtual

Query the best knowledge in the pool.

Implements AlpsKnowledgePool.

◆ getAllKnowledges()

virtual void AlpsSubTreePool::getAllKnowledges ( std::vector< std::pair< AlpsKnowledge *, double > > &  kls) const
virtual

Get a reference to all the knowledges in the pool.*‍/.

Implements AlpsKnowledgePool.

◆ addKnowledge()

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

Add a subtree to the subtree pool.

Implements AlpsKnowledgePool.

◆ popKnowledge()

virtual void AlpsSubTreePool::popKnowledge ( )
inlinevirtual

Remove a subtree from the pool.

Implements AlpsKnowledgePool.

Definition at line 73 of file AlpsSubTreePool.h.

◆ setMaxNumKnowledges()

virtual void AlpsSubTreePool::setMaxNumKnowledges ( int  num)
virtual

Set the quantity limit of knowledges that can be stored in the pool.

Implements AlpsKnowledgePool.

◆ getSubTreeList()

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

Return the container of subtrees.

◆ setComparison()

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

Set comparison function and resort heap.

◆ deleteGuts()

void AlpsSubTreePool::deleteGuts ( )

Delete the subtrees in the pool.

◆ getBestQuality()

double AlpsSubTreePool::getBestQuality ( )

Get the quality of the best subtree.

◆ operator=()

AlpsSubTreePool& AlpsSubTreePool::operator= ( const AlpsSubTreePool )
private

Disable copy assignment operator.

Member Data Documentation

◆ subTreeList_

AlpsPriorityQueue<AlpsSubTree*> AlpsSubTreePool::subTreeList_
private

Definition at line 40 of file AlpsSubTreePool.h.


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