|
|
|
|
|
||||||||||
| 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.AbstractQuestion
org.torweg.pulse.component.survey.model.OpenQuestion
@Entity public class OpenQuestion
Is an open question.
| Constructor Summary | |
|---|---|
protected |
OpenQuestion()
Default constructor. |
|
OpenQuestion(java.lang.String regex,
java.lang.Boolean isAllowBlank)
Creates a new OpenQuestion with the given value for
isAllowBlank. |
| Method Summary | |
|---|---|
AbstractTypedAnswer<?> |
getAnswer(ServiceRequest request)
Tries to extract the answer to the OpenQuestion from the
given ServiceRequest. |
java.lang.String |
getRegexpression()
Returns the regular expression. |
boolean |
isValid(AbstractTypedAnswer<?> answer)
Checks the given {@code AbstractTypedAnswer |
void |
setRegexpression(java.lang.String regex)
Sets the regular expression. |
| Methods inherited from class org.torweg.pulse.component.survey.model.AbstractQuestion |
|---|
getQuestionText, isAllowBlank, setIsAllowBlank, setQuestionText |
| 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 OpenQuestion()
public OpenQuestion(java.lang.String regex,
java.lang.Boolean isAllowBlank)
OpenQuestion with the given value for
isAllowBlank.
regex - the regular expression to use for the value checkisAllowBlank - the value for isAllowBlank to set| Method Detail |
|---|
public final void setRegexpression(java.lang.String regex)
regex - the regular expression to setpublic final java.lang.String getRegexpression()
public final AbstractTypedAnswer<?> getAnswer(ServiceRequest request)
OpenQuestion from the
given ServiceRequest.
getAnswer in class AbstractQuestionrequest - the ServiceRequest
AbstractTypedAnswer<?>; precisely a
OpenQuestionAnswerpublic final boolean isValid(AbstractTypedAnswer<?> answer)
AbstractTypedAnswer<?> for validity.
isValid in class AbstractQuestionanswer - the AbstractTypedAnswer<?> to validate
true if the
AbstractTypedAnswer<?> is valid,
false otherwise(org.torweg.pulse.component.survey.model.answer.AbstractTypedAnswer)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||