public class Poll extends java.lang.Object implements Sendable, java.io.Serializable
Modifier and Type | Field and Description |
---|---|
private java.sql.Date |
expiringDate |
private boolean |
isRunning |
private int |
pollID |
private java.lang.String |
pollText |
private static long |
serialVersionUID |
private java.util.HashMap<User,java.lang.Boolean> |
voteMap |
Constructor and Description |
---|
Poll(int pollID,
java.lang.String pollText,
java.sql.Date expiringDate) |
Modifier and Type | Method and Description |
---|---|
protected void |
addVote(User votingUser,
java.lang.Boolean voteValue) |
protected boolean |
checkDate() |
java.sql.Date |
getExpiringDate() |
boolean |
getIsRunning() |
int |
getPollID() |
java.lang.String |
getPollText() |
java.lang.Class<Poll> |
getType() |
java.util.HashMap<User,java.lang.Boolean> |
getVoteMap() |
java.util.Iterator<User> |
getVotesAbstensions() |
java.util.Iterator<User> |
getVotesAgainst() |
java.util.Iterator<User> |
getVotesFor() |
void |
setId(int id) |
private void |
setIsRunning(boolean isRunning) |
private static final long serialVersionUID
private java.util.HashMap<User,java.lang.Boolean> voteMap
private int pollID
private java.lang.String pollText
private java.sql.Date expiringDate
private boolean isRunning
public Poll(int pollID, java.lang.String pollText, java.sql.Date expiringDate)
public java.util.Iterator<User> getVotesFor()
public java.util.Iterator<User> getVotesAgainst()
public java.util.Iterator<User> getVotesAbstensions()
public int getPollID()
public java.util.HashMap<User,java.lang.Boolean> getVoteMap()
public java.lang.String getPollText()
public java.sql.Date getExpiringDate()
public boolean getIsRunning()
protected boolean checkDate()
protected void addVote(User votingUser, java.lang.Boolean voteValue)
private void setIsRunning(boolean isRunning)
public void setId(int id)