public void AddMember(G.Member member)
        {
            if (string.IsNullOrWhiteSpace(member.Email))
            {
                return;
            }

            switch (member.Role.ToLowerInvariant())
            {
            case "member":
                this.AddMember(member.Email);
                break;

            case "manager":
                this.AddManager(member.Email);
                break;

            case "owner":
                this.AddOwner(member.Email);
                break;

            default:
                throw new NotSupportedException("Unknown or unsupported member role");
            }
        }
        public List <G.Member> ToMemberList()
        {
            List <G.Member> members = new List <G.Member>();

            foreach (string address in this.Members.Union(this.ExternalMembers))
            {
                G.Member member = new G.Member
                {
                    Role  = "MEMBER",
                    Email = address
                };

                members.Add(member);
            }

            foreach (string address in this.Managers.Union(this.ExternalManagers))
            {
                G.Member member = new G.Member
                {
                    Role  = "MANAGER",
                    Email = address
                };

                members.Add(member);
            }

            foreach (string address in this.Owners.Union(this.ExternalOwners))
            {
                G.Member member = new G.Member
                {
                    Role  = "OWNER",
                    Email = address
                };

                members.Add(member);
            }

            return(members);
        }