edu.usc.cse.desi.algorithm
Class ExactAlgorithm
java.lang.Object
edu.usc.cse.desi.algorithm.AbstractAlgorithm
edu.usc.cse.desi.algorithm.ExactAlgorithm
- public class ExactAlgorithm
- extends AbstractAlgorithm
Here is the exact algorithm. It is pretty slow at least in terms of its order. (and also in terms
of its execution, making it slow in every possible way.)
- Author:
- NeLs
Started on Aug 9, 2004
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
myMaxAvailability
private double myMaxAvailability
myBestDeployment
private DESIViewModel myBestDeployment
ExactAlgorithm
public ExactAlgorithm()
executeAlgo
protected DESIViewModel executeAlgo(DESIViewModel cur_model)
- Here we execute the exact algorithm. In short, we try every possible
combination and see which one is the best.
I overrode this method:
- Specified by:
executeAlgo in class AbstractAlgorithm
- Parameters:
cur_model - DESIViewModel - The current model of the system.
- Returns:
- DESIViewModel - The affected model of the system.
- See Also:
AbstractAlgorithm.executeAlgo(edu.usc.cse.desi.model.view.DESIViewModel)
removeComponentsFromHosts
private void removeComponentsFromHosts(java.util.List list_of_hosts,
DESIViewModel desi_model)
- A method meant to only be called by this class, if you pass it a list
of host data models and it will remove all of their components.
addFixedComponents
private void addFixedComponents(java.util.List list_of_comps)
- This method will, given a list of component view models, will add all these components
to their required hosts.
- Parameters:
list_of_comps -
checkConstraintsAreSatisfied
private void checkConstraintsAreSatisfied(DESIViewModel model)
throws NoValidDeploymentException
- This method does what its name says. THis has to be THE slowest possible
way to do this, but I guess that's in keeping with out ultra-slow exact
algorithm.
- Parameters:
model -
- Throws:
NoValidDeploymentException