Interface DoublingContext
- All Known Implementing Classes:
DoubleDecisionContext, DoubleOpportunityContext
public interface DoublingContext
Common pre-roll context for stake-doubling decisions in a staked game.
-
Method Summary
Modifier and TypeMethodDescriptionclock()Returns the game clock, ornullfor an untimed game.default StringReturns the seat owning the cube, ornullif centered.default intReturns the doubling cube multiplier.default Stringcurrency()Returns the stake currency name.default longReturns the current active stake in whole currency units.decision()Returns the typed doubling decision.default StringReturns the opaque decision identifier for this doubling episode.dfen()Returns the pre-roll position; no dice are present.doubling()Returns the complete doubling state.gameId()Returns the game's unique identifier.default longReturns the initial stake in whole currency units.default intReturns the configured maximum multiplier cap.default booleanReturns whether the decision actor is eligible to offer a double.default longReturns the proposed doubled stake in whole currency units.seat()Returns the decision actor's seat, exactlyWhiteorBlack.default StringturnSeat()Returns the seat whose turn it is.longversion()Returns the authoritative game-state version carried by the delivery.
-
Method Details
-
gameId
-
seat
-
version
long version()Returns the authoritative game-state version carried by the delivery.- Returns:
- the version
-
dfen
-
clock
-
doubling
-
decision
-
decisionId
Returns the opaque decision identifier for this doubling episode.- Returns:
- the decision id
-
currentStake
default long currentStake()Returns the current active stake in whole currency units.- Returns:
- the current stake
-
proposedStake
default long proposedStake()Returns the proposed doubled stake in whole currency units.- Returns:
- the proposed stake
-
initialStake
default long initialStake()Returns the initial stake in whole currency units.- Returns:
- the initial stake
-
cubeValue
default int cubeValue()Returns the doubling cube multiplier.- Returns:
- the cube value
-
cubeOwner
Returns the seat owning the cube, ornullif centered.- Returns:
- the cube owner seat or
null
-
maximumMultiplier
default int maximumMultiplier()Returns the configured maximum multiplier cap.- Returns:
- the maximum multiplier
-
mayOfferDouble
default boolean mayOfferDouble()Returns whether the decision actor is eligible to offer a double.- Returns:
trueif eligible to offer
-
turnSeat
-
currency
-