org.chorem.pollen.ui.pages.poll
Class VoteForPoll

java.lang.Object
  extended by org.chorem.pollen.ui.pages.poll.VoteForPoll

@IncludeStylesheet(value="context:css/vote.css")
public class VoteForPoll
extends java.lang.Object

Classe de la page de vote.

Version:
$Id: VoteForPoll.java 2755 2009-08-26 10:01:22Z nrannou $
Author:
kmorin, rannou

Constructor Summary
VoteForPoll()
           
 
Method Summary
 java.lang.String getChoiceImageSrc()
          Retourne le chemin de l'image correspondant au choix courant
 java.util.Date getChoiceNameAsDate()
          Retourne la date correspondant au choix courant
 java.lang.String getChoiceThumbSrc()
          Retourne le chemin de la miniature correspondant au choix courant
 java.lang.String getCreatorName()
          Récupération du créateur du sondage.
 java.lang.String getCurrentChoiceResult()
          Retourne le résultat correspondant au choix de sondage courant.
 ChoiceDTO getCurrentVoteChoice()
          Retourne le choix de vote correspondant au choix de sondage courant.
 java.lang.String getCurrentVotingId()
          Retourne l'identifiant du votant du vote courant
 java.lang.String getFeedFileName()
          Retourne le nom complet du fichier de flux de syndication.
 java.lang.String getHelpMessage()
          Retourne le message d'aide correspondant au type de sondage.
 java.lang.String getResultsAsString()
          Retourne une chaîne contenant les résultats du sondage.
 boolean isAccountFieldDisplayed()
          Retourne vrai si le champs pollAccount doit apparaître.
 boolean isAddChoice()
           
 boolean isAnonymousVoteDisplayed()
          Retourne vrai si la checkbox anonymousVote doit être affichée.
 java.lang.Boolean isChoiceInVote(ChoiceDTO choice)
          Retourne si le choix fait partie du vote (s'il a été renseigné par le votant).
 boolean isCondorcetVoteCounting()
           
 boolean isCreatorUser()
          retourne vrai si l'utilisateur est le créateur du sondage
 boolean isCurrentVoteAnonymous()
          Retourne true si le sondage est anonyme ou si le vote courant est anonyme.
 boolean isDateType()
           
 boolean isDescNull()
           
 boolean isFeedFileExisting()
          Vérifie que le fichier de flux de syndication existe.
 boolean isFreePoll()
           
 boolean isGroupPoll()
           
 boolean isImageType()
           
 boolean isModifAllowed(java.lang.String votingId)
          Retourne vrai si la modification du vote est autorisée.
 boolean isNormalVoteCounting()
           
 boolean isPercentageVoteCounting()
           
 boolean isPollChoiceOrVoteStarted()
           
 boolean isPollChoiceRunning()
           
 boolean isPollChoiceStarted()
           
 boolean isPollFinished()
           
 boolean isPollNull()
           
 boolean isPollRunning()
           
 boolean isPollStarted()
           
 boolean isRestrictedPoll()
           
 boolean isTextType()
           
 boolean isVoteAnonymous()
          Retourne true si le sondage est anonyme ou si le vote soumis est anonyme.
 void setAddChoice(boolean addChoice)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VoteForPoll

public VoteForPoll()
Method Detail

isModifAllowed

public boolean isModifAllowed(java.lang.String votingId)
Retourne vrai si la modification du vote est autorisée. C'est à dire si l'utilisateur connecté est l'auteur du vote ou si le votant défini par l'url est l'auteur du vote.

Parameters:
votingId - le votant a rechercher
Returns:
vrai si la modification du vote est autorisée

isAddChoice

public boolean isAddChoice()

setAddChoice

public void setAddChoice(boolean addChoice)

isChoiceInVote

public java.lang.Boolean isChoiceInVote(ChoiceDTO choice)
Retourne si le choix fait partie du vote (s'il a été renseigné par le votant).

Parameters:
choice - le choix concerné
Returns:
true si le choix est dans le vote

getCurrentVoteChoice

public ChoiceDTO getCurrentVoteChoice()
Retourne le choix de vote correspondant au choix de sondage courant.

Returns:
un choix de vote

getCurrentChoiceResult

public java.lang.String getCurrentChoiceResult()
Retourne le résultat correspondant au choix de sondage courant.

Returns:
le résultat du choix

isFeedFileExisting

public boolean isFeedFileExisting()
Vérifie que le fichier de flux de syndication existe.

Returns:
vrai si le fichier existe

getFeedFileName

public java.lang.String getFeedFileName()
Retourne le nom complet du fichier de flux de syndication.

Returns:
le nom du fichier

getResultsAsString

public java.lang.String getResultsAsString()
Retourne une chaîne contenant les résultats du sondage.

Returns:
les résultats

isVoteAnonymous

public boolean isVoteAnonymous()
Retourne true si le sondage est anonyme ou si le vote soumis est anonyme. Utilisé lors de la soumission d'un vote.

Returns:
true si le vote est anonyme

isCurrentVoteAnonymous

public boolean isCurrentVoteAnonymous()
Retourne true si le sondage est anonyme ou si le vote courant est anonyme. Utilisé dans la boucle de parcours des votes.

Returns:
true si le vote est anonyme

isAnonymousVoteDisplayed

public boolean isAnonymousVoteDisplayed()
Retourne vrai si la checkbox anonymousVote doit être affichée.


getCurrentVotingId

public java.lang.String getCurrentVotingId()
Retourne l'identifiant du votant du vote courant


isPollNull

public boolean isPollNull()

isPollChoiceStarted

public boolean isPollChoiceStarted()

isPollStarted

public boolean isPollStarted()

isPollFinished

public boolean isPollFinished()

isPollChoiceOrVoteStarted

public boolean isPollChoiceOrVoteStarted()

isPollChoiceRunning

public boolean isPollChoiceRunning()

isPollRunning

public boolean isPollRunning()

isDescNull

public boolean isDescNull()

isAccountFieldDisplayed

public boolean isAccountFieldDisplayed()
Retourne vrai si le champs pollAccount doit apparaître.


isFreePoll

public boolean isFreePoll()

isRestrictedPoll

public boolean isRestrictedPoll()

isGroupPoll

public boolean isGroupPoll()

isTextType

public boolean isTextType()

isDateType

public boolean isDateType()

isImageType

public boolean isImageType()

isNormalVoteCounting

public boolean isNormalVoteCounting()

isPercentageVoteCounting

public boolean isPercentageVoteCounting()

isCondorcetVoteCounting

public boolean isCondorcetVoteCounting()

isCreatorUser

public boolean isCreatorUser()
retourne vrai si l'utilisateur est le créateur du sondage


getCreatorName

public java.lang.String getCreatorName()
Récupération du créateur du sondage.

Returns:
le nom du créateur du sondage.

getHelpMessage

public java.lang.String getHelpMessage()
Retourne le message d'aide correspondant au type de sondage.


getChoiceNameAsDate

public java.util.Date getChoiceNameAsDate()
Retourne la date correspondant au choix courant


getChoiceImageSrc

public java.lang.String getChoiceImageSrc()
Retourne le chemin de l'image correspondant au choix courant


getChoiceThumbSrc

public java.lang.String getChoiceThumbSrc()
Retourne le chemin de la miniature correspondant au choix courant



Copyright © 2009 CodeLutin. All Rights Reserved.