org.ggp.base.util.statemachine.StateMachineFactory Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of alloy-ggp-base Show documentation
Show all versions of alloy-ggp-base Show documentation
A modified version of the GGP-Base library for Alloy.
The newest version!
package org.ggp.base.util.statemachine;
import java.util.List;
import org.ggp.base.util.game.Game;
import org.ggp.base.util.gdl.grammar.Gdl;
import org.ggp.base.util.ruleengine.StateMachineRuleEngine;
import org.ggp.base.util.ruleengine.StdRuleEngine;
public interface StateMachineFactory {
public default T buildInitializedForGame(Game game) {
return buildInitializedForRules(game.getRules());
}
public T buildInitializedForRules(List rules);
public default StdRuleEngine buildEngineForGame(Game game) {
return StateMachineRuleEngine.wrap(buildInitializedForGame(game));
}
}