Skip to content

Instantly share code, notes, and snippets.

@laixintao
Created October 24, 2016 00:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save laixintao/ecf9961e4e9c9dc303a3e0c4e3b9f9e7 to your computer and use it in GitHub Desktop.
Save laixintao/ecf9961e4e9c9dc303a3e0c4e3b9f9e7 to your computer and use it in GitHub Desktop.
public class Jackpot {
private static Jackpot jackpot;
private ArrayList<Bet> betHistory;
private Jackpot() {
this.betHistory = new ArrayList<Bet>();
}
public boolean addBet(Bet bet) {
this.betHistory.add(bet);
return true;
}
public ArrayList<Bet> getBetHistory() {
return this.betHistory;
}
public static Jackpot getJackpot() {
if (jackpot == null) {
jackpot = new Jackpot();
}
return jackpot;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment