public class Player extends AbstractPlayer
| Modifier and Type | Field and Description |
|---|---|
private AccusationStrategy |
accusation |
private CardSet |
hand |
private int |
number |
private ResponseStrategy |
response |
private SuspicionStrategy |
suspicion |
| Constructor and Description |
|---|
Player(Card one,
Card two,
int number,
KripkeModel model,
java.lang.String suspicion,
java.lang.String response,
java.lang.String accusation)
Constructor for Player class
|
Player(CardSet hand,
int number,
KripkeModel model)
Constructor for Player class
|
Player(CardSet hand,
int number,
KripkeModel model,
java.lang.String suspicion,
java.lang.String response,
java.lang.String accusation)
Constructor for Player class
|
Player(CardSet hand,
int number,
KripkeModel model,
SuspicionStrategy suspicion,
ResponseStrategy response,
AccusationStrategy accusation)
Constructor for Player class
|
| Modifier and Type | Method and Description |
|---|---|
CardSet |
accuse()
the accusation function, determines an accusation
|
java.lang.String |
getAccusationStrategy()
Get the AccusationStrategy played
|
CardSet |
getHand()
Get the Hand of the agent
|
int |
getNumber()
Get the number of the agent in the model
|
java.lang.String |
getResponseStrategy()
Get the ResponseStrategy played
|
StrategySet |
getStrategies()
Get the strategies played by this agent
|
java.lang.String |
getSuspicionStrategy()
Get the SuspicionStrategy played
|
Card |
response(CardSet query,
int other)
the response function, determines if a response is to be made
|
CardSet |
suspect()
the suspect function, determines if a suspicion is pronounced
|
doesConsider, doesKnow, getAgents, getCardCategories, getCardsForCategoryprivate SuspicionStrategy suspicion
private ResponseStrategy response
private AccusationStrategy accusation
private CardSet hand
private int number
public Player(Card one, Card two, int number, KripkeModel model, java.lang.String suspicion, java.lang.String response, java.lang.String accusation)
one - the first card in the player's handtwo - the first card in the player's handnumber - the player's index numbermodel - the model played insuspicion - the suspicion strategyresponse - the response strategyaccusation - the accusation strategypublic Player(CardSet hand, int number, KripkeModel model)
hand - a CardSet cards that the player hasnumber - the player's index numbermodel - the model played inpublic Player(CardSet hand, int number, KripkeModel model, java.lang.String suspicion, java.lang.String response, java.lang.String accusation)
hand - a CardSet cards that the player hasnumber - the player's index numbermodel - the model played insuspicion - the suspicion strategyresponse - the response strategyaccusation - the accusation strategypublic Player(CardSet hand, int number, KripkeModel model, SuspicionStrategy suspicion, ResponseStrategy response, AccusationStrategy accusation)
hand - a CardSet cards that the player hasnumber - the player's index numbermodel - the model played insuspicion - the suspicion strategyresponse - the response strategyaccusation - the accusation strategypublic CardSet accuse()
public Card response(CardSet query, int other)
query - the query madeother - the agent requesting responsepublic CardSet suspect()
public CardSet getHand()
public int getNumber()
getNumber in class AbstractPlayerpublic StrategySet getStrategies()
public java.lang.String getAccusationStrategy()
public java.lang.String getResponseStrategy()
public java.lang.String getSuspicionStrategy()