MCScheduling 1.0
Set of Algorithms for Solving Mixed-Criticality Scheduling
Public Member Functions
MCScheduling.GeneticAlgorithm.IChromosomePool Interface Reference

An interface for implementation of a chromosome pool. More...

Inheritance diagram for MCScheduling.GeneticAlgorithm.IChromosomePool:
MCScheduling.GeneticAlgorithm.CChromosomePool

List of all members.

Public Member Functions

IChromosome acquire ()
 Returns a chromosome from the pool.
void release (IChromosome chromosome)
 Puts the specified chromosome into the pool so it may be reused.
void setMaximumSize (int size)
 Sets the capacity of the pool.
void clear ()
 Empties the chromosome pool.

Detailed Description

An interface for implementation of a chromosome pool.

The pool may be used to store reusable chromosome instances, so instead of creating new chromosome instances, the chromosomes from the pool may be used which give a performance boost proportional to the complexity of chromosome's construction.


Member Function Documentation

IChromosome MCScheduling.GeneticAlgorithm.IChromosomePool.acquire ( )

Returns a chromosome from the pool.

If the pool is empty, null is returned.

Returns:
A chromosome, or null, if the pool is empty.

Implemented in MCScheduling.GeneticAlgorithm.CChromosomePool.

void MCScheduling.GeneticAlgorithm.IChromosomePool.release ( IChromosome  chromosome)

Puts the specified chromosome into the pool so it may be reused.

Parameters:
chromosomeThe chromosome to be added into the pool.

Implemented in MCScheduling.GeneticAlgorithm.CChromosomePool.

void MCScheduling.GeneticAlgorithm.IChromosomePool.setMaximumSize ( int  size)

Sets the capacity of the pool.

Any chromosome added when the pool is at its maximum capacity is discarded.

Parameters:
sizeThe size of the pool.

Implemented in MCScheduling.GeneticAlgorithm.CChromosomePool.

 All Classes Namespaces Functions Variables Properties