Package edu.wisc.game.sql
Class GameGenerator
java.lang.Object
edu.wisc.game.sql.GameGenerator
- Direct Known Subclasses:
- PredefinedBoardGameGenerator,- RandomGameGenerator,- RandomImageGameGenerator,- TrivialGameGenerator
A GameGenerator generates random games (with the same rule set and
    randomly created initial boards) based on the provided parameter
    range specifications
- 
Nested Class SummaryNested Classes
- 
Method SummaryModifier and TypeMethodDescriptionvoidadvance(int n) Advances the counter.For Captive server, to be priented via JSON Reflect.getRules()booleanstatic GameGeneratormkGameGenerator(RandomRG _random, ParaSet para) Creates a GameGenerator based on a parameter set.abstract GamenextGame()Generates the next game to playvoidsetConditions(boolean _testing, RuleSet _condRules) For the training/testing restrictions on boards, as introduced in GS 6.010.voidsetTesting(boolean _testing) 
- 
Method Details- 
getRules
- 
nextGameGenerates the next game to play
- 
advancepublic void advance(int n) Advances the counter. This can be used to resume an interrupted series, so that e.g. a predefined board from the correct position in the list would be used next.- Parameters:
- n- advance the counter as if n games have been created
 
- 
mkGameGeneratorpublic static GameGenerator mkGameGenerator(RandomRG _random, ParaSet para) throws IOException, RuleParseException, IllegalInputException, ReflectiveOperationException Creates a GameGenerator based on a parameter set. Depending on which parameters are set, a PredefinedBoardGameGenerator or a RandomGameGenerator may be returned.- Parameters:
- para- The parameter set for which we will create a suitable GameGenerator
- Throws:
- IOException
- RuleParseException
- IllegalInputException
- ReflectiveOperationException
 
- 
getTestingpublic boolean getTesting()
- 
setTestingpublic void setTesting(boolean _testing) 
- 
setConditionsFor the training/testing restrictions on boards, as introduced in GS 6.010. See email discusion with Paul on 2023-03-08, and captive.html#cond
- 
getAllFeaturesFor Captive server, to be priented via JSON Reflect.
 
-