Class QuestionContainerHeader
- java.lang.Object
-
- org.silverpeas.core.i18n.AbstractI18NBean<BeanTranslation>
-
- org.silverpeas.core.i18n.AbstractBean
-
- org.silverpeas.core.questioncontainer.container.model.QuestionContainerHeader
-
- All Implemented Interfaces:
Serializable
,SilverContentInterface
,Contribution
,SilverpeasContent
,WithPermanentLink
,I18NBean<BeanTranslation>
,Translatable
,Identifiable
,Instance<Contribution>
,Nameable
,Securable
,SilverpeasResource
public class QuestionContainerHeader extends AbstractBean implements Serializable, SilverContentInterface, WithPermanentLink
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static int
CLASSIC_DISPLAY_RESULTS
static int
DELAYED_RESULTS
static int
DETAILED_DISPLAY_RESULTS
static int
IMMEDIATE_RESULTS
static int
NOTHING_DISPLAY_RESULTS
static int
TWICE_DISPLAY_RESULTS
-
Constructor Summary
Constructors Constructor Description QuestionContainerHeader(QuestionContainerPK questionContainerPK, String title, String description, String creatorId, String creationDate, String beginDate, String endDate, boolean isClosed, int nbVoters, int nbQuestionsPerPage, boolean anonymous, int resultMode, int resultView)
QuestionContainerHeader(QuestionContainerPK questionContainerPK, String title, String description, String comment, String creatorId, String creationDate, String beginDate, String endDate, boolean isClosed, int nbVoters, int nbQuestionsPerPage, int nbMaxParticipations, int nbParticipationsBeforeSolution, int maxTime, boolean anonymous, int resultMode, int resultView)
QuestionContainerHeader(QuestionContainerPK questionContainerPK, String title, String description, String comment, String creatorId, String creationDate, String beginDate, String endDate, boolean isClosed, int nbVoters, int nbQuestionsPerPage, int nbMaxParticipations, int nbParticipationsBeforeSolution, int maxTime, int resultMode, int resultView)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close(boolean isClosed)
String
getBeginDate()
String
getComment()
Date
getCreationDate()
Gets the date at which the resource has been created.User
getCreator()
Gets the user that has created the resource.String
getCreatorId()
String
getDate()
String
getEndDate()
String
getIconUrl()
String
getId()
Gets the identifier of this content in the Silverpeas component providing it.String
getInstanceId()
Date
getLastUpdateDate()
Gets the date at which the resource has been lastly updated.User
getLastUpdater()
Gets the user that has lastly updated the resource.int
getMaxTime()
int
getNbMaxParticipations()
int
getNbMaxPoints()
int
getNbParticipationsBeforeSolution()
int
getNbQuestionsPerPage()
int
getNbRegistered()
int
getNbVoters()
String
getPermalink()
QuestionContainerPK
getPK()
int
getResultMode()
int
getResultView()
Collection<ScoreDetail>
getScores()
String
getSilverCreationDate()
String
getTitle()
Gets the title of this contribution if any.String
getURL()
boolean
isAnonymous()
boolean
isClosed()
void
setAnonymous(boolean anonymous)
void
setBeginDate(String beginDate)
void
setComment(String comment)
void
setCreationDate(String creationDate)
void
setCreatorId(String creatorId)
void
setEndDate(String endDate)
void
setIconUrl(String iconUrl)
void
setMaxTime(int nb)
void
setNbMaxParticipations(int nb)
void
setNbMaxPoints(int nb)
void
setNbParticipationsBeforeSolution(int nb)
void
setNbQuestionsPerPage(int nb)
void
setNbVoters(int nb)
void
setPK(QuestionContainerPK pk)
void
setResultMode(int resultMode)
void
setResultView(int resultView)
void
setScores(Collection<ScoreDetail> scores)
void
setTitle(String title)
-
Methods inherited from class org.silverpeas.core.i18n.AbstractBean
getDescription, getLanguages, getName, getTranslationType
-
Methods inherited from class org.silverpeas.core.i18n.AbstractI18NBean
addTranslation, getClonedTranslations, getDescription, getLanguage, getLanguageToDisplay, getName, getNextTranslation, getTranslation, getTranslationId, getTranslations, isRemoveTranslation, setDescription, setLanguage, setName, setRemoveTranslation, setTranslationId, setTranslations, setTranslations
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.silverpeas.core.contribution.model.Contribution
canBeAccessedBy, getContributionType, getDescription, getModel, getResourcePath, isIndexable
-
Methods inherited from interface org.silverpeas.core.security.Securable
canBeDeletedBy, canBeFiledInBy, canBeModifiedBy
-
Methods inherited from interface org.silverpeas.core.contribution.contentcontainer.content.SilverContentInterface
getComponentInstanceId, getDescription, getLanguages, getName, getName
-
Methods inherited from interface org.silverpeas.core.contribution.model.SilverpeasContent
getIdentifier, getSilverpeasContentId
-
-
-
-
Field Detail
-
IMMEDIATE_RESULTS
public static final int IMMEDIATE_RESULTS
- See Also:
- Constant Field Values
-
DELAYED_RESULTS
public static final int DELAYED_RESULTS
- See Also:
- Constant Field Values
-
NOTHING_DISPLAY_RESULTS
public static final int NOTHING_DISPLAY_RESULTS
- See Also:
- Constant Field Values
-
CLASSIC_DISPLAY_RESULTS
public static final int CLASSIC_DISPLAY_RESULTS
- See Also:
- Constant Field Values
-
DETAILED_DISPLAY_RESULTS
public static final int DETAILED_DISPLAY_RESULTS
- See Also:
- Constant Field Values
-
TWICE_DISPLAY_RESULTS
public static final int TWICE_DISPLAY_RESULTS
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
QuestionContainerHeader
public QuestionContainerHeader(QuestionContainerPK questionContainerPK, String title, String description, String comment, String creatorId, String creationDate, String beginDate, String endDate, boolean isClosed, int nbVoters, int nbQuestionsPerPage, int nbMaxParticipations, int nbParticipationsBeforeSolution, int maxTime, int resultMode, int resultView)
-
QuestionContainerHeader
public QuestionContainerHeader(QuestionContainerPK questionContainerPK, String title, String description, String comment, String creatorId, String creationDate, String beginDate, String endDate, boolean isClosed, int nbVoters, int nbQuestionsPerPage, int nbMaxParticipations, int nbParticipationsBeforeSolution, int maxTime, boolean anonymous, int resultMode, int resultView)
-
QuestionContainerHeader
public QuestionContainerHeader(QuestionContainerPK questionContainerPK, String title, String description, String creatorId, String creationDate, String beginDate, String endDate, boolean isClosed, int nbVoters, int nbQuestionsPerPage, boolean anonymous, int resultMode, int resultView)
-
-
Method Detail
-
getPK
public QuestionContainerPK getPK()
-
getTitle
public String getTitle()
Description copied from interface:Contribution
Gets the title of this contribution if any. By default returns an empty String.- Specified by:
getTitle
in interfaceContribution
- Returns:
- the contribution's title in the specified language. Can be empty if no title was set or no title is defined for a such contribution.
-
getComment
public String getComment()
-
getCreatorId
public String getCreatorId()
- Specified by:
getCreatorId
in interfaceSilverContentInterface
-
getCreationDate
public Date getCreationDate()
Description copied from interface:SilverpeasResource
Gets the date at which the resource has been created.- Specified by:
getCreationDate
in interfaceSilverContentInterface
- Specified by:
getCreationDate
in interfaceSilverpeasResource
- Returns:
- the date of creation of the resource.
-
getLastUpdateDate
public Date getLastUpdateDate()
Description copied from interface:SilverpeasResource
Gets the date at which the resource has been lastly updated. If the resource doesn't have such an information, then this method should return the date of the resource creation.- Specified by:
getLastUpdateDate
in interfaceSilverContentInterface
- Specified by:
getLastUpdateDate
in interfaceSilverpeasResource
- Returns:
- the date of the last update of the resource.
-
getCreator
public User getCreator()
Description copied from interface:SilverpeasResource
Gets the user that has created the resource.- Specified by:
getCreator
in interfaceSilverContentInterface
- Specified by:
getCreator
in interfaceSilverpeasResource
- Returns:
- a
User
in Silverpeas.
-
getLastUpdater
public User getLastUpdater()
Description copied from interface:SilverpeasResource
Gets the user that has lastly updated the resource. If the resource doesn't have such an information, then this method should return the user that has created the resource.- Specified by:
getLastUpdater
in interfaceSilverContentInterface
- Specified by:
getLastUpdater
in interfaceSilverpeasResource
- Returns:
- a
User
in Silverpeas.
-
getBeginDate
public String getBeginDate()
-
getEndDate
public String getEndDate()
-
isClosed
public boolean isClosed()
-
getNbVoters
public int getNbVoters()
-
getNbRegistered
public int getNbRegistered()
-
getNbQuestionsPerPage
public int getNbQuestionsPerPage()
-
getNbMaxParticipations
public int getNbMaxParticipations()
-
getNbParticipationsBeforeSolution
public int getNbParticipationsBeforeSolution()
-
getMaxTime
public int getMaxTime()
-
getNbMaxPoints
public int getNbMaxPoints()
-
getScores
public Collection<ScoreDetail> getScores()
-
setPK
public void setPK(QuestionContainerPK pk)
-
setTitle
public void setTitle(String title)
-
setComment
public void setComment(String comment)
-
setCreatorId
public void setCreatorId(String creatorId)
-
setCreationDate
public void setCreationDate(String creationDate)
-
setBeginDate
public void setBeginDate(String beginDate)
-
setEndDate
public void setEndDate(String endDate)
-
close
public void close(boolean isClosed)
-
setNbVoters
public void setNbVoters(int nb)
-
setNbQuestionsPerPage
public void setNbQuestionsPerPage(int nb)
-
setNbMaxParticipations
public void setNbMaxParticipations(int nb)
-
setNbParticipationsBeforeSolution
public void setNbParticipationsBeforeSolution(int nb)
-
setMaxTime
public void setMaxTime(int nb)
-
setNbMaxPoints
public void setNbMaxPoints(int nb)
-
setScores
public void setScores(Collection<ScoreDetail> scores)
-
getURL
public String getURL()
- Specified by:
getURL
in interfaceSilverContentInterface
-
getId
public String getId()
Description copied from interface:SilverpeasContent
Gets the identifier of this content in the Silverpeas component providing it. This identifier is only unique among all the contents managed by the same component (whatever its different instances). As each type of contents in Silverpeas is provided by a single Silverpeas component, the identifier of a content is then specific to the component it belongs to. It is a way for an instance of a such component to identify uniquely the different contents it manages. So, each component can have their own policy to identify their content, whatever the way they are identified in Silverpeas.- Specified by:
getId
in interfaceIdentifiable
- Specified by:
getId
in interfaceSilverpeasContent
- Returns:
- the identifier of this content.
-
getInstanceId
public String getInstanceId()
- Specified by:
getInstanceId
in interfaceSilverContentInterface
-
getDate
public String getDate()
- Specified by:
getDate
in interfaceSilverContentInterface
-
getSilverCreationDate
public String getSilverCreationDate()
- Specified by:
getSilverCreationDate
in interfaceSilverContentInterface
-
setIconUrl
public void setIconUrl(String iconUrl)
-
getIconUrl
public String getIconUrl()
- Specified by:
getIconUrl
in interfaceSilverContentInterface
-
getPermalink
public String getPermalink()
- Specified by:
getPermalink
in interfaceWithPermanentLink
-
isAnonymous
public boolean isAnonymous()
-
setAnonymous
public void setAnonymous(boolean anonymous)
-
getResultMode
public int getResultMode()
-
setResultMode
public void setResultMode(int resultMode)
-
getResultView
public int getResultView()
-
setResultView
public void setResultView(int resultView)
-
-