Exemplo n.º 1
0
        /// <summary>
        /// Returns true if AccountRef instances are equal
        /// </summary>
        /// <param name="other">Instance of AccountRef to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(AccountRef other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     Description == other.Description ||
                     Description != null &&
                     Description.Equals(other.Description)
                     ) &&
                 (
                     Href == other.Href ||
                     Href != null &&
                     Href.Equals(other.Href)
                 ) &&
                 (
                     Id == other.Id ||
                     Id != null &&
                     Id.Equals(other.Id)
                 ) &&
                 (
                     Name == other.Name ||
                     Name != null &&
                     Name.Equals(other.Name)
                 ));
        }
Exemplo n.º 2
0
        /// <summary>
        /// Returns true if AgreementRef instances are equal
        /// </summary>
        /// <param name="other">Instance of AgreementRef to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(AgreementRef other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     Href == other.Href ||
                     Href != null &&
                     Href.Equals(other.Href)
                     ) &&
                 (
                     Id == other.Id ||
                     Id != null &&
                     Id.Equals(other.Id)
                 ) &&
                 (
                     Name == other.Name ||
                     Name != null &&
                     Name.Equals(other.Name)
                 ));
        }
Exemplo n.º 3
0
        /// <summary>
        /// Returns true if RelatedPartyRef instances are equal
        /// </summary>
        /// <param name="other">Instance of RelatedPartyRef to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(RelatedPartyRef other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     Href == other.Href ||
                     Href != null &&
                     Href.Equals(other.Href)
                     ) &&
                 (
                     Id == other.Id ||
                     Id != null &&
                     Id.Equals(other.Id)
                 ) &&
                 (
                     Name == other.Name ||
                     Name != null &&
                     Name.Equals(other.Name)
                 ) &&
                 (
                     Role == other.Role ||
                     Role != null &&
                     Role.Equals(other.Role)
                 ));
        }
Exemplo n.º 4
0
        public override Boolean Equals(object obj)
        {
            if (ReferenceEquals(this, obj))
            {
                return(true);
            }

            return((obj is Link other) && Href.Equals(other.Href) && Name.Equals(other.Name));
        }
Exemplo n.º 5
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="obj"></param>
        /// <returns></returns>
        public override bool Equals(object obj)
        {
            if (!(obj is RuleDetails))
            {
                return(false);
            }


            return(Href != null &&
                   ((RuleDetails)obj).Href != null &&
                   Href.Equals(((RuleDetails)obj).Href));
        }
Exemplo n.º 6
0
        /// <summary>
        /// Returns true if HalLink instances are equal
        /// </summary>
        /// <param name="other">Instance of HalLink to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(HalLink other)
        {
            if (other is null)
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     Href == other.Href ||
                     Href != null &&
                     Href.Equals(other.Href)
                     ) &&
                 (
                     Templated == other.Templated ||

                     Templated.Equals(other.Templated)
                 ) &&
                 (
                     Type == other.Type ||
                     Type != null &&
                     Type.Equals(other.Type)
                 ) &&
                 (
                     Deprecation == other.Deprecation ||
                     Deprecation != null &&
                     Deprecation.Equals(other.Deprecation)
                 ) &&
                 (
                     Profile == other.Profile ||
                     Profile != null &&
                     Profile.Equals(other.Profile)
                 ) &&
                 (
                     Title == other.Title ||
                     Title != null &&
                     Title.Equals(other.Title)
                 ) &&
                 (
                     Hreflang == other.Hreflang ||
                     Hreflang != null &&
                     Hreflang.Equals(other.Hreflang)
                 ) &&
                 (
                     Name == other.Name ||
                     Name != null &&
                     Name.Equals(other.Name)
                 ));
        }
Exemplo n.º 7
0
        public override bool Equals(object obj)
        {
            if (!(obj is CRObject))
            {
                return(false);
            }


            return(Href != null &&
                   (obj as CRObject).Href != null &&
                   Href.Equals((obj as CRObject).Href));
        }
        /// <summary>
        /// Returns true if PartyRef instances are equal
        /// </summary>
        /// <param name="other">Instance of PartyRef to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(PartyRef other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     PartyRefType == other.PartyRefType ||
                     PartyRefType != null &&
                     PartyRefType.Equals(other.PartyRefType)
                     ) &&
                 (
                     Description == other.Description ||
                     Description != null &&
                     Description.Equals(other.Description)
                 ) &&
                 (
                     Href == other.Href ||
                     Href != null &&
                     Href.Equals(other.Href)
                 ) &&
                 (
                     Id == other.Id ||
                     Id != null &&
                     Id.Equals(other.Id)
                 ) &&
                 (
                     Name == other.Name ||
                     Name != null &&
                     Name.Equals(other.Name)
                 ) &&
                 (
                     Individual == other.Individual ||
                     Individual != null &&
                     Individual.SequenceEqual(other.Individual)
                 ) &&
                 (
                     Organization == other.Organization ||
                     Organization != null &&
                     Organization.SequenceEqual(other.Organization)
                 ));
        }
        /// <summary>
        /// Returns true if Organization instances are equal
        /// </summary>
        /// <param name="other">Instance of Organization to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(Organization other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     Id == other.Id ||
                     Id != null &&
                     Id.Equals(other.Id)
                     ) &&
                 (
                     TradingName == other.TradingName ||
                     TradingName != null &&
                     TradingName.Equals(other.TradingName)
                 ) &&
                 (
                     Href == other.Href ||
                     Href != null &&
                     Href.Equals(other.Href)
                 ) &&
                 (
                     IsLegalEntity == other.IsLegalEntity ||
                     IsLegalEntity != null &&
                     IsLegalEntity.Equals(other.IsLegalEntity)
                 ) &&
                 (
                     OrganizationType == other.OrganizationType ||
                     OrganizationType != null &&
                     OrganizationType.Equals(other.OrganizationType)
                 ) &&
                 (
                     NameType == other.NameType ||
                     NameType != null &&
                     NameType.Equals(other.NameType)
                 ) &&
                 (
                     Status == other.Status ||
                     Status != null &&
                     Status.Equals(other.Status)
                 ));
        }
Exemplo n.º 10
0
 public bool Equals(Link other)
 {
     if (other == null)
     {
         return(false);
     }
     if (!Rel.Equals(other.Rel, StringComparison.InvariantCultureIgnoreCase))
     {
         return(false);
     }
     if (!Href.Equals(other.Href, StringComparison.InvariantCultureIgnoreCase))
     {
         return(false);
     }
     if (!Method.Equals(other.Method, StringComparison.InvariantCultureIgnoreCase))
     {
         return(false);
     }
     if (Links.Intersect(other.Links).Any())
     {
         return(false);
     }
     return(true);
 }
Exemplo n.º 11
0
        /// <summary>
        /// Returns true if Individual instances are equal
        /// </summary>
        /// <param name="other">Instance of Individual to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(Individual other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     Id == other.Id ||
                     Id != null &&
                     Id.Equals(other.Id)
                     ) &&
                 (
                     Title == other.Title ||
                     Title != null &&
                     Title.Equals(other.Title)
                 ) &&
                 (
                     GivenName == other.GivenName ||
                     GivenName != null &&
                     GivenName.Equals(other.GivenName)
                 ) &&
                 (
                     FamilyName == other.FamilyName ||
                     FamilyName != null &&
                     FamilyName.Equals(other.FamilyName)
                 ) &&
                 (
                     MiddleName == other.MiddleName ||
                     MiddleName != null &&
                     MiddleName.Equals(other.MiddleName)
                 ) &&
                 (
                     Href == other.Href ||
                     Href != null &&
                     Href.Equals(other.Href)
                 ) &&
                 (
                     Gender == other.Gender ||
                     Gender != null &&
                     Gender.Equals(other.Gender)
                 ) &&
                 (
                     PlaceOfBirth == other.PlaceOfBirth ||
                     PlaceOfBirth != null &&
                     PlaceOfBirth.Equals(other.PlaceOfBirth)
                 ) &&
                 (
                     CountryOfBirth == other.CountryOfBirth ||
                     CountryOfBirth != null &&
                     CountryOfBirth.Equals(other.CountryOfBirth)
                 ) &&
                 (
                     Nationality == other.Nationality ||
                     Nationality != null &&
                     Nationality.Equals(other.Nationality)
                 ) &&
                 (
                     MaritalStatus == other.MaritalStatus ||
                     MaritalStatus != null &&
                     MaritalStatus.Equals(other.MaritalStatus)
                 ) &&
                 (
                     BirthDate == other.BirthDate ||
                     BirthDate != null &&
                     BirthDate.Equals(other.BirthDate)
                 ) &&
                 (
                     FullName == other.FullName ||
                     FullName != null &&
                     FullName.Equals(other.FullName)
                 ) &&
                 (
                     FormattedName == other.FormattedName ||
                     FormattedName != null &&
                     FormattedName.Equals(other.FormattedName)
                 ) &&
                 (
                     Location == other.Location ||
                     Location != null &&
                     Location.Equals(other.Location)
                 ) &&
                 (
                     Status == other.Status ||
                     Status != null &&
                     Status.Equals(other.Status)
                 ));
        }
