Interface EventQuestionService
- All Known Implementing Classes:
EventQuestionServiceImpl
public interface EventQuestionService
This service can be used to easily create or update
Event_question_answers for a specific
Event_question and Registration.-
Method Summary
Modifier and TypeMethodDescriptiongetQuestionAnswer(Entity registration, Entity eventQuestion) Returns anEvent_question_answerfor the passedregistrationandEvent_questionif existing.voidupdateOrCreateChoiceQuestion(Entity eventQuestion, Entity registration, EntityList answers) Updates or creates anEvent_question_answerfor the passedRegistrationandEvent_questionand adds the passedRegistration_answer_optionsto it.voidupdateOrCreateTextQuestion(Entity eventQuestion, Entity registration, String answer) Updates or creates anEvent_question_answerfor the passedRegistrationandEvent_questionand sets the value of the fieldanswerwith the passedString.
-
Method Details
-
getQuestionAnswer
-
updateOrCreateTextQuestion
Updates or creates anEvent_question_answerfor the passedRegistrationandEvent_questionand sets the value of the fieldanswerwith the passedString. The type of the question has either to betext_single_lineortext_multi_line. Otherwise this method won't do anything. If there is noEvent_question_answeravailable for the passedRegistrationandEvent_questiona new one will be created. -
updateOrCreateChoiceQuestion
Updates or creates anEvent_question_answerfor the passedRegistrationandEvent_questionand adds the passedRegistration_answer_optionsto it. the type of the question has either to besingle_choiceormultiple_choice. Otherwise this method won't do anything. If there is noEvent_question_answeravailable for the passedRegistrationandEvent_questiona new one will be created. If the type of the passedEvent_questionissingle_choiceand the passedEntityListhas more than one entries, only the first entry will be added.
-