antsim.genie
Interface GeneticNest

All Superinterfaces:
Clearable, Nest
All Known Implementing Classes:
LocalGeneticNest

public interface GeneticNest
extends Nest

The GeneticNest interface extends Nest with methods for managing genetic codes to be used in the creation of new ants during the evaluation of the fitness of a genetic ant algorithm.

Version:
$Revision: 1.2 $
Author:
Alberto Montresor

Field Summary
 
Fields inherited from interface anthill.nest.Nest
NAME
 
Method Summary
 void addGeneticCode(GeneticCode code)
          Add a new genetic code to the set of genetic codes known to this nest.
 
Methods inherited from interface anthill.nest.Nest
addAntNeighbour, addClientNeighbour, createResourceManager, getNeighbours, getNestId, getResourceManager, removeNeighbour, request
 
Methods inherited from interface anthill.util.Clearable
clear
 

Method Detail

addGeneticCode

public void addGeneticCode(GeneticCode code)
Add a new genetic code to the set of genetic codes known to this nest. When creating a new ant, this nest may choose from one of the available genetic codes. If an implementation of GeneticNest does not enable the use of more than one genetic code, duplicated invocations of addGeneticCode() must throw an IllegalStateException.

Parameters:
code - the genetic code to be added
Throws:
IllegalStateException - if no other genetic code can be added to this nest