Example #1
0
 public VoteSummaryVM(VoteSet voteSet)
     : this()
 {
     VoteData.Add(voteSet.GetVoteData(voteSet.RedCount, Colors.Red));
     VoteData.Add(voteSet.GetVoteData(voteSet.YellowCount, Colors.Yellow));
     VoteData.Add(voteSet.GetVoteData(voteSet.GreenCount, Colors.Green));
 }
Example #2
0
 public void Ensure(VoteSet voteSet)
 {
     var setToAdd = voteSet.GetClone();
     if (_sets.ContainsKey(setToAdd.StartTime))
     {
         _sets.Remove(setToAdd.StartTime);
     }
     _sets.Add(setToAdd.StartTime, setToAdd);
 }