- Timestamp:
- Feb 20, 2018, 12:09:09 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/Presentation_HS17_merge/src/modules/dialog/Question.cc
r11781 r11782 33 33 { 34 34 35 35 RegisterClass(Question); 36 36 37 38 39 40 37 Question::Question(Context* context) : BaseObject(context) 38 { 39 RegisterObject(Question); 40 } 41 41 42 43 44 42 void Question::XMLPort(Element& xmlement, XMLPort::Mode mode) 43 { 44 SUPER(Question, XMLPort, xmlement, mode); 45 45 46 47 46 XMLPortParam(Question, "question", setQuestion, getQuestion, xmlement, mode); 47 XMLPortParam(Question, "Id", setQuestionId, getQuestionId, xmlement, mode); 48 48 49 50 49 XMLPortObject(Question, AnswerId, "answerIds", addAnswerId, getAnswerId, xmlement, mode); 50 } 51 51 52 53 54 55 52 void Question::setQuestionId(const std::string& Id) 53 { 54 this->questionId_ = Id; 55 } 56 56 57 58 59 60 57 const std::string& Question::getQuestionId() const 58 { 59 return this->questionId_; 60 } 61 61 62 63 64 65 62 void Question::setQuestion(const std::string& question) 63 { 64 this->question_ = question; 65 } 66 66 67 68 69 70 67 const std::string& Question::getQuestion() const 68 { 69 return this->question_; 70 } 71 71 72 73 74 75 72 void Question::addAnswerId(AnswerId* answerId) 73 { 74 this->answerIds_.push_back(answerId->getId()); 75 } 76 76 77 78 79 80 77 AnswerId* Question::getAnswerId(unsigned int index) const 78 { 79 return nullptr; 80 } 81 81 82 const std::vector<std::string>& Question::getAnswerIds() const 83 { 84 return this->answerIds_; 85 } 86 82 const std::vector<std::string>& Question::getAnswerIds() const 83 { 84 return this->answerIds_; 85 } 87 86 }
Note: See TracChangeset
for help on using the changeset viewer.