mirror of
https://dev.azure.com/TeilRad/sharee.bike%20App/_git/Code
synced 2024-11-16 07:06:33 +01:00
32 lines
1.1 KiB
C#
32 lines
1.1 KiB
C#
using System.Collections.Generic;
|
|
|
|
namespace ShareeBike.ViewModel.MiniSurvey.Question
|
|
{
|
|
public class FreeTextViewModel : IMiniSurveyQuestion
|
|
{
|
|
/// <summary> Constructs object. </summary>
|
|
/// <param name="question">Holds the question with key asked to user.</param>
|
|
/// <param name="answers">Holds the list of possible answers with their option keys.</param>
|
|
public FreeTextViewModel(
|
|
KeyValuePair<string, string> question)
|
|
{
|
|
Question = question;
|
|
}
|
|
|
|
/// <summary> Holds the question with key asked to user. </summary>
|
|
public KeyValuePair<string, string> Question { get; }
|
|
|
|
/// <summary> Holds the question with key asked to user exposed to GUI. </summary>
|
|
public string QuestionText => Question.Value;
|
|
|
|
/// <summary> Holds the users selected answer with its option key. </summary>
|
|
public KeyValuePair<string, string> Answer { get; private set; }
|
|
|
|
/// <summary> Holds the list of possible answers exposed to GUI. </summary>
|
|
public string AnswerText
|
|
{
|
|
get => null;
|
|
set => Answer = new KeyValuePair<string, string>(value, null);
|
|
}
|
|
}
|
|
}
|