private void ScrumTeamOnMessageReceived(object sender, MessageReceivedEventArgs e)
        {
            var team = (ScrumTeam)sender;
            ScrumTeamMessage scrumTeamMessage = null;

            switch (e.Message.MessageType)
            {
            case MessageType.MemberJoined:
            case MessageType.MemberDisconnected:
            case MessageType.MemberActivity:
                var memberMessage = (MemberMessage)e.Message;
                scrumTeamMessage = new ScrumTeamMemberMessage(team.Name, memberMessage.MessageType)
                {
                    MemberName            = memberMessage.Member.Name,
                    MemberType            = memberMessage.Member.GetType().Name,
                    SessionId             = memberMessage.Member.SessionId,
                    AcknowledgedMessageId = memberMessage.Member.AcknowledgedMessageId
                };
                break;

            case MessageType.MemberEstimated:
                var memberEstimatedMessage = (MemberMessage)e.Message;
                var member = memberEstimatedMessage.Member as Member;
                if (member != null && member.Estimation != null)
                {
                    scrumTeamMessage = new ScrumTeamMemberEstimationMessage(team.Name, memberEstimatedMessage.MessageType)
                    {
                        MemberName = member.Name,
                        Estimation = member.Estimation.Value
                    };
                }

                break;

            default:
                scrumTeamMessage = new ScrumTeamMessage(team.Name, e.Message.MessageType);
                break;
            }

            if (scrumTeamMessage != null)
            {
                _observableMessages.OnNext(scrumTeamMessage);
            }
        }
 private void OnMemberEstimatedMessage(string teamName, ScrumTeamMemberEstimationMessage message)
 {
     using (var teamLock = this.PlanningPoker.GetScrumTeam(teamName))
     {
         teamLock.Lock();
         var team = teamLock.Team;
         try
         {
             this.processingScrumTeamName = team.Name;
             var member = team.FindMemberOrObserver(message.MemberName) as Member;
             if (member != null)
             {
                 member.Estimation = new Estimation(message.Estimation);
             }
         }
         finally
         {
             this.processingScrumTeamName = null;
         }
     }
 }