public override int GetHashCode()
        {
            int hash = 1;

            if (roomType_ != null)
            {
                hash ^= RoomType.GetHashCode();
            }
            if (date_ != null)
            {
                hash ^= Date.GetHashCode();
            }
            if (Available != 0)
            {
                hash ^= Available.GetHashCode();
            }
            if (rateSchedule_ != null)
            {
                hash ^= RateSchedule.GetHashCode();
            }
            if (nightlyPrice_ != null)
            {
                hash ^= NightlyPrice.GetHashCode();
            }
            hash ^= requiredTags_.GetHashCode();
            if (ReleasableHolds != 0)
            {
                hash ^= ReleasableHolds.GetHashCode();
            }
            if (IsPriceOverridden != false)
            {
                hash ^= IsPriceOverridden.GetHashCode();
            }
            return(hash);
        }
示例#2
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (roomType_ != null)
            {
                hash ^= RoomType.GetHashCode();
            }
            if (date_ != null)
            {
                hash ^= Date.GetHashCode();
            }
            if (Available != 0)
            {
                hash ^= Available.GetHashCode();
            }
            if (rateSchedule_ != null)
            {
                hash ^= RateSchedule.GetHashCode();
            }
            if (nightlyPrice_ != null)
            {
                hash ^= NightlyPrice.GetHashCode();
            }
            hash ^= requiredTags_.GetHashCode();
            return(hash);
        }
        public override int GetHashCode()
        {
            int hash = 1;

            if (date_ != null)
            {
                hash ^= Date.GetHashCode();
            }
            if (rateSchedule_ != null)
            {
                hash ^= RateSchedule.GetHashCode();
            }
            if (roomType_ != null)
            {
                hash ^= RoomType.GetHashCode();
            }
            if (nightlyPrice_ != null)
            {
                hash ^= NightlyPrice.GetHashCode();
            }
            if (IsPriceOverriddenBooking != false)
            {
                hash ^= IsPriceOverriddenBooking.GetHashCode();
            }
            return(hash);
        }
 public void MergeFrom(PricedOfferedLodging other)
 {
     if (other == null)
     {
         return;
     }
     if (other.roomType_ != null)
     {
         if (roomType_ == null)
         {
             roomType_ = new global::HOLMS.Types.Supply.RoomTypes.RoomTypeIndicator();
         }
         RoomType.MergeFrom(other.RoomType);
     }
     if (other.date_ != null)
     {
         if (date_ == null)
         {
             date_ = new global::HOLMS.Types.Primitive.PbLocalDate();
         }
         Date.MergeFrom(other.Date);
     }
     if (other.Available != 0)
     {
         Available = other.Available;
     }
     if (other.rateSchedule_ != null)
     {
         if (rateSchedule_ == null)
         {
             rateSchedule_ = new global::HOLMS.Types.Supply.RateScheduleIndicator();
         }
         RateSchedule.MergeFrom(other.RateSchedule);
     }
     if (other.nightlyPrice_ != null)
     {
         if (nightlyPrice_ == null)
         {
             nightlyPrice_ = new global::HOLMS.Types.Primitive.MonetaryAmount();
         }
         NightlyPrice.MergeFrom(other.NightlyPrice);
     }
     requiredTags_.Add(other.requiredTags_);
     if (other.ReleasableHolds != 0)
     {
         ReleasableHolds = other.ReleasableHolds;
     }
     if (other.IsPriceOverridden != false)
     {
         IsPriceOverridden = other.IsPriceOverridden;
     }
 }
 public void MergeFrom(ScheduledPrice other)
 {
     if (other == null)
     {
         return;
     }
     if (other.date_ != null)
     {
         if (date_ == null)
         {
             date_ = new global::HOLMS.Types.Primitive.PbLocalDate();
         }
         Date.MergeFrom(other.Date);
     }
     if (other.rateSchedule_ != null)
     {
         if (rateSchedule_ == null)
         {
             rateSchedule_ = new global::HOLMS.Types.Supply.RateSchedule();
         }
         RateSchedule.MergeFrom(other.RateSchedule);
     }
     if (other.roomType_ != null)
     {
         if (roomType_ == null)
         {
             roomType_ = new global::HOLMS.Types.Supply.RoomTypes.RoomType();
         }
         RoomType.MergeFrom(other.RoomType);
     }
     if (other.nightlyPrice_ != null)
     {
         if (nightlyPrice_ == null)
         {
             nightlyPrice_ = new global::HOLMS.Types.Primitive.MonetaryAmount();
         }
         NightlyPrice.MergeFrom(other.NightlyPrice);
     }
     if (other.IsPriceOverriddenBooking != false)
     {
         IsPriceOverriddenBooking = other.IsPriceOverriddenBooking;
     }
 }