/**
* Author: Joshua McMillen
*/
package games.blackjack;
import java.util.ArrayList;
import game.Card;
import games.blackjack.commands.BuildDealerList;
import games.blackjack.commands.CommandList;
/**
* Controller for the Dealer
*/
public class Dealer
{
//Initialize commands, hand, and AI.
private CommandList commL = new CommandList();
private ArrayList<Card> hand;
private AI diff;
public Dealer()
{
this(new Average());
setHand(new ArrayList<Card>());
}
//Construct Commands and set AI
public Dealer(AI diff)
{
BuildDealerList commB = new BuildDealerList();
commB.createList(getCommL());
setDiff(diff);
}
//returns commands
public CommandList getCommL()
{
return commL;
}
//sets commands
public void setCommL(CommandList commL)
{
this.commL = commL;
}
//returns hand
public ArrayList<Card> getHand()
{
return hand;
}
//sets hand
public void setHand(ArrayList<Card> hand)
{
this.hand = hand;
}
//returns AI
public AI getDiff()
{
return diff;
}
//sets AI
public void setDiff(AI diff)
{
this.diff = diff;
}
}