org.dbe.eve.ga.impl
Class SolutionImpl

java.lang.Object
  extended by org.dbe.eve.ga.impl.SolutionImpl
All Implemented Interfaces:
java.io.Serializable, PrivateSolution, Solution

public class SolutionImpl
extends java.lang.Object
implements PrivateSolution, java.io.Serializable

This class represent one simple solution for a bussiness model. This is a set of services that can fit the model.

Author:
bob
See Also:
Serialized Form

Constructor Summary
SolutionImpl()
           
SolutionImpl(float fitnessValue, EvEService[] solution)
          Constructor.
 
Method Summary
 float getFitnessValue()
           
 EvEService[] getServices()
          The Set of Services of which this solution consists
 EvEService[] getSolution()
           
 int getSolutionSize()
          Return the number of services (0 if none)
 boolean isEvaluated()
           
 void setEvaluated(boolean evaluated)
           
 void setFitnessValue(float fitnessValue)
           
 void setSolution(EvEService[] solution)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SolutionImpl

public SolutionImpl()

SolutionImpl

public SolutionImpl(float fitnessValue,
                    EvEService[] solution)
Constructor. If solution = null it will be discarted

Parameters:
fitnessValue - Associated Fitness
solution - The Set of Services of which this solution consists
Method Detail

getServices

public EvEService[] getServices()
The Set of Services of which this solution consists

Specified by:
getServices in interface Solution
Returns:
EvESerice Array of Services

getSolutionSize

public int getSolutionSize()
Return the number of services (0 if none)

Specified by:
getSolutionSize in interface Solution
Returns:
int the number of services

getFitnessValue

public float getFitnessValue()
Specified by:
getFitnessValue in interface Solution
Returns:
Returns the fitnessValue.

setFitnessValue

public void setFitnessValue(float fitnessValue)
Specified by:
setFitnessValue in interface PrivateSolution

isEvaluated

public boolean isEvaluated()
Returns:
Returns the evaluated.

setEvaluated

public void setEvaluated(boolean evaluated)
Parameters:
evaluated - The evaluated to set.

getSolution

public EvEService[] getSolution()
Returns:
Returns the solution.

setSolution

public void setSolution(EvEService[] solution)
Parameters:
solution - The solution to set.