mets::tabu_list_chain Class Reference

An abstract tabu list. More...

#include <mets.h>

Inherited by mets::simple_tabu_list.

Inheritance diagram for mets::tabu_list_chain:

Inheritance graph
[legend]
Collaboration diagram for mets::tabu_list_chain:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 tabu_list_chain (const tabu_list_chain &)
 purposely not implemented (see Effective C++)
tabu_list_chainoperator= (const tabu_list_chain &)
 purposely not implemented (see Effective C++)
 tabu_list_chain (unsigned int tenure)
 Create an abstract tabu list with a certain tenure.
 tabu_list_chain (tabu_list_chain *next, unsigned int tenure)
 Create an abstract tabu list with a certain tenure and a chained tabu list that decorates this one.
virtual ~tabu_list_chain ()
 Virtual destructor.
virtual void tabu (feasible_solution &sol, move &mov)=0
 Make a move tabu when starting from a certain solution.
virtual bool is_tabu (feasible_solution &sol, move &mov)=0
 True if the move is tabu for the given solution.
virtual unsigned int tenure ()
 Tenure of this tabu list.
virtual unsigned int tenure (unsigned int tenure)=0
 Tenure of this tabu list.

Protected Attributes

tabu_list_chainnext_m
unsigned int tenure_m

Detailed Description

An abstract tabu list.

This is chainable so that tabu lists can be decorated with other tabu lists.

Definition at line 340 of file mets.h.


Constructor & Destructor Documentation

mets::tabu_list_chain::tabu_list_chain ( const tabu_list_chain  ) 

purposely not implemented (see Effective C++)

mets::tabu_list_chain::tabu_list_chain ( unsigned int  tenure  )  [inline, explicit]

Create an abstract tabu list with a certain tenure.

Definition at line 351 of file mets.h.

mets::tabu_list_chain::tabu_list_chain ( tabu_list_chain next,
unsigned int  tenure 
) [inline]

Create an abstract tabu list with a certain tenure and a chained tabu list that decorates this one.

Definition at line 356 of file mets.h.

virtual mets::tabu_list_chain::~tabu_list_chain (  )  [inline, virtual]

Virtual destructor.

Definition at line 361 of file mets.h.


Member Function Documentation

tabu_list_chain& mets::tabu_list_chain::operator= ( const tabu_list_chain  ) 

purposely not implemented (see Effective C++)

void mets::tabu_list_chain::tabu ( feasible_solution sol,
move mov 
) [pure virtual]

Make a move tabu when starting from a certain solution.

Different implementation can remember "tenure" moves, "tenure" solutions or some other peculiar fact that will avoid cycling.

Parameters:
sol The current working solution
mov The move to make tabu

Implemented in mets::simple_tabu_list.

Definition at line 108 of file tabu-search.cc.

References next_m, and tabu().

Referenced by mets::tabu_search::search(), mets::simple_tabu_list::tabu(), and tabu().

bool mets::tabu_list_chain::is_tabu ( feasible_solution sol,
move mov 
) [pure virtual]

True if the move is tabu for the given solution.

Different implementation can remember "tenure" moves, "tenure" solutions or some other peculiar fact that will avoid cycling. So it's not defined at this stage if a move will be tabu or not at a certain state of the search: this depends on the implementation.

Parameters:
sol The current working solution
mov The move to make tabu

Implemented in mets::simple_tabu_list.

Definition at line 115 of file tabu-search.cc.

References is_tabu(), and next_m.

Referenced by mets::simple_tabu_list::is_tabu(), is_tabu(), and mets::tabu_search::search().

virtual unsigned int mets::tabu_list_chain::tenure (  )  [inline, virtual]

Tenure of this tabu list.

The tenure is the length of the tabu-list (the order of the tabu memory)

Reimplemented in mets::simple_tabu_list.

Definition at line 395 of file mets.h.

References tenure_m.

virtual unsigned int mets::tabu_list_chain::tenure ( unsigned int  tenure  )  [pure virtual]

Tenure of this tabu list.

Parameters:
tenure,: the new tenure of the list.

Implemented in mets::simple_tabu_list.


The documentation for this class was generated from the following files:
Generated on Tue Nov 21 00:58:29 2006 for METSlib by  doxygen 1.5.1