net.sourceforge.cilib.util.calculator
Class PropertyBasedFitnessCalculator

java.lang.Object
  extended by net.sourceforge.cilib.util.calculator.PropertyBasedFitnessCalculator
All Implemented Interfaces:
Serializable, FitnessCalculator<Entity>, Cloneable

public class PropertyBasedFitnessCalculator
extends Object
implements FitnessCalculator<Entity>

Author:
leo Calculates the fitness by passing the entity's blackboard to the algorithm's optimization problem
See Also:
Serialized Form

Constructor Summary
PropertyBasedFitnessCalculator()
           
 
Method Summary
 FitnessCalculator getClone()
          Create a cloned copy of the current object and return it.
 Fitness getFitness(Entity entity, boolean count)
          Get the fitness, given the position.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PropertyBasedFitnessCalculator

public PropertyBasedFitnessCalculator()
Method Detail

getClone

public FitnessCalculator getClone()
Create a cloned copy of the current object and return it. In general the created copy will be a deep copy of the provided instance. As a result this operation an be quite expensive if used incorrectly.

Specified by:
getClone in interface FitnessCalculator<Entity>
Specified by:
getClone in interface Cloneable
Returns:
An exact clone of the current object instance.
See Also:
Object.clone()

getFitness

public Fitness getFitness(Entity entity,
                          boolean count)
Get the fitness, given the position.

Specified by:
getFitness in interface FitnessCalculator<Entity>
Parameters:
entity - The Type to base the calculation on.
count - Whether or not the evaluation is to be counted.
Returns:
A Fitness object representing the fitness of the position.


Copyright © 2009 CIRG. All Rights Reserved.