Interface IChainingReasoner
-
- All Superinterfaces:
IReasoner
- All Known Implementing Classes:
AbstractChainedReasoner
public interface IChainingReasoner extends IReasoner
A specialized interface for reasoners, which, in principle, can be chained, i.e., composed to a chain of reasoners, passing along results and configurations. The last reasoner in a chain shall create the final reasoning result, potentially taking over results of the previous ones or complementing the reasoning by resolving problems that the previous reasoners cannot solve.- Author:
- Holger Eichelberger
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ConfigurationgetLastConfiguration()Returns the last, potentially internal configuration.voidsetState(Configuration config, EvaluationResult result)Sets the state determined by the last reasoner.voidsetState(Configuration config, ReasoningResult result)Sets the state determined by the last reasoner.-
Methods inherited from interface net.ssehub.easy.reasoning.core.reasoner.IReasoner
check, createInstance, createValue, evaluate, getDescriptor, initialize, isConsistent, notify, propagate, setInterceptor, upgrade
-
-
-
-
Method Detail
-
setState
void setState(Configuration config, ReasoningResult result)
Sets the state determined by the last reasoner. If not null, project and configuration passed in through the interface ofIReasonershall be ignored.- Parameters:
config- the configuration (may be null, shall be ignored then).configmay be an internal resultresult- the last reasoning result (may be null, shall be ignored then, identifies beginning of chain). It is assumed that the constraints and variables mentioned in reasoning result fit toconfiguration
-
setState
void setState(Configuration config, EvaluationResult result)
Sets the state determined by the last reasoner. If not null, project and configuration passed in through the interface ofIReasonershall be ignored. Shall be used for#evaluate(net.ssehub.easy.varModel.model.Project, Configuration, java.util.List, ReasonerConfiguration, net.ssehub.easy.basics.progress.ProgressObserver)only.- Parameters:
config- the configuration (may be null, shall be ignored then).configmay be an internal resultresult- the last reasoning result (may be null, shall be ignored then, identifies beginning of chain). It is assumed that the constraints and variables mentioned in reasoning result fit toconfiguration
-
getLastConfiguration
Configuration getLastConfiguration()
Returns the last, potentially internal configuration. Shall be past intosetState(Configuration, ReasoningResult)of the next reasoner. Shall clear the attribute holding the last config.- Returns:
- the last, potentially internal configuration
-
-