Package edu.wisc.game.sql
Class EpisodeInfo
- java.lang.Object
-
- edu.wisc.game.sql.Episode
-
- edu.wisc.game.sql.EpisodeInfo
-
@Entity public class EpisodeInfo extends Episode
An EpisodeInfo instance extends an Episode, containing additional information related to it being played as part of an experiment. That includes support for creating an Episode based on a parameter set, and for managing earned reward amount.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classEpisodeInfo.ExtendedDisplayProvides some extra information related to the episode's context within the experiment.-
Nested classes/interfaces inherited from class edu.wisc.game.sql.Episode
Episode.CODE, Episode.Display, Episode.FINISH_CODE, Episode.Move, Episode.OutputMode, Episode.Pick
-
-
Field Summary
Fields Modifier and Type Field Description static HashMap<String,Episode>globalAllEpisodes-
Fields inherited from class edu.wisc.game.sql.Episode
episodeId, NBU, ruleLineNo, version
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcache()Episode.DisplaydoMove(int y, int x, int by, int bx, int _attemptCnt)Calls Episode.doMove, and then does various adjustments related to this episode's role in the experiment plan.Episode.DisplaydoPick(int y, int x, int _attemptCnt)Evaluate a pick attemptBoardgetCurrentBoard()Shows tHe current board (including dropped pieces, which are labeled as such)StringgetGuess()intgetGuessConfidence()booleangetGuessSaved()PlayerInfogetPlayer()intgetSeriesNo()booleanisBonus()static EpisodelocateEpisode(String eid)Episode.DisplaymkDisplay()Builds a display to be sent out over the web UIStringreport()Concise report, handy for debuggingvoidsaveGuessToFile(File f, String guessText, int confidence)voidsetBonus(boolean _bonus)voidsetGuess(String _guess)voidsetGuessConfidence(int _guessConfidence)voidsetGuessSaved(boolean _guessSaved)voidsetPlayer(PlayerInfo _player)voidsetSeriesNo(int _seriesNo)ParaSetxgetPara()-
Methods inherited from class edu.wisc.game.sql.Episode
getEpisodeId, getNPiecesStart, getStartTime, graphicDisplay, graphicDisplay, graphicDisplayAscii, playGame, setEpisodeId, setNPiecesStart, setStartTime
-
-
-
-
Method Detail
-
getPlayer
public PlayerInfo getPlayer()
-
setPlayer
public void setPlayer(PlayerInfo _player)
-
cache
public void cache()
-
isBonus
public boolean isBonus()
-
setBonus
public void setBonus(boolean _bonus)
-
getSeriesNo
public int getSeriesNo()
-
setSeriesNo
public void setSeriesNo(int _seriesNo)
-
getGuessSaved
public boolean getGuessSaved()
-
setGuessSaved
public void setGuessSaved(boolean _guessSaved)
-
getGuess
public String getGuess()
-
setGuess
public void setGuess(String _guess)
-
getGuessConfidence
public int getGuessConfidence()
-
setGuessConfidence
public void setGuessConfidence(int _guessConfidence)
-
xgetPara
public ParaSet xgetPara()
-
doMove
public Episode.Display doMove(int y, int x, int by, int bx, int _attemptCnt) throws IOException
Calls Episode.doMove, and then does various adjustments related to this episode's role in the experiment plan. If the player has failed to complete a bonus episode on time, this is the place that sets the "lost" flag.- Overrides:
doMovein classEpisode- Throws:
IOException
-
doPick
public Episode.Display doPick(int y, int x, int _attemptCnt) throws IOException
Description copied from class:EpisodeEvaluate a pick attempt- Overrides:
doPickin classEpisode- Throws:
IOException
-
report
public String report()
Concise report, handy for debugging
-
getCurrentBoard
public Board getCurrentBoard()
Shows tHe current board (including dropped pieces, which are labeled as such)- Overrides:
getCurrentBoardin classEpisode
-
mkDisplay
public Episode.Display mkDisplay()
Builds a display to be sent out over the web UI
-
-