org.sakaiproject.poll.service.impl
Class PollVoteManagerImpl

java.lang.Object
  extended by org.sakaiproject.poll.service.impl.PollVoteManagerImpl
All Implemented Interfaces:
PollVoteManager

public class PollVoteManagerImpl
extends Object
implements PollVoteManager


Constructor Summary
PollVoteManagerImpl()
           
 
Method Summary
 void deleteVote(Vote vote)
           
 List<Vote> getAllVotesForOption(Option option)
           
 List<Vote> getAllVotesForPoll(Poll poll)
           
 int getDisctinctVotersForPoll(Poll poll)
           
 Vote getVoteById(Long voteId)
           
 Map<Long,List<Vote>> getVotesForUser(String userId, Long[] pollIds)
           
 boolean isUserAllowedVote(String userId, Long pollId, boolean ignoreVoted)
           
 boolean pollIsVotable(Poll poll)
           
 boolean saveVote(Vote vote)
           
 void saveVoteList(List<Vote> votes)
           
 void setDao(PollDao dao)
           
 void setExternalLogic(ExternalLogic externalLogic)
           
 void setPollListManager(PollListManager pollListManaver)
           
 boolean userHasVoted(Long pollId)
           
 boolean userHasVoted(Long pollid, String userID)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PollVoteManagerImpl

public PollVoteManagerImpl()
Method Detail

setExternalLogic

public void setExternalLogic(ExternalLogic externalLogic)

setDao

public void setDao(PollDao dao)

setPollListManager

public void setPollListManager(PollListManager pollListManaver)

saveVoteList

public void saveVoteList(List<Vote> votes)
Specified by:
saveVoteList in interface PollVoteManager

saveVote

public boolean saveVote(Vote vote)
Specified by:
saveVote in interface PollVoteManager

getAllVotesForPoll

public List<Vote> getAllVotesForPoll(Poll poll)
Specified by:
getAllVotesForPoll in interface PollVoteManager

getAllVotesForOption

public List<Vote> getAllVotesForOption(Option option)
Specified by:
getAllVotesForOption in interface PollVoteManager

getVotesForUser

public Map<Long,List<Vote>> getVotesForUser(String userId,
                                            Long[] pollIds)
Specified by:
getVotesForUser in interface PollVoteManager

getDisctinctVotersForPoll

public int getDisctinctVotersForPoll(Poll poll)
Specified by:
getDisctinctVotersForPoll in interface PollVoteManager

userHasVoted

public boolean userHasVoted(Long pollid,
                            String userID)
Specified by:
userHasVoted in interface PollVoteManager

userHasVoted

public boolean userHasVoted(Long pollId)
Specified by:
userHasVoted in interface PollVoteManager

getVoteById

public Vote getVoteById(Long voteId)
Specified by:
getVoteById in interface PollVoteManager

isUserAllowedVote

public boolean isUserAllowedVote(String userId,
                                 Long pollId,
                                 boolean ignoreVoted)
Specified by:
isUserAllowedVote in interface PollVoteManager

pollIsVotable

public boolean pollIsVotable(Poll poll)
Specified by:
pollIsVotable in interface PollVoteManager

deleteVote

public void deleteVote(Vote vote)
Specified by:
deleteVote in interface PollVoteManager


Copyright © 2003-2012 Sakai Project. All Rights Reserved.