public void MergeFrom(CompleteOpenReservation other) { if (other == null) { return; } if (other.entityId_ != null) { if (entityId_ == null) { entityId_ = new global::HOLMS.Types.Booking.Indicators.ReservationIndicator(); } EntityId.MergeFrom(other.EntityId); } if (other.BookingId.Length != 0) { BookingId = other.BookingId; } if (other.State != 0) { State = other.State; } if (other.guest_ != null) { if (guest_ == null) { guest_ = new global::HOLMS.Types.CRM.Guests.Guest(); } Guest.MergeFrom(other.Guest); } if (other.dateRange_ != null) { if (dateRange_ == null) { dateRange_ = new global::HOLMS.Types.Primitive.PbInclusiveOpsdateRange(); } DateRange.MergeFrom(other.DateRange); } if (other.NumberAdults != 0) { NumberAdults = other.NumberAdults; } if (other.NumberChildren != 0) { NumberChildren = other.NumberChildren; } if (other.roomType_ != null) { if (roomType_ == null) { roomType_ = new global::HOLMS.Types.Supply.RoomTypes.RoomType(); } RoomType.MergeFrom(other.RoomType); } additionalGuests_.Add(other.additionalGuests_); if (other.TaxExempt != false) { TaxExempt = other.TaxExempt; } if (other.GuaranteeStatus != 0) { GuaranteeStatus = other.GuaranteeStatus; } if (other.unpaidGuaranteeBalance_ != null) { if (unpaidGuaranteeBalance_ == null) { unpaidGuaranteeBalance_ = new global::HOLMS.Types.Primitive.MonetaryAmount(); } UnpaidGuaranteeBalance.MergeFrom(other.UnpaidGuaranteeBalance); } if (other.hkTimePreference_ != null) { if (hkTimePreference_ == null) { hkTimePreference_ = new global::HOLMS.Types.Operations.Housekeeping.HousekeepingTime(); } HkTimePreference.MergeFrom(other.HkTimePreference); } if (other.VehiclePlateInformation.Length != 0) { VehiclePlateInformation = other.VehiclePlateInformation; } if (other.CurrentOccupiedRoomNumber.Length != 0) { CurrentOccupiedRoomNumber = other.CurrentOccupiedRoomNumber; } if (other.currentOccupiedRoom_ != null) { if (currentOccupiedRoom_ == null) { currentOccupiedRoom_ = new global::HOLMS.Types.Operations.Rooms.RoomIndicator(); } CurrentOccupiedRoom.MergeFrom(other.CurrentOccupiedRoom); } if (other.TerminalOccupiedRoomNumber.Length != 0) { TerminalOccupiedRoomNumber = other.TerminalOccupiedRoomNumber; } if (other.terminalOccupiedRoom_ != null) { if (terminalOccupiedRoom_ == null) { terminalOccupiedRoom_ = new global::HOLMS.Types.Operations.Rooms.RoomIndicator(); } TerminalOccupiedRoom.MergeFrom(other.TerminalOccupiedRoom); } activeTags_.Add(other.activeTags_); if (other.ChannelManagerId.Length != 0) { ChannelManagerId = other.ChannelManagerId; } if (other.SourceChannelId.Length != 0) { SourceChannelId = other.SourceChannelId; } if (other.cancellationPolicy_ != null) { if (cancellationPolicy_ == null) { cancellationPolicy_ = new global::HOLMS.Types.Booking.Indicators.CancellationPolicyIndicator(); } CancellationPolicy.MergeFrom(other.CancellationPolicy); } }
public override int GetHashCode() { int hash = 1; if (entityId_ != null) { hash ^= EntityId.GetHashCode(); } if (BookingId.Length != 0) { hash ^= BookingId.GetHashCode(); } if (State != 0) { hash ^= State.GetHashCode(); } if (guest_ != null) { hash ^= Guest.GetHashCode(); } if (dateRange_ != null) { hash ^= DateRange.GetHashCode(); } if (NumberAdults != 0) { hash ^= NumberAdults.GetHashCode(); } if (NumberChildren != 0) { hash ^= NumberChildren.GetHashCode(); } if (roomType_ != null) { hash ^= RoomType.GetHashCode(); } hash ^= additionalGuests_.GetHashCode(); if (TaxExempt != false) { hash ^= TaxExempt.GetHashCode(); } if (GuaranteeStatus != 0) { hash ^= GuaranteeStatus.GetHashCode(); } if (unpaidGuaranteeBalance_ != null) { hash ^= UnpaidGuaranteeBalance.GetHashCode(); } if (hkTimePreference_ != null) { hash ^= HkTimePreference.GetHashCode(); } if (VehiclePlateInformation.Length != 0) { hash ^= VehiclePlateInformation.GetHashCode(); } if (CurrentOccupiedRoomNumber.Length != 0) { hash ^= CurrentOccupiedRoomNumber.GetHashCode(); } if (currentOccupiedRoom_ != null) { hash ^= CurrentOccupiedRoom.GetHashCode(); } if (TerminalOccupiedRoomNumber.Length != 0) { hash ^= TerminalOccupiedRoomNumber.GetHashCode(); } if (terminalOccupiedRoom_ != null) { hash ^= TerminalOccupiedRoom.GetHashCode(); } hash ^= activeTags_.GetHashCode(); if (ChannelManagerId.Length != 0) { hash ^= ChannelManagerId.GetHashCode(); } if (SourceChannelId.Length != 0) { hash ^= SourceChannelId.GetHashCode(); } if (cancellationPolicy_ != null) { hash ^= CancellationPolicy.GetHashCode(); } return(hash); }
public override int GetHashCode() { int hash = 1; if (entityId_ != null) { hash ^= EntityId.GetHashCode(); } if (BookingId.Length != 0) { hash ^= BookingId.GetHashCode(); } if (State != 0) { hash ^= State.GetHashCode(); } if (guest_ != null) { hash ^= Guest.GetHashCode(); } if (dateRange_ != null) { hash ^= DateRange.GetHashCode(); } if (roomType_ != null) { hash ^= RoomType.GetHashCode(); } if (GuaranteeStatus != 0) { hash ^= GuaranteeStatus.GetHashCode(); } if (tenancy_ != null) { hash ^= Tenancy.GetHashCode(); } if (property_ != null) { hash ^= Property.GetHashCode(); } if (Channel != 0) { hash ^= Channel.GetHashCode(); } if (VehiclePlateInformation.Length != 0) { hash ^= VehiclePlateInformation.GetHashCode(); } if (CurrentOccupiedRoomNumber.Length != 0) { hash ^= CurrentOccupiedRoomNumber.GetHashCode(); } if (currentOccupiedRoom_ != null) { hash ^= CurrentOccupiedRoom.GetHashCode(); } if (TerminalOccupiedRoomNumber.Length != 0) { hash ^= TerminalOccupiedRoomNumber.GetHashCode(); } if (terminalOccupiedRoom_ != null) { hash ^= TerminalOccupiedRoom.GetHashCode(); } if (NumberAdults != 0) { hash ^= NumberAdults.GetHashCode(); } if (NumberChildren != 0) { hash ^= NumberChildren.GetHashCode(); } hash ^= activeTags_.GetHashCode(); if (cancellationPolicy_ != null) { hash ^= CancellationPolicy.GetHashCode(); } if (hkTimePreference_ != null) { hash ^= HkTimePreference.GetHashCode(); } if (createdAt_ != null) { hash ^= CreatedAt.GetHashCode(); } if (OutstandingIssuedRoomKeys != 0) { hash ^= OutstandingIssuedRoomKeys.GetHashCode(); } if (OptaRoomStayIndex != 0) { hash ^= OptaRoomStayIndex.GetHashCode(); } if (ReservationIdFromChannel.Length != 0) { hash ^= ReservationIdFromChannel.GetHashCode(); } return(hash); }
public void MergeFrom(ReservationSummary other) { if (other == null) { return; } if (other.entityId_ != null) { if (entityId_ == null) { entityId_ = new global::HOLMS.Types.Booking.Indicators.ReservationIndicator(); } EntityId.MergeFrom(other.EntityId); } if (other.BookingId.Length != 0) { BookingId = other.BookingId; } if (other.State != 0) { State = other.State; } if (other.guest_ != null) { if (guest_ == null) { guest_ = new global::HOLMS.Types.CRM.Guests.Guest(); } Guest.MergeFrom(other.Guest); } if (other.dateRange_ != null) { if (dateRange_ == null) { dateRange_ = new global::HOLMS.Types.Primitive.PbInclusiveOpsdateRange(); } DateRange.MergeFrom(other.DateRange); } if (other.roomType_ != null) { if (roomType_ == null) { roomType_ = new global::HOLMS.Types.Supply.RoomTypes.RoomType(); } RoomType.MergeFrom(other.RoomType); } if (other.GuaranteeStatus != 0) { GuaranteeStatus = other.GuaranteeStatus; } if (other.tenancy_ != null) { if (tenancy_ == null) { tenancy_ = new global::HOLMS.Types.IAM.TenancyIndicator(); } Tenancy.MergeFrom(other.Tenancy); } if (other.property_ != null) { if (property_ == null) { property_ = new global::HOLMS.Types.TenancyConfig.Indicators.PropertyIndicator(); } Property.MergeFrom(other.Property); } if (other.Channel != 0) { Channel = other.Channel; } if (other.VehiclePlateInformation.Length != 0) { VehiclePlateInformation = other.VehiclePlateInformation; } if (other.CurrentOccupiedRoomNumber.Length != 0) { CurrentOccupiedRoomNumber = other.CurrentOccupiedRoomNumber; } if (other.currentOccupiedRoom_ != null) { if (currentOccupiedRoom_ == null) { currentOccupiedRoom_ = new global::HOLMS.Types.Operations.Rooms.RoomIndicator(); } CurrentOccupiedRoom.MergeFrom(other.CurrentOccupiedRoom); } if (other.TerminalOccupiedRoomNumber.Length != 0) { TerminalOccupiedRoomNumber = other.TerminalOccupiedRoomNumber; } if (other.terminalOccupiedRoom_ != null) { if (terminalOccupiedRoom_ == null) { terminalOccupiedRoom_ = new global::HOLMS.Types.Operations.Rooms.RoomIndicator(); } TerminalOccupiedRoom.MergeFrom(other.TerminalOccupiedRoom); } if (other.NumberAdults != 0) { NumberAdults = other.NumberAdults; } if (other.NumberChildren != 0) { NumberChildren = other.NumberChildren; } activeTags_.Add(other.activeTags_); if (other.cancellationPolicy_ != null) { if (cancellationPolicy_ == null) { cancellationPolicy_ = new global::HOLMS.Types.Booking.Indicators.CancellationPolicyIndicator(); } CancellationPolicy.MergeFrom(other.CancellationPolicy); } if (other.hkTimePreference_ != null) { if (hkTimePreference_ == null) { hkTimePreference_ = new global::HOLMS.Types.Operations.Housekeeping.HousekeepingTime(); } HkTimePreference.MergeFrom(other.HkTimePreference); } if (other.createdAt_ != null) { if (createdAt_ == null) { createdAt_ = new global::Google.Protobuf.WellKnownTypes.Timestamp(); } CreatedAt.MergeFrom(other.CreatedAt); } if (other.OutstandingIssuedRoomKeys != 0) { OutstandingIssuedRoomKeys = other.OutstandingIssuedRoomKeys; } if (other.OptaRoomStayIndex != 0) { OptaRoomStayIndex = other.OptaRoomStayIndex; } if (other.ReservationIdFromChannel.Length != 0) { ReservationIdFromChannel = other.ReservationIdFromChannel; } }
public override int GetHashCode() { int hash = 1; if (entityId_ != null) { hash ^= EntityId.GetHashCode(); } if (BookingId.Length != 0) { hash ^= BookingId.GetHashCode(); } if (State != 0) { hash ^= State.GetHashCode(); } if (guest_ != null) { hash ^= Guest.GetHashCode(); } if (dateRange_ != null) { hash ^= DateRange.GetHashCode(); } if (NumberAdults != 0) { hash ^= NumberAdults.GetHashCode(); } if (NumberChildren != 0) { hash ^= NumberChildren.GetHashCode(); } if (roomType_ != null) { hash ^= RoomType.GetHashCode(); } hash ^= additionalGuests_.GetHashCode(); if (TaxExempt != false) { hash ^= TaxExempt.GetHashCode(); } if (hkTimePreference_ != null) { hash ^= HkTimePreference.GetHashCode(); } if (VehiclePlateInformation.Length != 0) { hash ^= VehiclePlateInformation.GetHashCode(); } if (CurrentOccupiedRoomNumber.Length != 0) { hash ^= CurrentOccupiedRoomNumber.GetHashCode(); } if (currentOccupiedRoom_ != null) { hash ^= CurrentOccupiedRoom.GetHashCode(); } if (TerminalOccupiedRoomNumber.Length != 0) { hash ^= TerminalOccupiedRoomNumber.GetHashCode(); } if (terminalOccupiedRoom_ != null) { hash ^= TerminalOccupiedRoom.GetHashCode(); } if (FirstNightAssignedRoom.Length != 0) { hash ^= FirstNightAssignedRoom.GetHashCode(); } hash ^= activeTags_.GetHashCode(); if (ChannelManagerId.Length != 0) { hash ^= ChannelManagerId.GetHashCode(); } if (SourceChannelId.Length != 0) { hash ^= SourceChannelId.GetHashCode(); } if (cancellationPolicy_ != null) { hash ^= CancellationPolicy.GetHashCode(); } if (ReservationIdFromChannel.Length != 0) { hash ^= ReservationIdFromChannel.GetHashCode(); } if (RushReservationIdFromChannel.Length != 0) { hash ^= RushReservationIdFromChannel.GetHashCode(); } if (SourceIndirectChannel.Length != 0) { hash ^= SourceIndirectChannel.GetHashCode(); } if (reservationSource_ != null) { hash ^= ReservationSource.GetHashCode(); } return(hash); }