Exemplo n.º 12
0
 public bool Equals(Link other)
 => other != null && Href.Equals(other.Href);
Exemplo n.º 13
0
        /// <summary>
        /// Returns true if Customer instances are equal
        /// </summary>
        /// <param name="other">Instance of Customer to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(Customer other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     Href == other.Href ||
                     Href != null &&
                     Href.Equals(other.Href)
                     ) &&
                 (
                     Id == other.Id ||
                     Id != null &&
                     Id.Equals(other.Id)
                 ) &&
                 (
                     Name == other.Name ||
                     Name != null &&
                     Name.Equals(other.Name)
                 ) &&
                 (
                     Status == other.Status ||
                     Status != null &&
                     Status.Equals(other.Status)
                 ) &&
                 (
                     StatusReason == other.StatusReason ||
                     StatusReason != null &&
                     StatusReason.Equals(other.StatusReason)
                 ) &&
                 (
                     PreferredLanguage == other.PreferredLanguage ||
                     PreferredLanguage != null &&
                     PreferredLanguage.Equals(other.PreferredLanguage)
                 ) &&
                 (
                     ValidFor == other.ValidFor ||
                     ValidFor != null &&
                     ValidFor.Equals(other.ValidFor)
                 ) &&
                 (
                     EngagedParty == other.EngagedParty ||
                     EngagedParty != null &&
                     EngagedParty.Equals(other.EngagedParty)
                 ) &&
                 (
                     PartyRoleType == other.PartyRoleType ||
                     PartyRoleType != null &&
                     PartyRoleType.Equals(other.PartyRoleType)
                 ) &&
                 (
                     Account == other.Account ||
                     Account != null &&
                     Account.SequenceEqual(other.Account)
                 ) &&
                 (
                     PaymentMethod == other.PaymentMethod ||
                     PaymentMethod != null &&
                     PaymentMethod.SequenceEqual(other.PaymentMethod)
                 ) &&
                 (
                     ContactMedium == other.ContactMedium ||
                     ContactMedium != null &&
                     ContactMedium.SequenceEqual(other.ContactMedium)
                 ) &&
                 (
                     Characteristic == other.Characteristic ||
                     Characteristic != null &&
                     Characteristic.SequenceEqual(other.Characteristic)
                 ) &&
                 (
                     CreditProfile == other.CreditProfile ||
                     CreditProfile != null &&
                     CreditProfile.SequenceEqual(other.CreditProfile)
                 ) &&
                 (
                     Agreement == other.Agreement ||
                     Agreement != null &&
                     Agreement.SequenceEqual(other.Agreement)
                 ) &&
                 (
                     RelatedParty == other.RelatedParty ||
                     RelatedParty != null &&
                     RelatedParty.SequenceEqual(other.RelatedParty)
                 ));
        }