Skip to content
Snippets Groups Projects

Add "Initial Guess" Search Strategy

Merged Julia Rossow requested to merge stu222169/theodolite-extensions:issue-258 into master
Files
6
 
package theodolite.strategies.searchstrategy
 
 
import io.quarkus.runtime.annotations.RegisterForReflection
 
import theodolite.util.Resource
 
 
/**
 
* Base class for the implementation of Guess strategies. Guess strategies are strategies to determine the resource
 
* demand we start with in our initial guess search strategy.
 
*/
 
 
@RegisterForReflection
 
abstract class GuessStrategy {
 
/**
 
* Computing the resource demand for the initial guess search strategy to start with.
 
*
 
* @param resources List of all possible [Resource]s.
 
* @param lastLowestResource Previous resource demand needed for the given load.
 
*
 
* @return Returns the resource demand to start the initial guess search strategy with or null
 
*/
 
abstract fun firstGuess(resources: List<Resource>, lastLowestResource: Resource?): Resource?
 
}
 
\ No newline at end of file
Loading