|
|
|
|
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.torweg.pulse.util.entity.AbstractBasicEntity
org.torweg.pulse.component.survey.model.Survey
@Entity public class Survey
A Survey is a collection of AbstractQuestions.
The Survey will be processed by the
SurveyController during the execution of which the following
settings of the Survey will be evaluated:
| Constructor Summary | |
|---|---|
protected |
Survey()
Default constructor. |
|
Survey(java.lang.String n,
java.util.List<AbstractQuestion> quests)
Creates a new Survey with the given name and the given
AbstractQuestions. |
| Method Summary | |
|---|---|
java.util.Date |
getEndDate()
Returns the end- Date. |
java.lang.String |
getName()
Returns the name of the Survey. |
AbstractQuestion |
getQuestion(int index)
Returns the AbstractQuestion at the specified index. |
java.util.List<Questionnaire> |
getQuestionnaires(org.hibernate.Session s)
Returns the Questionnaires associated with the
Survey. |
java.util.List<AbstractQuestion> |
getQuestions()
Returns the AbstractQuestions of the Survey. |
java.util.Collection<java.lang.Long> |
getRoleIds()
Returns the ids of the Roles required to take part
in the Survey. |
java.util.Date |
getStartDate()
Returns the start- Date. |
boolean |
isAnonymous()
Returns the anonymous of the Survey. |
boolean |
isKeepInSession()
Indicates whether the Survey (precisely the current
SurveyProgress) is to be kept in the session once the
Survey is finished. |
boolean |
isRequireAllRoles()
Indicates whether all roleIds are required to take part in the Survey or a single one is enough. |
boolean |
isRequiresRole()
Returns whether this Survey requires (a) specific
Role/s to take part. |
boolean |
isRequireSurveyToken()
Returns whether the Survey requires a token to take
part. |
boolean |
isSingleStepSave()
Returns whether to save the Questionnaires for this survey
on every single step. |
void |
setAnonymous(boolean anon)
Sets the anonymous for the Survey. |
void |
setEndDate(java.util.Date end)
Sets the end- Date. |
void |
setKeepInSession(boolean keep)
Sets the keepInSession, which indicates whether the Survey (precisely the current SurveyProgress)
is to be kept in the session once the Survey is finished. |
void |
setRequireAllRoles(boolean requireAllRls)
Sets the requireAllRoles. |
void |
setRequireSurveyToken(boolean requireToken)
Sets the requireSurveyToken for the Survey. |
void |
setRoleIds(java.util.Collection<java.lang.Long> rIds)
Sets the ids of the Roles required to take part in
the Survey. |
void |
setSingleStepSave(boolean stepSave)
Sets the singleStepSave. |
void |
setStartDate(java.util.Date start)
Sets the start- Date. |
| Methods inherited from class org.torweg.pulse.util.entity.AbstractBasicEntity |
|---|
compareTo, equals, getFullQualifiedClassNameJAXB, getId, hashCode |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected Survey()
public Survey(java.lang.String n,
java.util.List<AbstractQuestion> quests)
Survey with the given name and the given
AbstractQuestions.
n - the name to setquests - the AbstractQuestions to set| Method Detail |
|---|
public final java.lang.String getName()
Survey.
getName in interface INamedpublic final java.util.List<AbstractQuestion> getQuestions()
AbstractQuestions of the Survey.
AbstractQuestionspublic final AbstractQuestion getQuestion(int index)
AbstractQuestion at the specified index.
index - the index
AbstractQuestion at the specified indexpublic final void setStartDate(java.util.Date start)
Date.
start - the start-Date to setpublic final java.util.Date getStartDate()
Date.
Date if set, null otherwisepublic final void setEndDate(java.util.Date end)
Date.
end - the end-Date to setpublic final java.util.Date getEndDate()
Date.
Date if set, null otherwisepublic final void setSingleStepSave(boolean stepSave)
stepSave - the singleStepSave to setpublic final boolean isSingleStepSave()
Questionnaires for this survey
on every single step.
true to save the Questionnaires for
this survey on every single step, false otherwisepublic final void setAnonymous(boolean anon)
Survey.
anon - the anonymous to setpublic final boolean isAnonymous()
Survey.
public final void setRequireSurveyToken(boolean requireToken)
Survey.
requireToken - the requireSurveyToken to setpublic final boolean isRequireSurveyToken()
Survey requires a token to take
part.
true if the Survey requires a
token to take part, false otherwisepublic final void setRoleIds(java.util.Collection<java.lang.Long> rIds)
Roles required to take part in
the Survey.
rIds - the roleIds to setpublic final java.util.Collection<java.lang.Long> getRoleIds()
Roles required to take part
in the Survey.
public final boolean isRequiresRole()
Survey requires (a) specific
Role/s to take part.
true if this Survey requires (a)
Role/s to take part, false otherwisepublic final void setRequireAllRoles(boolean requireAllRls)
requireAllRls - the requireAllRoles to setpublic final boolean isRequireAllRoles()
Survey or a single one is enough.
true if all roleIds are required to take
part in the Survey, false if a single
one is enoughpublic final void setKeepInSession(boolean keep)
Survey (precisely the current SurveyProgress)
is to be kept in the session once the Survey is finished.
keep - the keepInSession to setpublic final boolean isKeepInSession()
Survey (precisely the current
SurveyProgress) is to be kept in the session once the
Survey is finished.
true if the Survey (precisely the
SurveyProgress) is to be kept in the session,
false otherwisepublic final java.util.List<Questionnaire> getQuestionnaires(org.hibernate.Session s)
Questionnaires associated with the
Survey.
s - the hibernateTM-Session
Questionnaires associated with the
Survey
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||