Exemplo n.º 1
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (reservation_ != null)
            {
                hash ^= Reservation.GetHashCode();
            }
            if (BookingId.Length != 0)
            {
                hash ^= BookingId.GetHashCode();
            }
            if (dateRangePrior_ != null)
            {
                hash ^= DateRangePrior.GetHashCode();
            }
            if (roomTypePrior_ != null)
            {
                hash ^= RoomTypePrior.GetHashCode();
            }
            if (NumberAdultsPrior != 0)
            {
                hash ^= NumberAdultsPrior.GetHashCode();
            }
            if (NumberChildrenPrior != 0)
            {
                hash ^= NumberChildrenPrior.GetHashCode();
            }
            if (priceEstimatePrior_ != null)
            {
                hash ^= PriceEstimatePrior.GetHashCode();
            }
            if (dateRangeLatter_ != null)
            {
                hash ^= DateRangeLatter.GetHashCode();
            }
            if (roomTypeLatter_ != null)
            {
                hash ^= RoomTypeLatter.GetHashCode();
            }
            if (NumberAdultsLatter != 0)
            {
                hash ^= NumberAdultsLatter.GetHashCode();
            }
            if (NumberChildrenLatter != 0)
            {
                hash ^= NumberChildrenLatter.GetHashCode();
            }
            if (priceEstimateLatter_ != null)
            {
                hash ^= PriceEstimateLatter.GetHashCode();
            }
            hash ^= tagsPrior_.GetHashCode();
            hash ^= tagsLatter_.GetHashCode();
            return(hash);
        }
Exemplo n.º 2
0
 public void MergeFrom(ReservationAmendmentSummary other)
 {
     if (other == null)
     {
         return;
     }
     if (other.reservation_ != null)
     {
         if (reservation_ == null)
         {
             reservation_ = new global::HOLMS.Types.Booking.Indicators.ReservationIndicator();
         }
         Reservation.MergeFrom(other.Reservation);
     }
     if (other.BookingId.Length != 0)
     {
         BookingId = other.BookingId;
     }
     if (other.dateRangePrior_ != null)
     {
         if (dateRangePrior_ == null)
         {
             dateRangePrior_ = new global::HOLMS.Types.Primitive.PbInclusiveOpsdateRange();
         }
         DateRangePrior.MergeFrom(other.DateRangePrior);
     }
     if (other.roomTypePrior_ != null)
     {
         if (roomTypePrior_ == null)
         {
             roomTypePrior_ = new global::HOLMS.Types.Supply.RoomTypes.RoomType();
         }
         RoomTypePrior.MergeFrom(other.RoomTypePrior);
     }
     if (other.NumberAdultsPrior != 0)
     {
         NumberAdultsPrior = other.NumberAdultsPrior;
     }
     if (other.NumberChildrenPrior != 0)
     {
         NumberChildrenPrior = other.NumberChildrenPrior;
     }
     if (other.priceEstimatePrior_ != null)
     {
         if (priceEstimatePrior_ == null)
         {
             priceEstimatePrior_ = new global::HOLMS.Types.Booking.Pricing.ReservationPriceEstimate();
         }
         PriceEstimatePrior.MergeFrom(other.PriceEstimatePrior);
     }
     if (other.dateRangeLatter_ != null)
     {
         if (dateRangeLatter_ == null)
         {
             dateRangeLatter_ = new global::HOLMS.Types.Primitive.PbInclusiveOpsdateRange();
         }
         DateRangeLatter.MergeFrom(other.DateRangeLatter);
     }
     if (other.roomTypeLatter_ != null)
     {
         if (roomTypeLatter_ == null)
         {
             roomTypeLatter_ = new global::HOLMS.Types.Supply.RoomTypes.RoomType();
         }
         RoomTypeLatter.MergeFrom(other.RoomTypeLatter);
     }
     if (other.NumberAdultsLatter != 0)
     {
         NumberAdultsLatter = other.NumberAdultsLatter;
     }
     if (other.NumberChildrenLatter != 0)
     {
         NumberChildrenLatter = other.NumberChildrenLatter;
     }
     if (other.priceEstimateLatter_ != null)
     {
         if (priceEstimateLatter_ == null)
         {
             priceEstimateLatter_ = new global::HOLMS.Types.Booking.Pricing.ReservationPriceEstimate();
         }
         PriceEstimateLatter.MergeFrom(other.PriceEstimateLatter);
     }
     tagsPrior_.Add(other.tagsPrior_);
     tagsLatter_.Add(other.tagsLatter_);
 }