Esempio n. 1
0
 public void Update(GroupResponse?other)
 {
     if (other is null)
     {
         return;
     }
     if (!Detail.DeepEquals(other.Detail))
     {
         Detail.Update(other.Detail);
         OnPropertyChanged(nameof(Detail));
     }
     if (!Founder.DeepEquals(other.Founder))
     {
         Founder.Update(other.Founder);
         OnPropertyChanged(nameof(Founder));
     }
     if (!AlliedIds.DeepEqualsListNaive(other.AlliedIds))
     {
         AlliedIds = other.AlliedIds;
         OnPropertyChanged(nameof(AlliedIds));
     }
     if (!ParentGroup.DeepEquals(other.ParentGroup))
     {
         ParentGroup.Update(other.ParentGroup);
         OnPropertyChanged(nameof(ParentGroup));
     }
     if (AllianceStatus != other.AllianceStatus)
     {
         AllianceStatus = other.AllianceStatus;
         OnPropertyChanged(nameof(AllianceStatus));
     }
     if (GroupJoinInviteCount != other.GroupJoinInviteCount)
     {
         GroupJoinInviteCount = other.GroupJoinInviteCount;
         OnPropertyChanged(nameof(GroupJoinInviteCount));
     }
     if (CurrentUserMembershipsInactiveForDestiny != other.CurrentUserMembershipsInactiveForDestiny)
     {
         CurrentUserMembershipsInactiveForDestiny = other.CurrentUserMembershipsInactiveForDestiny;
         OnPropertyChanged(nameof(CurrentUserMembershipsInactiveForDestiny));
     }
     if (!CurrentUserMemberMap.DeepEqualsDictionary(other.CurrentUserMemberMap))
     {
         CurrentUserMemberMap = other.CurrentUserMemberMap;
         OnPropertyChanged(nameof(CurrentUserMemberMap));
     }
     if (!CurrentUserPotentialMemberMap.DeepEqualsDictionary(other.CurrentUserPotentialMemberMap))
     {
         CurrentUserPotentialMemberMap = other.CurrentUserPotentialMemberMap;
         OnPropertyChanged(nameof(CurrentUserPotentialMemberMap));
     }
 }
Esempio n. 2
0
 public bool DeepEquals(GroupResponse?other)
 {
     return(other is not null &&
            (Detail is not null ? Detail.DeepEquals(other.Detail) : other.Detail is null) &&
            (Founder is not null ? Founder.DeepEquals(other.Founder) : other.Founder is null) &&
            AlliedIds.DeepEqualsListNaive(other.AlliedIds) &&
            (ParentGroup is not null ? ParentGroup.DeepEquals(other.ParentGroup) : other.ParentGroup is null) &&
            AllianceStatus == other.AllianceStatus &&
            GroupJoinInviteCount == other.GroupJoinInviteCount &&
            CurrentUserMembershipsInactiveForDestiny == other.CurrentUserMembershipsInactiveForDestiny &&
            CurrentUserMemberMap.DeepEqualsDictionary(other.CurrentUserMemberMap) &&
            CurrentUserPotentialMemberMap.DeepEqualsDictionary(other.CurrentUserPotentialMemberMap));
 }
Esempio n. 3
0
        public bool Equals(GroupResponse input)
        {
            if (input == null)
            {
                return(false);
            }

            return
                ((
                     Detail == input.Detail ||
                     (Detail != null && Detail.Equals(input.Detail))
                     ) &&
                 (
                     Founder == input.Founder ||
                     (Founder != null && Founder.Equals(input.Founder))
                 ) &&
                 (
                     AlliedIds == input.AlliedIds ||
                     (AlliedIds != null && AlliedIds.SequenceEqual(input.AlliedIds))
                 ) &&
                 (
                     ParentGroup == input.ParentGroup ||
                     (ParentGroup != null && ParentGroup.Equals(input.ParentGroup))
                 ) &&
                 (
                     AllianceStatus == input.AllianceStatus ||
                     (AllianceStatus != null && AllianceStatus.Equals(input.AllianceStatus))
                 ) &&
                 (
                     GroupJoinInviteCount == input.GroupJoinInviteCount ||
                     (GroupJoinInviteCount.Equals(input.GroupJoinInviteCount))
                 ) &&
                 (
                     CurrentUserMembershipsInactiveForDestiny == input.CurrentUserMembershipsInactiveForDestiny ||
                     (CurrentUserMembershipsInactiveForDestiny != null && CurrentUserMembershipsInactiveForDestiny.Equals(input.CurrentUserMembershipsInactiveForDestiny))
                 ) &&
                 (
                     CurrentUserMemberMap == input.CurrentUserMemberMap ||
                     (CurrentUserMemberMap != null && CurrentUserMemberMap.SequenceEqual(input.CurrentUserMemberMap))
                 ) &&
                 (
                     CurrentUserPotentialMemberMap == input.CurrentUserPotentialMemberMap ||
                     (CurrentUserPotentialMemberMap != null && CurrentUserPotentialMemberMap.SequenceEqual(input.CurrentUserPotentialMemberMap))
                 ));
        }