コード例 #1
0
        public static Participant In(EstimationRound round, string name = "anonymous")
        {
            var participant = new Participant(name);

            participant.Participate(round);
            return(participant);
        }
コード例 #2
0
ファイル: RoundKeeper.cs プロジェクト: jeroenbok/spooker
        public void Enroll(Participant participant)
        {
            if (!HasActiveRound)
            {
                StartNewRound(participant);
                return;
            }

            if (_activeRound.Status.IsCompleted)
            {
                var newRoundParticipants = _activeRound.Partipants.Union(new[] {participant}).ToArray();
                StartNewRound(newRoundParticipants);
            } else
            {
                participant.Participate(_activeRound);
            }
        }
コード例 #3
0
ファイル: RoundKeeper.cs プロジェクト: jeroenbok/spooker
        public void Enroll(Participant participant)
        {
            if (!HasActiveRound)
            {
                StartNewRound(participant);
                return;
            }

            if (_activeRound.Status.IsCompleted)
            {
                var newRoundParticipants = _activeRound.Partipants.Union(new[] { participant }).ToArray();
                StartNewRound(newRoundParticipants);
            }
            else
            {
                participant.Participate(_activeRound);
            }
        }
コード例 #4
0
ファイル: Participant.cs プロジェクト: jeroenbok/spooker
 public static Participant In(EstimationRound round, string name = "anonymous")
 {
     var participant = new Participant(name);
     participant.Participate(round);
     return participant;
 }