public virtual int _GetUniqueIdentifier()
        {
            var hashCode = 399326290;

            hashCode = hashCode * -1521134295 + (Id?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (TransportOrderNo?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (OrderYear?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (DocumentTransportNo?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (OrderDate?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (DepartureCustomerName?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (DepartureAddress?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (DepartureCity?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (DepartureState?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (DestinationName?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (DestinationAddress?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (DestinationCity?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (DestinationState?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (Qty?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (OrderWeight?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (Volume?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (Pallet?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (RetiredDate?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (DeliveryDate?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (Note?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (CallCustomerBefore?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (Telephone?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (DayClosed?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (Urgent?.GetHashCode() ?? 0);
            return(hashCode);
        }
예제 #2
0
        public virtual int _GetUniqueIdentifier()
        {
            var hashCode = 399326290;

            hashCode = hashCode * -1521134295 + (Id?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (Description?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (Title?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (Address?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (Telephone?.GetHashCode() ?? 0);
            return(hashCode);
        }
예제 #3
0
        public virtual int _GetUniqueIdentifier()
        {
            var hashCode = 399326290;

            hashCode = hashCode * -1521134295 + (Id?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (ContactPerson?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (AddressOne?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (AddressTwo?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (Telephone?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (Email?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (ManagingDirector?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (EstablishedIn?.GetHashCode() ?? 0);
            return(hashCode);
        }
예제 #4
0
        public void Entity_GetHashCode_BeTrue()
        {
            //Arrange
            var       id         = Guid.NewGuid();
            Telephone telephone  = new Telephone(id, "212", "5513394", "home");
            Telephone telephone2 = new Telephone(id, "212", "5513394", "home");

            //Act
            var telephoneHashCode  = telephone.GetHashCode();
            var telephone2HashCode = telephone2.GetHashCode();

            //Assert
            telephoneHashCode.Should().Be(telephone2HashCode);
        }
예제 #5
0
    public override int GetHashCode()
    {
        int hash = 1;

        if (Type != global::Request.Types.Type.Unknown)
        {
            hash ^= Type.GetHashCode();
        }
        if (volunteer_ != null)
        {
            hash ^= Volunteer.GetHashCode();
        }
        if (DonorId != 0)
        {
            hash ^= DonorId.GetHashCode();
        }
        if (Name.Length != 0)
        {
            hash ^= Name.GetHashCode();
        }
        if (Address.Length != 0)
        {
            hash ^= Address.GetHashCode();
        }
        if (Telephone.Length != 0)
        {
            hash ^= Telephone.GetHashCode();
        }
        if (Sum != 0D)
        {
            hash ^= pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.GetHashCode(Sum);
        }
        if (CaseId != 0)
        {
            hash ^= CaseId.GetHashCode();
        }
        if (Substring.Length != 0)
        {
            hash ^= Substring.GetHashCode();
        }
        if (_unknownFields != null)
        {
            hash ^= _unknownFields.GetHashCode();
        }
        return(hash);
    }
예제 #6
0
 /// <summary>
 /// Gets the hash code
 /// </summary>
 /// <returns>Hash code</returns>
 public override int GetHashCode()
 {
     unchecked // Overflow is fine, just wrap
     {
         var hashCode = 41;
         // Suitable nullity checks etc, of course :)
         if (Incidentid != null)
         {
             hashCode = hashCode * 59 + Incidentid.GetHashCode();
         }
         if (Description != null)
         {
             hashCode = hashCode * 59 + Description.GetHashCode();
         }
         if (Type != null)
         {
             hashCode = hashCode * 59 + Type.GetHashCode();
         }
         if (Position != null)
         {
             hashCode = hashCode * 59 + Position.GetHashCode();
         }
         if (Prio != null)
         {
             hashCode = hashCode * 59 + Prio.GetHashCode();
         }
         if (Status != null)
         {
             hashCode = hashCode * 59 + Status.GetHashCode();
         }
         if (Probability != null)
         {
             hashCode = hashCode * 59 + Probability.GetHashCode();
         }
         if (Interventionplan != null)
         {
             hashCode = hashCode * 59 + Interventionplan.GetHashCode();
         }
         if (Incidenttime != null)
         {
             hashCode = hashCode * 59 + Incidenttime.GetHashCode();
         }
         if (Wbid != null)
         {
             hashCode = hashCode * 59 + Wbid.GetHashCode();
         }
         if (Telephone != null)
         {
             hashCode = hashCode * 59 + Telephone.GetHashCode();
         }
         if (AdditionalMedia != null)
         {
             hashCode = hashCode * 59 + AdditionalMedia.GetHashCode();
         }
         if (MediaType != null)
         {
             hashCode = hashCode * 59 + MediaType.GetHashCode();
         }
         if (Area != null)
         {
             hashCode = hashCode * 59 + Area.GetHashCode();
         }
         return(hashCode);
     }
 }